zhangshuyan0 commented on PR #5855:
URL: https://github.com/apache/hadoop/pull/5855#issuecomment-1661459596

   > Two of the cases will come into this logic
   > 
   > 1. The namenode is restarting while receiving FBRS from all datanodes and 
is in safe mode
   > 2. When the namenode is in secure mode for some reason while it has been 
running for a long time
   >    In the first case, if the datanode has a failed disk, the datanode will 
send the FBR for the normal disk and the namenode will handle it normally
   >    In the second case, blockReportCount == 0 will always be false if no 
new disks are added to the datanode
   >    So I recommend keeping the code as it is and not using blockReportCount 
== 0
   
   @Tre2878 If a disk is failed, its' state will be set to `FAILED` and it will 
be removed from `storageMap`. So the check of `blockReportCount` will not 
involve failed storages, and `blockReportCount == 0` is not always be false. 
Thus, I think my plan can work here. What's your opinion?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to