Link to home
Start Free TrialLog in
Avatar of ITCity
ITCity

asked on

Freebsd maillog rotation to happen not daily. at least every 2 days ( newsyslog.conf)

This is my newsyslog.conf file.  How can i make the maillog rotation not happen daily and every 2 days?


/var/log/all.log                  600  7         *      @T00  J
/var/log/amd.log                  644  7         100      *     J
/var/log/auth.log                  600  7     100  *     JC
/var/log/console.log                  600  5         100      *     J
/var/log/cron                        600  3         100      *     JC
/var/log/daily.log                  640  7         *      @T00  JN
/var/log/debug.log                  600  7     100  *     JC
/var/log/kerberos.log                  600  7         100      *     J
/var/log/lpd-errs                  644  7         100      *     JC
/var/log/maillog                  640  7         *      D0  JC
/var/log/messages                  644  5         100      *     JC
/var/log/monthly.log                  640  12         *      $M1D0 JN
/var/log/pflog                        600  3         100      *     JB    /var/run/pflogd.pid
/var/log/ppp.log      root:network      640  3         100      *     JC
/var/log/security                  600  10         100      *     JC
/var/log/sendmail.st                  640  10         *      168   B
/var/log/slip.log      root:network      640  3         100      *     JC
/var/log/weekly.log                  640  5         1      $W6D0 JN
/var/log/wtmp                        644  3         *      @01T05 B
/var/log/xferlog                  600  7         100      *     JC
Avatar of cminear
cminear

Just so we're clear, you would like maillog to rotate once every 2 days, correct?  If that's the case, change the "D0" you currently have to "48@T01"; this set the interval for rotation to 48 hours, and specify the role time as 1AM.  (Change the "T01" to whenever you'd really like it to run.)  You could also just specify "48", in which case that would be 48 hours from the last time it was rolled.
Avatar of ITCity

ASKER

/var/log/maillog                  640  7         *      48@T01  JC

is this correct?

I want it to rotate every 2 days correct.

Thanks
ASKER CERTIFIED SOLUTION
Avatar of cminear
cminear

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial