title: NameNode DataNode communication on read operation
body: <p>So I'm studying for the CCDH certification, and I found some sample questions online but to be honest, I don't think they are all that accurate so I would like to check here.</p>
  
  <p>Which of the following describes best the read operation on HDFS?</p>
  
  <p>A. The client queries the NameNode for the block location(s). The NameNode returns the
  block location(s) to the client. The client reads the data directory off the DataNode(s).</p>
  
  <p>B. The client queries all DataNodes in parallel. The DataNode that contains the requested
  data responds directly to the client. The client reads the data directly off the DataNode.</p>
  
  <p>C. The client contacts the NameNode for the block location(s). The NameNode then
  queries the DataNodes for block locations. The DataNodes respond to the NameNode,
  and the NameNode redirects the client to the DataNode that holds the requested data
  block(s). The client then reads the data directly off the DataNode.</p>
  
  <p>D. The client contacts the NameNode for the block location(s). The NameNode contacts
  the DataNode that holds the requested data block. Data is transferred from the DataNode
  to the NameNode, and then from the NameNode to the client.</p>
  
  <p>I know for sure that B and D. According to the document, the correct answer is C. But I always thought that the NameNode already had the block locations in RAM, and did not need to query the datanodes? So I would expect the correct answer to be A. Am I wrong or is the document wrong?</p>