public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] Questions about logrotate
@ 2020-11-02 12:07 Walter Dnes
  0 siblings, 0 replies; only message in thread
From: Walter Dnes @ 2020-11-02 12:07 UTC (permalink / raw
  To: Gentoo Users List

  Recent install is not rotating logs.  "rc-update" shows cronie and
"sysklogd" at "default" level.  Directory /etc/logrotate.d contains...

elog-save-summary  hibernate-script  openrc  rsyncd

  I assume that I have to create configs for various files in /var/log
Reading "man logrotate", and adapting for sysklogd and bzip2 I get the
following for /var/log/messages.  I intend to rotate whenever the file
hits 3 megabytes.  Does it look OK?  Do I have to set up /etc/crontab?

######################################

compress
compresscmd /bin/bzip2
compressoptions -9
nomail

/var/log/messages {
    rotate 5
    size 3M
    postrotate
        /usr/bin/killall -HUP sysklogd
    endscript
}

######################################

-- 
Walter Dnes <waltdnes@waltdnes.org>
I don't run "desktop environments"; I run useful applications


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-11-02 12:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-11-02 12:07 [gentoo-user] Questions about logrotate Walter Dnes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox