weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

Post by Dinesh Nai » Fri, 09 Mar 2001 05:24:26



hey,

just cvsup'ed to what i thought was -stable (RELENG_4), built and installed
world and kernel 12 hours back. uname -a shows FreeBSD 4.3-BETA though.
mergemastered everything in. all works fine, except this odd quirk with sendmail
8.11.3.

i've got sendmail configured (did it new with the upgrade) for
DeliveryMode=deferred and a smart host since i'm on a dialup. when ppp sings
it's mating song and connects, i run 'sendmail -q -v' to clear the queue. i
notice that it seemingly hangs for a long time (50 seconds) before pushing the
mail thru.

whip out ethereal and snoop the ppp0 interface, and here's where i observe this
weird behaviour. i see a flurry of DNS requests for the AAAA (IPv6) record of
the smarthost, but goes out as a IPv4 packet. finally (after 1.5 seconds), an A
record query for the smarthost goes out and is promptly answered by the
nameservers.

then here's the odd part, sendmail attempts to connect (SYN) to port 25 of the
smarthost, but the TTL of the outgoing tcp packet is set to 0. yes, that's zero.
predictably, the next hop returns an ICMP TTL Exceeded packet. this continues
for another 58 seconds and 9 packets. finally, sendmail tries again (on a new
local source port, so it seems to be a new connection) and this time setting the
TTL to the correct value of 64. this connection goes thru and mail gets sent.

problem only exists with sendmail, as telnet, nntp, pop3 and a host of other tcp
proggies work fine. ipv6_enable="NO" in rc.conf and sendmail's DAEMON_OPTIONS
are the default without the addition of IPv6.

i suspect it's a sendmail issue, as nothing else is affected and works the way
it's supposed to. any clues as to what's causing this, as the delay is
irritating and causes me to stay dialled in longer than i really need to.

will be more than happy to send the ethereal libcap saved file to anyone
interested.

--
Regards,                           /\_/\   "All dogs go to heaven."

+==========================----oOO--(_)--OOo----============================+
| for a in past present future; do                                          |
|   for b in clients employers associates relatives neighbours pets; do     |
|   echo "The opinions here in no way reflect the opinions of my $a $b."    |
| done; done                                                                |
+===========================================================================+
   http://pgp.ai.mit.edu/htbin/pks-extract-key.pl?op=get&search=0x230096E9

 
 
 

weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

Post by Steve O'Hara-Smit » Fri, 09 Mar 2001 07:17:36



Quote:> hey,
> just cvsup'ed to what i thought was -stable (RELENG_4), built and installed
> world and kernel 12 hours back. uname -a shows FreeBSD 4.3-BETA though.

        Yes, RELENG_4 is currently labeled 4.3-BETA, soon it will be 4.3-RC, and
(very briefly) 4.3-RELEASE before becoming 4.3-STABLE. Business as usual
in RELENG. Don't worry it's still RELENG_4 or 4-stable.

--
Life is complex - it has real and imaginary parts.

 
 
 

weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

Post by Dinesh Nai » Fri, 09 Mar 2001 11:33:32



>         Yes, RELENG_4 is currently labeled 4.3-BETA, soon it will be 4.3-RC, and
> (very briefly) 4.3-RELEASE before becoming 4.3-STABLE. Business as usual
> in RELENG. Don't worry it's still RELENG_4 or 4-stable.

i was more concerned about the sendmail/TTL issue than over the nomenclature.
thanks for the explanation, though.

--
Regards,                           /\_/\   "All dogs go to heaven."

+==========================----oOO--(_)--OOo----============================+
| for a in past present future; do                                          |
|   for b in clients employers associates relatives neighbours pets; do     |
|   echo "The opinions here in no way reflect the opinions of my $a $b."    |
| done; done                                                                |
+===========================================================================+
   http://pgp.ai.mit.edu/htbin/pks-extract-key.pl?op=get&search=0x230096E9

 
 
 

weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

Post by Dinesh Nai » Fri, 09 Mar 2001 15:48:16



> i was more concerned about the sendmail/TTL issue than over the nomenclature.
> thanks for the explanation, though.

and i might add that when i'm connected to the LAN thru fxp0, sendmail doesnt
exhibit this funny behaviour at all and works as normal. so this begs the
question, what is it about ppp which is causing it to make sendmail and only
sendmail send out SYNs for the first connection with a TTL of 0 ?

--
Regards,                           /\_/\   "All dogs go to heaven."

+==========================----oOO--(_)--OOo----============================+
| for a in past present future; do                                          |
|   for b in clients employers associates relatives neighbours pets; do     |
|   echo "The opinions here in no way reflect the opinions of my $a $b."    |
| done; done                                                                |
+===========================================================================+
   http://pgp.ai.mit.edu/htbin/pks-extract-key.pl?op=get&search=0x230096E9

 
 
 

weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

Post by mic.. » Fri, 09 Mar 2001 17:51:20



Quote:> hey,
> just cvsup'ed to what i thought was -stable (RELENG_4), built and installed
> world and kernel 12 hours back. uname -a shows FreeBSD 4.3-BETA though.
> mergemastered everything in. all works fine, except this odd quirk with sendmail
> 8.11.3.
> i've got sendmail configured (did it new with the upgrade) for
> DeliveryMode=deferred and a smart host since i'm on a dialup. when ppp sings
> it's mating song and connects, i run 'sendmail -q -v' to clear the queue. i
> notice that it seemingly hangs for a long time (50 seconds) before pushing the
> mail thru.
> whip out ethereal and snoop the ppp0 interface, and here's where i observe this
> weird behaviour. i see a flurry of DNS requests for the AAAA (IPv6) record of
> the smarthost, but goes out as a IPv4 packet. finally (after 1.5 seconds), an A
> record query for the smarthost goes out and is promptly answered by the
> nameservers.

This problem has been discussed some time ago on freebsd-stable mailing list.
One of the ways to solve it was to recompile sendmail if i remeber well
without IPV6 support, or was it named? For sure i have no such problem
on my boxes, in particular this laptop on which i type, and i have
cvsupped it recently. Note also that i have disabled IPV6 in kernel
config file.

--
Michel Talon

 
 
 

weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

Post by Per Hedela » Sat, 10 Mar 2001 07:48:11





>> i was more concerned about the sendmail/TTL issue than over the nomenclature.
>> thanks for the explanation, though.

>and i might add that when i'm connected to the LAN thru fxp0, sendmail doesnt
>exhibit this funny behaviour at all and works as normal. so this begs the
>question, what is it about ppp which is causing it to make sendmail and only
>sendmail send out SYNs for the first connection with a TTL of 0 ?

Well, sendmail most certainly doesn't "set" the TTL either to 0 or to
anything else - AFAIK there isn't even a way to do that from user-level
via the socket interface - nor does it "know" whether the connection is
via PPP or not. Have you tried with something else making the first TCP
connection on the newly-established PPP link?

--Per Hedeland

 
 
 

weird behaviour: sendmail/freebsd 4.3-BETA fails to connect due to TTL

Post by Dinesh Nai » Sat, 10 Mar 2001 15:59:17



> This problem has been discussed some time ago on freebsd-stable mailing list.
> One of the ways to solve it was to recompile sendmail if i remeber well
> without IPV6 support, or was it named? For sure i have no such problem

that fixed it. thanx michel.

--
Regards,                           /\_/\   "All dogs go to heaven."

+==========================----oOO--(_)--OOo----============================+
| for a in past present future; do                                          |
|   for b in clients employers associates relatives neighbours pets; do     |
|   echo "The opinions here in no way reflect the opinions of my $a $b."    |
| done; done                                                                |
+===========================================================================+
   http://pgp.ai.mit.edu/htbin/pks-extract-key.pl?op=get&search=0x230096E9