Issue Details (XML | Word | Printable)

Key: HADOOP-5034
Type: New Feature New Feature
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Hairong Kuang
Reporter: Hairong Kuang
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
Hadoop Common

NameNode should send both replication and deletion requests to DataNode in one reply to a heartbeat

Created: 14/Jan/09 07:30 PM   Updated: 08/Jul/09 04:43 PM
Return to search
Component/s: None
Affects Version/s: 0.18.0
Fix Version/s: 0.19.1

Time Tracking:
Not Specified

File Attachments:
  Size
Text File Licensed for inclusion in ASF works blockTransferInvalidate.patch 2009-01-21 09:12 PM Hairong Kuang 12 kB
Text File Licensed for inclusion in ASF works blockTransferInvalidate1.patch 2009-01-22 01:12 AM Hairong Kuang 14 kB
Text File Licensed for inclusion in ASF works blockTransferInvalidate2.patch 2009-01-26 08:04 PM Hairong Kuang 9 kB
Text File Licensed for inclusion in ASF works blockTransferInvalidate3.patch 2009-01-29 01:27 AM Hairong Kuang 14 kB

Hadoop Flags: Reviewed
Release Note: This patch changes the DatanodeProtocoal version number from 18 to 19. The patch allows NameNode to send both block replication and deletion request to a DataNode in response to a heartbeat.
Resolution Date: 02/Feb/09 07:16 PM


 Description  « Hide
Currently NameNode favors block replication requests over deletion requests. On reply to a heartbeat, NameNode does not send a block deletion request unless there is no block replication request.

This brings a problem when a near-full cluster loses a bunch of DataNodes. In react to the DataNode loss, NameNode starts to replicate blocks. However, replication takes a lot of cpu and a lot of replications fail because of the lack of disk space. So the administrator tries to delete some DFS files to free up space. However, block deletion requests get delayed for very long time because it takes a long time to drain the block replication requests for most DataNodes.

I'd like to propose to let NameNode to send both replication requests and deletion requests to DataNodes in one reply to a heartbeat. This also implies that the replication monitor should schedule both replication and deletion work in one iteration.



 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Repository Revision Date User Message
ASF #740077 Mon Feb 02 19:03:12 UTC 2009 hairong HADOOP-5034. NameNode should send both replication and deletion requests to DataNode in one reply to a heartbeat. Contributed by Hairong Kuang.
Files Changed
MODIFY /hadoop/core/trunk/src/test/org/apache/hadoop/hdfs/server/namenode/NNThroughputBenchmark.java
MODIFY /hadoop/core/trunk/CHANGES.txt
MODIFY /hadoop/core/trunk/src/hdfs/org/apache/hadoop/hdfs/server/namenode/NameNode.java
MODIFY /hadoop/core/trunk/src/hdfs/org/apache/hadoop/hdfs/server/datanode/DataNode.java
ADD /hadoop/core/trunk/src/test/org/apache/hadoop/hdfs/server/namenode/TestHeartbeatHandling.java
MODIFY /hadoop/core/trunk/src/hdfs/org/apache/hadoop/hdfs/server/protocol/DatanodeProtocol.java
MODIFY /hadoop/core/trunk/src/hdfs/org/apache/hadoop/hdfs/server/namenode/FSNamesystem.java

Repository Revision Date User Message
ASF #740081 Mon Feb 02 19:10:30 UTC 2009 hairong Merge -r 740076:740077 to move the change of HADOOP-5034 from main t0 branch 0.19.
Files Changed
MODIFY /hadoop/core/branches/branch-0.19/src/hdfs/org/apache/hadoop/hdfs/server/protocol/DatanodeProtocol.java
MODIFY /hadoop/core/branches/branch-0.19/src/hdfs/org/apache/hadoop/hdfs/server/namenode/FSNamesystem.java
MODIFY /hadoop/core/branches/branch-0.19
MODIFY /hadoop/core/branches/branch-0.19/CHANGES.txt
MODIFY /hadoop/core/branches/branch-0.19/src/hdfs/org/apache/hadoop/hdfs/server/namenode/NameNode.java
MODIFY /hadoop/core/branches/branch-0.19/src/hdfs/org/apache/hadoop/hdfs/server/datanode/DataNode.java
ADD /hadoop/core/branches/branch-0.19/src/test/org/apache/hadoop/hdfs/server/namenode/TestHeartbeatHandling.java (from /hadoop/core/trunk/src/test/org/apache/hadoop/hdfs/server/namenode/TestHeartbeatHandling.java)