Support Questions
Find answers, ask questions, and share your expertise

HDP/Hbase log size limit?

Highlighted

HDP/Hbase log size limit?

Explorer

How can i limit size and number of HDP logs in /var/logs, in particular for HBase?

2 REPLIES 2

Re: HDP/Hbase log size limit?

Rising Star

@Victor L

This can be done via Ambari UI. For each component (example HBase) there are configuration options for log file size, number, rotation etc. This is done via Log4j.

For example for HBase, the default is:

hbase.log.maxfilesize=256MB
hbase.log.maxbackupindex=20

HBase uses, the DRFA "org.apache.log4j.DailyRollingFileAppender". If you want the log rotation to happen based on filesize, then you should consider using - "org.apache.log4j.RollingFileAppender".

You can tune the Log4j as per your exact requirement.

Hope this helps.

Regards

Ravi

Highlighted

Re: HDP/Hbase log size limit?

Explorer

The real problem is: hbase.log.maxfilesize is set to 256MB by default but it seems to can grow to GBs size, fill disk and cause disk failure