Logrotate gives warnings for three config files:
$ sudo logrotate -v -d /etc/logrotate.conf 2>&1 | fgrep -B1 warning
reading config file commcare-hq-gunicorn
warning: 'size' overrides previously specified 'daily'
reading config file monolith
warning: 'size' overrides previously specified 'weekly'
reading config file monolith-sprite_couchdb2
warning: 'size' overrides previously specified 'hourly
The size directive overrides the period (rather than "either-or"), which means that the log directories will eventually grow to massive size. Assuming 2x compression:
commcare-hq.gunicorn.log: no big deal: size 50M; rotate 5 means (1+5/2)*50M = 175M
/home/cchq/www/mint-sprite/log: size 750M; rotate 4 for 38 files (in my monolith): 38*(1+4/2)*750M = 85G
/opt/couchdb/var/log/couchdb.log: size 300M; rotate 100: 51*300M = 15G
/var/log/* (rsyslog, uses weekly in standard Ubuntu): size 750M; rotate 4 for 14 files: 14*(1+4/2)*750M = 31G
Clearly it will take considerable time to get to 100G, but given the lack of a time limit this volume will eventually be reached (also, these aren't the only log files). Maybe a periodic cron job to cull outdated log files?
Logrotate gives warnings for three config files:
The
sizedirective overrides the period (rather than "either-or"), which means that the log directories will eventually grow to massive size. Assuming 2x compression:commcare-hq.gunicorn.log: no big deal:size 50M; rotate 5means (1+5/2)*50M = 175M/home/cchq/www/mint-sprite/log:size 750M; rotate 4for 38 files (in my monolith): 38*(1+4/2)*750M = 85G/opt/couchdb/var/log/couchdb.log:size 300M; rotate 100: 51*300M = 15G/var/log/*(rsyslog, usesweeklyin standard Ubuntu):size 750M; rotate 4for 14 files: 14*(1+4/2)*750M = 31GClearly it will take considerable time to get to 100G, but given the lack of a time limit this volume will eventually be reached (also, these aren't the only log files). Maybe a periodic cron job to cull outdated log files?