[ 
https://issues.apache.org/jira/browse/HDFS-16482?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

cp updated HDFS-16482:
----------------------
    Description: 
DfsClient call ObsererNamenode throw FileNotFoundException:
{code:java}
       at 
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.checkLease(FSNamesystem.java:2898)
        at 
org.apache.hadoop.hdfs.server.namenode.FSDirWriteFileOp.analyzeFileState(FSDirWriteFileOp.java:599)
        at 
org.apache.hadoop.hdfs.server.namenode.FSDirWriteFileOp.validateAddBlock(FSDirWriteFileOp.java:171)
        at 
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getAdditionalBlock(FSNamesystem.java:2777)
        at 
org.apache.hadoop.hdfs.server.namenode.NameNodeRpcServer.addBlock(NameNodeRpcServer.java:892)
 {code}
 

 addBlock operation should send to ANN,but if ANN is changed or access ANN 
timeout,DfsClient will find ANN from failOverProxy which ObserverNode in. If 
the command send to ObserverNode, ObserverNode will not block until it is 
synchronized with the client because the method is not readOnly.

!image-2022-03-25-18-21-57-677.png!

getAdditionalBlock method check read operation and check file exits or not and 
check write operation finally.

!image-2022-03-25-18-25-19-808.png|width=230,height=266!

I think the ObserverNameNode should not handle this method firstly

  was:
DfsClient call ObsererNamenode throw FileNotFoundException:
{code:java}
       at 
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.checkLease(FSNamesystem.java:2898)
        at 
org.apache.hadoop.hdfs.server.namenode.FSDirWriteFileOp.analyzeFileState(FSDirWriteFileOp.java:599)
        at 
org.apache.hadoop.hdfs.server.namenode.FSDirWriteFileOp.validateAddBlock(FSDirWriteFileOp.java:171)
        at 
org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getAdditionalBlock(FSNamesystem.java:2777)
        at 
org.apache.hadoop.hdfs.server.namenode.NameNodeRpcServer.addBlock(NameNodeRpcServer.java:892)
 {code}
 

 addBlock operation should send to ANN,but if ANN is changed or access ANN 
timeout,DfsClient will find ANN from failOverProxy which ObserverNode in. If 
the command send to ObserverNode, ObserverNode will not block until it is 
synchronized with the client because the method is not readOnly.

!image-2022-03-25-18-21-57-677.png!

getAdditionalBlock method check read operation and check file exits or not and 
check write operation finally.

!image-2022-03-25-18-25-19-808.png!

I think the ObserverNameNode should not handle this method firstly


> ObserverNamenode throw FileNotFoundException on addBlock 
> ---------------------------------------------------------
>
>                 Key: HDFS-16482
>                 URL: https://issues.apache.org/jira/browse/HDFS-16482
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: dfsclient, namenode
>    Affects Versions: 3.2.1
>            Reporter: cp
>            Priority: Major
>         Attachments: image-2022-03-25-18-18-22-720.png, 
> image-2022-03-25-18-25-19-808.png
>
>
> DfsClient call ObsererNamenode throw FileNotFoundException:
> {code:java}
>        at 
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.checkLease(FSNamesystem.java:2898)
>         at 
> org.apache.hadoop.hdfs.server.namenode.FSDirWriteFileOp.analyzeFileState(FSDirWriteFileOp.java:599)
>         at 
> org.apache.hadoop.hdfs.server.namenode.FSDirWriteFileOp.validateAddBlock(FSDirWriteFileOp.java:171)
>         at 
> org.apache.hadoop.hdfs.server.namenode.FSNamesystem.getAdditionalBlock(FSNamesystem.java:2777)
>         at 
> org.apache.hadoop.hdfs.server.namenode.NameNodeRpcServer.addBlock(NameNodeRpcServer.java:892)
>  {code}
>  
>  addBlock operation should send to ANN,but if ANN is changed or access ANN 
> timeout,DfsClient will find ANN from failOverProxy which ObserverNode in. If 
> the command send to ObserverNode, ObserverNode will not block until it is 
> synchronized with the client because the method is not readOnly.
> !image-2022-03-25-18-21-57-677.png!
> getAdditionalBlock method check read operation and check file exits or not 
> and check write operation finally.
> !image-2022-03-25-18-25-19-808.png|width=230,height=266!
> I think the ObserverNameNode should not handle this method firstly



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org

Reply via email to