Often the namenode log files grow in size and they have too many kinds of messages. One of the most commonly faced scenario is where there had been multiple state changes in hdfs and investigating them becomes a pain when there are multiple occurrence in huge log files.
Luckily there is a very easy way to make a few configuration changes to ensure that state change log statements get logged to a separate file.
To isolate and log state change log messages to another file, add the following to hdfs-log4j and restart the namenodes.