@40000000429254a51e1b254c tcpserver: status: 1/40
@40000000429254a51e1b3cbc tcpserver: pid 32384 from 206.106.137.9
@40000000429254a53037f4bc tcpserver: ok 32384 :::ffff:192.168.133.1:25
:::ffff:206.106.137.9::50816
@40000000429254a6020ef07c tcpserver: end 32384 status 256
What is status 256?
I tried to google it, tried to look at tcpserver code, but I am totally
lost.
Any ideas appreciated. Thanks.
> tcpserver is dropping some of the email before it get's to
> qmail-smtpd. I am able to receive mail from many
> servers.. yahoo. hotmail, and many other. However, I can see in the
> qmail-smtpd log that many mail is not getting accepted from some of
> the domains...
>
> @40000000429254a51e1b254c tcpserver: status: 1/40
> @40000000429254a51e1b3cbc tcpserver: pid 32384 from 206.106.137.9
> @40000000429254a53037f4bc tcpserver: ok 32384 :::ffff:192.168.133.1:25
> :::ffff:206.106.137.9::50816
> @40000000429254a6020ef07c tcpserver: end 32384 status 256
>
> What is status 256?
It means that qmail-smtpd exited with an error status. There are many
possible reasons that can occur. One way to find out exactly what's
happening is to use recordio to record the complete SMTP dialogue in
the logs. In an LWQ installation, you'd replace the following:
exec /usr/local/bin/softlimit -m 2000000 \
/usr/local/bin/tcpserver -v -R -l "$LOCAL" -x /etc/tcp.smtp.cdb -c "$MAXSMTPD" \
-u "$QMAILDUID" -g "$NOFILESGID" 0 smtp /var/qmail/bin/qmail-smtpd 2>&1
with:
exec /usr/local/bin/softlimit -m 2000000 \
/usr/local/bin/tcpserver -v -R -l "$LOCAL" -x /etc/tcp.smtp.cdb -c "$MAXSMTPD" \
-u "$QMAILDUID" -g "$NOFILESGID" 0 smtp
/usr/local/bin/recordio \
/var/qmail/bin/qmail-smtpd 2>&1
in /var/qmail/supervise/qmail-smtpd/run and do:
svc -t /service/qmail-smtpd
Then keep an eye on /var/log/qmail/smtpd/current.
--
Dave Sill Oak Ridge National Lab, Workstation Support
Author, The qmail Handbook <http://web.infoave.net/~dsill>
<http://lifewithqmail.org/>: Almost everything you always wanted to know.
First, a little bit more background. As far as I can see, it's not a
qmail problem per se, but I am trying to understand exactly what
qmail-smtpd doesn't like.
I am using gentoo linux, with the qmail "ebuild" provided by gentoo
package maintainers. This problem started when I "upgraded" my qmail
from 1.03-r13 to 1.03-r15.
Anyways, they added the fixcrio program in the QMAIL_SMTP_PRE (see
below), among many other changes. I was initially very happy that I
finally started receiving some email from some broken SMTP servers that
have bare linefeed problems. BUT, now I do not receive some other email
- the example is in my original post.
So following your direction, I modify my gentoo linux boxes'
/var/qmail/control/conf-smtpd from
QMAIL_SMTP_PRE="${QMAIL_SMTP_PRE} rblsmtpd -r sbl-xbl.spamhaus.org"
to
QMAIL_SMTP_PRE="${QMAIL_SMTP_PRE} /usr/bin/recordio rblsmtpd -r
sbl-xbl.spamhaus.org"
btw, I tried putting recordio after rblsmtpd as well, same result.
Works great - full log of SMTP dialog is recorded in log. However,
adding either recordio or fixcrio is causing the mail to be rejected -
dialog follows (with fixcrio REMOVED, recordio ADDED)
@40000000429377ad08f69034 tcpserver: status: 1/40
@40000000429377ad08f6ab8c tcpserver: pid 19438 from 206.106.137.9
@40000000429377ad184036bc tcpserver: ok 19438 :::ffff:192.168.133.1:25
:::ffff:206.106.137.9::41191
40000000429377ad25414504 19438 > 220 icalyx.com ESMTP
40000000429377ad27b3e314 19438 < EHLO mx1.interactivebrokers.com
40000000429377ad27b8a1ec 19438 > 250-icalyx.com
40000000429377ad27b8ada4 19438 > 250-STARTTLS
40000000429377ad27b8b574 19438 > 250-SIZE 0
40000000429377ad27b8bd44 19438 > 250-PIPELINING
40000000429377ad27b8c514 19438 > 250 8BITMIME
40000000429377ad2ac8cfec 19438 < STARTTLS
40000000429377ad2aee3df4 19438 > 220 ready for tls
@40000000429377ad2d43fd64 19438 < jQ
@40000000429377ad2d4414d4 19438 < Àedcba` #WÌFµð7Ü&©d+
@40000000429377ad2d6694dc 19438 > [EOF]
@40000000429377ad2d66b034 tcpserver: end 19438 status 256
However, with both fixcrio & recordio removed, this smtp conversation
works fine, with mail being accepted. With only fixcrio, I know I get a
status 256, but have no further details.
I am at a loss to what else can be done.
Thanks!
> I am using gentoo linux, with the qmail "ebuild" provided by gentoo
> package maintainers. This problem started when I "upgraded" my qmail
> from 1.03-r13 to 1.03-r15.
>
> ...
>
> Works great - full log of SMTP dialog is recorded in log. However,
> adding either recordio or fixcrio is causing the mail to be rejected -
> dialog follows (with fixcrio REMOVED, recordio ADDED)
>
> @40000000429377ad08f69034 tcpserver: status: 1/40
> @40000000429377ad08f6ab8c tcpserver: pid 19438 from 206.106.137.9
> @40000000429377ad184036bc tcpserver: ok 19438 :::ffff:192.168.133.1:25
> :::ffff:206.106.137.9::41191
> 40000000429377ad25414504 19438 > 220 icalyx.com ESMTP
> 40000000429377ad27b3e314 19438 < EHLO mx1.interactivebrokers.com
> 40000000429377ad27b8a1ec 19438 > 250-icalyx.com
> 40000000429377ad27b8ada4 19438 > 250-STARTTLS
> 40000000429377ad27b8b574 19438 > 250-SIZE 0
> 40000000429377ad27b8bd44 19438 > 250-PIPELINING
> 40000000429377ad27b8c514 19438 > 250 8BITMIME
> 40000000429377ad2ac8cfec 19438 < STARTTLS
> 40000000429377ad2aee3df4 19438 > 220 ready for tls
> @40000000429377ad2d43fd64 19438 < jQ
> @40000000429377ad2d4414d4 19438 < Àedcba` #WÌFµð7Ü&©d+
> @40000000429377ad2d6694dc 19438 > [EOF]
> @40000000429377ad2d66b034 tcpserver: end 19438 status 256
>
> However, with both fixcrio & recordio removed, this smtp conversation
> works fine, with mail being accepted. With only fixcrio, I know I get
> a status 256, but have no further details.
>
> I am at a loss to what else can be done.
Something in the Gentoo ebuild is broken. You'll probably have to
contact the maintainer of that package for help. Vanilla qmail doesn't
exhibit this behavior. It might be significant that that was a TLS
session.
So, bottom line, if I want TLS, I should not use fixcrio
Do you agree with this? If so, all I can say is - learnt a new thing,
but spent too much time doing so.
On a related note, if I can't use fixcrio, and keep using TLS, is there
a patch or other way to kill off that barelinefeed mail refusal? I know
it's bad and all that - but email is email - I want those ones 8(
Thanks!
> The gentoo package maintainers pointed me to this -
> http://iain.cx/ssl/?qmailtls
>
> So, bottom line, if I want TLS, I should not use fixcrio
>
> Do you agree with this? If so, all I can say is - learnt a new thing,
> but spent too much time doing so.
Yeah, it makes sense. If the TLS stream contains any LFs, then fixcrio
will "fix" them into CR-LF and corrupt the TLS data.
> On a related note, if I can't use fixcrio, and keep using TLS, is
> there a patch or other way to kill off that barelinefeed mail refusal?
> I know it's bad and all that - but email is email - I want those ones
> 8(
Yeah, there's probably a patch somewhere. I've never needed fixcrio
myself, so I'm kinda suprised you do.
# fixcrio inserts missing CRs at the ends of lines. See:
# http://cr.yp.to/ucspi-tcp/fixcrio.html
# http://cr.yp.to/docs/smtplf.html
# DO NOT enable this, when you are using SSL/TLS (USE=ssl)!
#QMAIL_SMTP_PRE="${QMAIL_SMTP_PRE} fixcrio"
But I'm getting the same status 256 issue on TLS conversations. I
think it's an openssl problem. Please see and (answer if possible) my
post on TLS Handshake Problem.
ded
Tcpserver error 256 should not and is not of any meaningul consequence.
It simply means that the connection was terminated before tcpserver was
ready.
I.e. a connection is established.
The session is completed.
A quit is issued.tcpserver waits for 10 seconds to terminate the TCP
session while the remote end drops/terminates the connection in 9. Or
the timeout for a session to termine is shorted then the amount of time
needed for the tcp scheme to disingage the connection.
The only time 256 tcpserver might have an adverse is during an smtp
session when a response following the data command (possible duplicate
issue).
Unless this is what you are seeing and are trying to prevent, error 256
can be relagated to mean nothing.
AK