A2 Hosting Forums

Full Version: maillog empty... where's my outbound email logged?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
On both my VPS, /var/log/maillog is empty. Can anyone point me to where outgoing SMTP traffic is logged to? Or how I enable logging if it's disabled by default? It's pretty vital to troubleshooting SMTP traffic.

Thanks,
Thilo

trusche Wrote:
On both my VPS, /var/log/maillog is empty. Can anyone point me to where outgoing SMTP traffic is logged to? Or how I enable logging if it's disabled by default? It's pretty vital to troubleshooting SMTP traffic.

Thanks,
Thilo


It depends on your mail client: sendmail should log there, exim logs to /var/log/exim_mainlog, etc. Logging should be enabled by default.

Is your mail server set to start on boot? You won't see a log if it's not running.

Did you try

find /var -name "*log"  

to show all log files under /var?

Bruce Wrote:

It depends on your mail client: sendmail should log there, exim logs to /var/log/exim_mainlog, etc. Logging should be enabled by default.


It's qmail, it seems (the default setup of the VPS), but /var/log/qmail/* are all emtpy.

Bruce Wrote:
Is your mail server set to start on boot? You won't see a log if it's not running.


Yes, it's running, and I am getting the mail I'm sending to myself (on external accounts).

Bruce Wrote:
Did you try

find /var -name "*log"  

to show all log files under /var?


The only files that indicate anything regarding mail are under /var/qmail/supervise/*, like this:

[root@www var]# cat /var/qmail/supervise/smtp/log/run
#!/bin/sh
LOGSIZE=`cat /var/qmail/control/logsize`
LOGCOUNT=`cat /var/qmail/control/logcount`
exec /usr/bin/setuidgid qmaill /usr/bin/multilog t s$LOGSIZE n$LOGCOUNT /var/log/qmail/smtp 2>&1

This seems to say that logging is redirected to /var/log/qmail/smtp, but that is a directory, which is empty. Might that be the problem? Redirecting stdout and stderr to a directory seems, well, weird...

Nevermind, found it. It's in

/var/log/lxadmin/maillog

as configured in /etc/syslog.conf. Syslog is used since qmail by default uses splogger for logging, which by default uses syslog... oh my.

Given that this seems to be the default setup for your VPS, you may want to stick this into the knowledgebase somewhere...

Thanks for the reply!
Thilo
Reference URL's