1

Topic: /var/log/maillog size

my /var/log/maillog size  is around 10MB

i can't properly see it since it is big in size also my net is very poor in speed

how to reduce its size to just 100kb 200kb?


Thanks.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: /var/log/maillog size

You can use logrotate to rotate it when it reaches 100KB. Check files under /etc/logrotate.d/* as reference.

3

Re: /var/log/maillog size

[root@mail ~]# cd    /etc/logrotate.d/
[root@mail logrotate.d]# ls
clamav   fail2ban   httpd    named  samba      shorewall  syslog
dovecot  freshclam  iredapd  ppp    sa-update  sieve      yum


which one is for maillog?

4

Re: /var/log/maillog size

hebrew878 wrote:

[root@mail ~]# cd    /etc/logrotate.d/
[root@mail logrotate.d]# ls
clamav   fail2ban   httpd    named  samba      shorewall  syslog
dovecot  freshclam  iredapd  ppp    sa-update  sieve      yum


which one is for maillog?

Look into syslog

5

Re: /var/log/maillog size

/var/log/messages /var/log/secure /var/log/maillog /var/log/spooler /var/log/boot.log /var/log/cron
{
    sharedscripts
    postrotate
    /bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true
    endscript
}

6 (edited by Javed32155 2013-04-06 02:09:29)

Re: /var/log/maillog size

how to reduce its size to just 100 Kb and  200 Kb?

breathalyser

7

Re: /var/log/maillog size

Hi hebrew878, Javed32155,

You should check manual page of command "logrotate", there's a parameter "size" you can use to achieve your goal. Add this parameter and proper value in files under /etc/logrotate.d/.

Reference: http://linux.die.net/man/8/logrotate

8

Re: /var/log/maillog size

thanks admin smile