phase wrote:
>
> I currently have qmail logging via syslog to maillog. I would like to
> change the log files to log to the /var/log/qmail dir.
>
> This is my rc file.
>
> #!/bin/sh
> exec env - PATH="/var/qmail/bin:$PATH" \
> qmail-start ./Mailbox splogger qmail
>
> as u see it uses the splogger..
>
> I've found one example but it uses cyclog which I can't find in the
> latest daemontools where it should be? It goes something like this..
>
> #!/bin/sh
> exec env - PATH="/var/qmail/bin:$PATH" \
> qmail-start ./Mailbox /usr/local/bin/accustamp \
> | setuser qmaill /usr/local/bin/cyclog /var/log/qmail &
>
> In short, can I use splogger or any other log tool to direct logging
> to the /var/log/qmail dir & how would the rc file look like?
>
> thanxs..
Take a look at http://www.inter7.com/qmailmrtg7/
It has sample startup scripts and of course,
mrtg graphs for all the logs.
Basicly this is the startup script (from the
qmailmrtg7 INSTALL doc)
1. How should I start qmail, smtp and pop to create the right kind
of logs?
First make sure you have the log directories:
mkdir /var/log/qmail
mkdir /var/log/pop3
mkdir /var/log/smtp
chown qmaill /var/log/qmail
chown qmaill /var/log/pop3
chown qmaill /var/log/smtp
Then start up qmail
env - PATH="/var/qmail/bin:/usr/local/bin" \
qmail-start ./Maildir/ | /usr/local/bin/setuidgid qmaill \
/usr/local/bin/multilog t n100 s1000000 /var/log/qmail &
env - PATH="/var/qmail/bin:/usr/local/bin" \
tcpserver -v -H -R -l$HOSTNAME -c200 0 110
/var/qmail/bin/qmail-popup \
$HOSTNAME \
/home/vpopmail/bin/vchkpw /var/qmail/bin/qmail-pop3d Maildir
2>&1 | \
/usr/local/bin/setuidgid qmaill \
/usr/local/bin/multilog t n100 s1000000 /var/log/pop3 &
env - PATH="/var/qmail/bin:/usr/local/bin" \
tcpserver -v -H -R -l$HOSTNAME -x
/home/vpopmail/etc/tcp.smtp.cdb \
-c200 -u8002 -g8001 0 25 fixcrio /var/qmail/bin/qmail-smtpd 2>&1
| \
/usr/local/bin/setuidgid qmaill \
/usr/local/bin/multilog t n100 s1000000 /var/log/smtp &