Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

namenode service is not logging any messages in log file

namenode service is not logging any messages in log file

New Contributor

namenode service is not logging any messages in log file

Attached log4j.properties and hadoop-env

2 REPLIES 2

Re: namenode service is not logging any messages in log file

Vishal,

Where are you checking the logs? they should be under "hdfs_log_dir_prefix"(this directory name can be obtained from Ambari) this directory.

Alternatively you can verify the log location and file by executing this command in namenode machine. "ps -ef | grep namenode"

Also it looks like you have changed the file appender, Do verify the properties with the one here.

Re: namenode service is not logging any messages in log file

Hi @Vishal Shah ,

As @Sandeep Nemuri said you can either verify it with command :

[root@asnaik1 hdfs]# ps -ef|grep namenode |grep -i log
hdfs     19308     1  0 Jul24 ?        05:06:03 /usr/jdk64/jdk1.8.0_112/bin/java -Dproc_namenode -Xmx1024m -Dhdp.version=2.6.5.0-292 -Djava.net.preferIPv4Stack=true -Dhdp.version= -Djava.net.preferIPv4Stack=true -Dhdp.version= -Djava.net.preferIPv4Stack=true -Dhadoop.log.dir=/var/log/hadoop/hdfs -Dhadoop.log.file=hadoop.log -Dhadoop.home.dir=/usr/hdp/2.6.5.0-292/hadoop -Dhadoop.id.str=hdfs -Dhadoop.root.logger=INFO,console -Djava.library.path=:/usr/hdp/2.6.5.0-292/hadoop/lib/native/Linux-amd64-64:/usr/hdp/2.6.5.0-292/hadoop/lib/native/Linux-amd64-64:/usr/hdp/2.6.5.0-292/hadoop/lib/native -Dhadoop.policy.file=hadoop-policy.xml -Djava.net.preferIPv4Stack=true -Dhdp.version=2.6.5.0-292 -Dhadoop.log.dir=/var/log/hadoop/hdfs -Dhadoop.log.file=hadoop-hdfs-namenode-asnaik1.openstacklocal.log -Dhadoop.home.dir=/usr/hdp/2.6.5.0-292/hadoop -Dhadoop.id.str=hdfs -Dhadoop.root.logger=INFO,RFA

and checkout for hadoop.log.dir and hadoop.log.file you will know where the log files are written.

If you are using ambari you can even check the same using ambari UI in Service -> HDFS -> Configs -> Advanced-hadoop-env > Hadoop Log Dir Prefix

the hdfs-audit logs , hdfs-namenode logs and gc logs will be present in this folder.

Hope this helps you :)

If you found answer helpfull please login and accept the answer by click on accept button which will help other users findout correct one easily.