Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

can i change log location in HDP installation

avatar
Expert Contributor

Hi Team,

we see logs of various hadoop services are stored in /var/log

can we change it to our customized location

if i dont want to store logs in below location then

/var/log/ambari-agent/ /var/log/ambari-metrics-monitor/ /var/log/ambari-server/ /var/log/hbase /var/log/zookeeper

i see in ambari changing log location is disabled ?

1 ACCEPTED SOLUTION

avatar
Super Guru
@ripunjay godhani

This is easier done at install time. After installation, your best bet is to create symbolic links. Please see the following thread.

https://community.hortonworks.com/questions/4329/log-file-location-is-there-a-way-to-change-varlog.h...

View solution in original post

4 REPLIES 4

avatar
Super Guru
@ripunjay godhani

This is easier done at install time. After installation, your best bet is to create symbolic links. Please see the following thread.

https://community.hortonworks.com/questions/4329/log-file-location-is-there-a-way-to-change-varlog.h...

avatar
Super Guru

@ripunjay godhani

You need to stop Ambari services to allow changes to configurations like log location. During that time, your cluster could still run, but you will have a gap in Ambari logs and metrics.

avatar
Super Collaborator

@ripunjay godhani

For service logs , log directory is controlled by a configuration property. You can modify the configuration property .

Look at https://cwiki.apache.org/confluence/display/AMBARI/Modify+configurations for more details.

You will have to restart the service for the changes to take effect.

avatar
Expert Contributor

@ripunjay godhani

I want to be sure I understand your post. Are you saying that modifying a single Ambari property will relocate logs for all components on a restart? If so, can share what the name of that property is? The page you linked to does not have a single mention of log location.

In a perfect world, I would have left plenty of room under /var for logging, but we have a heavily used cluster with a lot of data and constant crashes from full /var on many of the machines. I need to move everything to a new location.