CCA-500 · Question #83
What metadata is stored on a DataNode when a block is written to it?
The correct answer is D. Node location of each block belonging to the same namespace. Each DataNode keeps a small amount of metadata allowing it to identify the cluster it participates in. If this metadata is lost, then the DataNode cannot participate in an HDFS instance and the data blocks it stores cannot be reached. When an HDFS instance is formatted, the…
Question
What metadata is stored on a DataNode when a block is written to it?
Options
- ANone. Only the block itself is written.
- BChecksums for the data in the block, as a separate file.
- CInformation on the file's location in HDFS.
- DNode location of each block belonging to the same namespace.
How the community answered
(15 responses)- A7% (1)
- B7% (1)
- C13% (2)
- D73% (11)
Explanation
Each DataNode keeps a small amount of metadata allowing it to identify the cluster it participates in. If this metadata is lost, then the DataNode cannot participate in an HDFS instance and the data blocks it stores cannot be reached. When an HDFS instance is formatted, the NameNode generates a unique namespace id for the instance. When DataNodes first connect to the NameNode, they bind to this namespace id and establish a unique "storage id" that identifies that particular DataNode in the HDFS instance. This data as well as information about what version of Hadoop was used to create the block files, is stored in a filed named VERSION in the ${dfs.data.dir}/current directory. Note: Administrators of HDFS clusters understand that the HDFS metadata is some of the most precious bits they have. While you might have hundreds of terabytes of information stored in HDFS, the NameNode's metadata is the key that allows this information, spread across several million "blocks" to be reassembled into coherent, ordered files.
Topics
Community Discussion
No community discussion yet for this question.