I. namenode details
Ii. Execution Process of namenode and secondarynamenode
Fsimage is very important, so it was backed up.
Core-default.xml
<Property>
<Name> hadoop. tmp. dir </Name>
<Value>/tmp/hadoop-$ {user. name} </value>
<Description> a base for other temporary directories. </description>
</Property>
Hdfs-default.xml
<Property>
<Name> DFS. Name. dir </Name>
<Value >$ {hadoop. tmp. dir}/dfs/name </value>
<Description> determines where on the local filesystem the DFS Name Node
Shocould store the name table (fsimage). If this is a comma-delimited list
Of directories then the name table is replicated in all of
Directories, for redundancy. </description>
</Property>
HA solution. However, hot backup is not supported. Configuration.
(See source code)
Execution Process: Download the metadata information (fsimage, edits) from namenode, merge the two, generate a new fsimage, save it locally, and push it to namenode, reset the edits of the namenode.
It is installed on the namenode node by default, but it is not safe!
The data of datanode is not infinitely stored. It is decided to use the fsimage with namenode. Because the fsimage is stored in the memory, the memory cannot exceed TB! (The memory cannot be stored, and the fsimage is stored in the memory.) the metadata of namenode occupies the memory.
1. Add memory to namenode
2. Upload large files as much as possible.
3. sequencefile
4. Increase the block size (this depends on the environment, that is, the size of the uploaded files is designed to be large)