psacct/psacct-logrotate.in

15 lines
387 B
Plaintext
Raw Normal View History

2019-11-19 11:53:12 +08:00
/var/account/pacct {
compress
delaycompress
notifempty
daily
2020-01-21 16:37:02 +08:00
dateext
2019-11-19 11:53:12 +08:00
rotate 31
create 0600 root root
postrotate
2020-01-21 16:37:02 +08:00
if /usr/bin/systemctl --quiet is-active psacct.service ; then
/usr/sbin/accton /var/account/pacct | /usr/bin/grep -v "Turning on process accounting, file set to '/var/account/pacct'." | /usr/bin/cat
2019-11-19 11:53:12 +08:00
fi
endscript
}