Logrotate Beispiel nginx
Version vom 26. März 2025, 19:19 Uhr von Thomas.will (Diskussion | Beiträge) (Die Seite wurde neu angelegt: „ *Die Konfiguration für nginx könnte wie folgt aussehen: <pre> /var/log/nginx/*log { daily missingok rotate 3 notifempty dateext dateformat -%Y-%m-%d…“)
- Die Konfiguration für nginx könnte wie folgt aussehen:
/var/log/nginx/*log {
daily
missingok
rotate 3
notifempty
dateext
dateformat -%Y-%m-%d
create 640 http log
compress
sharedscripts
postrotate
test ! -r /run/nginx.pid || kill -USR1 `cat /run/nginx.pid`
endscript
}