Closed schlos closed 8 years ago
/var/www/imamopravoznati.org/alaveteli/log$ ls -lrtah -rw-rw-r-- 1 alaveteli alaveteli 20K Feb 25 2015 foi-alert-tracks.log -rw-rw-r-- 1 alaveteli alaveteli 4.6M May 8 10:30 update-xapian-index.log -rw-r--r-- 1 alaveteli alaveteli 1.7M May 8 11:22 thin.log -rw-rw-r-- 1 alaveteli alaveteli 529M May 8 12:10 newrelic_agent.log -rw-rw-r-- 1 alaveteli alaveteli 4.9G May 8 12:12 production.log
production.log ~ 415 MB/monthly (13.83 MB/daily; 100 MB/weekly is 5 - 25 MB *.gz) newrelic_agent.log ~ 44 MB/monthly
/etc/logrotate.d$ less alaveteli
/var/www/imamopravoznati.org/alaveteli/log/production.log {
daily
rotate 30
compress
delaycompress
missingok
notifempty
dateext
mail upload.**REDACTED**@u.box.com
create 664 alaveteli alaveteli
}
/var/www/imamopravoznati.org/alaveteli/log/newrelic_agent.log {
monthly
rotate 1
compress
delaycompress
missingok
notifempty
dateext
mail upload.**REDACTED**@u.box.com
create 664 alaveteli alaveteli
}
/var/www/imamopravoznati.org/alaveteli/log/update-xapian-index.log {
monthly
rotate 1
compress
delaycompress
missingok
notifempty
dateext
mail upload.**REDACTED**@u.box.com
create 664 alaveteli alaveteli
}
/var/www/imamopravoznati.org/alaveteli/log/thin.log {
monthly
rotate 1
compress
delaycompress
missingok
notifempty
dateext
mail upload.**REDACTED**@u.box.com
create 664 alaveteli alaveteli
}
http://www.linuxcommand.org/man_pages/logrotate8.html