# qmail and recordio

## principito

Ok sorry if I'm a bit ignorant, but I'm having problems getting full SMTP logs w/ qmail and recordio. there is some documentation on Qmails webpage but it says:

 *Quote:*   

> 
> 
> Simply insert recordio before qmail-smtpd. SMTP traffic will be sent to syslog. 
> 
> 

 

Thats not very good explanation for someone who has never used qmail before.

I have a file: 

/service/qmail-smtpd/run

which contains the following:

```

#!/bin/sh

QMAILDUID=`id -u qmaild`

NOFILESGID=`id -g qmaild`

exec /usr/bin/softlimit -m 2000000 \

        /usr/bin/tcpserver -H -R -v -p -x /etc/tcp.smtp.cdb \

        -u $QMAILDUID -g $NOFILESGID 0 smtp rblsmtpd \

        /var/qmail/bin/qmail-smtpd 2>&1

```

I assume I put recordio in there somewhere. But where? Am I on the totally wrong track? And once I find out where to put recordio where does it log too? I have /var/log/all setup w/ msyslog that should catch it I hope.

Any help is appreciated.

Thanks in advance.

-Mike

----------

## ves

try this...

#!/bin/sh 

QMAILDUID=`id -u qmaild` 

NOFILESGID=`id -g qmaild` 

exec /usr/bin/softlimit -m 2000000 \ 

        /usr/bin/tcpserver -H -R -v -p -x /etc/tcp.smtp.cdb \ 

        -u $QMAILDUID -g $NOFILESGID 0 smtp rblsmtpd \ 

        /var/qmail/bin/qmail-smtpd | /var/qmail/bin/splogger smtpd 3 & 

that'll send it to syslog...

----------

## principito

that doesn't seem to catch everything.... just a few things

I want to get the actuall message (I'm testing something from a program)

----------

## ves

what are you trying to log then?  That will just log smtp connections...if you want to log mail deliveries or pop3 connections, you need to setup logging for that too...

----------

## principito

I heard that w/ the daemontools program recordio you can get the whole SMTP connection to the machine from the 

EHLO blah.com

MAIL FROM: <look@me.com>

all the way to the

.

I guess I could TCP dump or packetsniff... just figured if it was built in it would be easier.

thanks

----------

## ves

ahh i see...nevermind.

erm, well i've never used recordio, but try putting that after the pipe.

----------

