Monday, 17 August 2015

What is Secondary Namenode and what it actually does?

Mainly SecondaryNameNode server is used as a backup of NameNode server in Hadoop Distributed File system to recreate the NameNode server if it goes down. As total HDFS depends on the NameNode we have to recover it.

If you are building a test cluster, you don’t need to set up secondary name node on a different machine, something like pseudo cluster install steps. However if you’re building out a real distributed cluster, you must move secondary node to other machine and it is a great idea. You can have Secondary Namenode on a different machine other than  NameNode in case the Namenode goes down.

NameNode actually holds the edit log which contains the metadata information of the NameNode. In every few second the edit log is sent to the Secondary NameNode. Secondary NameNode can not become actual NameNode  itself, because after some time gap the edit log  is sent to the SecondaryNameNode. If the NameNode goes down the Secondary NameNode   lost few data  but it has a persistent copy of the Namenode  server’s metadata. So we can recreate the NameNode.

No comments:

Post a Comment