1
$\begingroup$

In hadoop , if i want to read a file from client , the class DFSInputStream enters in action.

About this, my textbook says

The DFSInputStream also verifies checksums for the data transferred to it from the datanode. If a corrupted block is found, the DFSInputStream attempts to read a replica of the block from another datanode; it also reports the corrupted block to the namenode.

My questions are : 1) What's the meaning in saying that the data is trasferred to DFSInputStream ? Am i wrong, or the client communicates directly with the datanode ?

2)If the checksum shows that the transfer of a block has going wrong, why does the DFSInputStream request this block from another datanode instead of trying again with the datanode that generated the corrupted block ?

$\endgroup$

0

Browse other questions tagged or ask your own question.