Reply
Highlighted
New Contributor
Posts: 2
Registered: ‎04-03-2014

Changing log directory for Hadoop, CDH4

Hello everyone,

 

I have recently deployed a CDH 4.4.0 cluster (manual install/config) and I seem to have some problems with the logging directories. Although I modified the log4j.properties file (the hadoop.log.dir value) in order to point the logs to the desired directory, the logs are still generated under /var/logs/.

 

How could I modify the logging directory? What exactly am I missing here?

I must say that everything else works perfectly fine in the cluster. Logs also look great. But they look great in the wrong directory.

 

Thank you in advance for your answers!

Posts: 1,894
Kudos: 433
Solutions: 303
Registered: ‎07-31-2013

Re: Changing log directory for Hadoop, CDH4

Edit the /etc/default/hadoop and similar files and alter the HADOOP_LOG_DIR environment value under them to point to the directory you need them to go to.

You can alternatively use symlinks.
New Contributor
Posts: 1
Registered: ‎05-13-2014

Re: Changing log directory for Hadoop, CDH4

edit the below files and add the following "HADOOP_LOG_DIR"

 

/etc/default/hadoop-hdfs-namenode

/etc/default/hadoop-hdfs-secondarynamenode

/etc/default/hadoop-hdfs-datanode

 

 

Announcements