Discussion:
Submit by running sendmail submits to 127.0.0.1 ?
(too old to reply)
John Levine
2024-03-10 02:49:42 UTC
Permalink
I was looking at the logs and saw this when I sent myself a test
message by running sendmail and typing the message:

Mar 9 21:21:36 xxx sendmail[58329]: 42A2LKNa058329: from=jrl396, size=57, class=0, nrcpts=1, msgid=<***@xxx>, relay=***@localhost
Mar 9 21:21:36 xxx sendmail[58608]: 42A2Lah7058608: from=<***@xxx>, size=386, class=0, nrcpts=1, msgid=<***@xxx>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Mar 9 21:21:36 xxx sendmail[58329]: 42A2LKNa058329: to=***@iecc.com, ctladdr=jrl396 (14132/14132), delay=00:00:16, xdelay=00:00:00, mailer=relay, pri=30057, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (42A2Lah7058608 Message accepted for delivery)

It looks like sendmail submitted the message by ESMTP to 127.0.0.1.

So to check that, I telnet'ed to 127.0.0.1 and sending it directly:

Mar 9 21:25:12 xxx sendmail[63488]: 42A2OcIV063488: from=<***@xxx>, size=58, class=0, nrcpts=1, msgid=<***@xxx>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Mar 9 21:25:12 xxx sendmail[64171]: STARTTLS=client, relay=mail.xxx., version=TLSv1/SSLv3, verify=FAIL, cipher=ECDHE-RSA-AES256-GCM-SHA384, bits=256/256

Yup, that worked fine.

Submitting to 127.0.0.1 rather than running sendmail will always be
faster since it's doing less work, right?
--
Regards,
John Levine, ***@taugh.com, Primary Perpetrator of "The Internet for Dummies",
Please consider the environment before reading this e-mail. https://jl.ly
Marco Moock
2024-03-10 07:48:54 UTC
Permalink
Post by John Levine
It looks like sendmail submitted the message by ESMTP to 127.0.0.1.
The MSP (mail submission program, calling sendmail directly to send the
mail) sends it to 127.0.0.1:25 by default. See submit.mc.
Post by John Levine
STARTTLS=client, relay=mail.xxx., version=TLSv1/SSLv3, verify=FAIL,
cipher=ECDHE-RSA-AES256-GCM-SHA384, bits=256/256
Yup, that worked fine.
Submitting to 127.0.0.1 rather than running sendmail will always be
faster since it's doing less work, right?
By default, yes.
At least in Debian, it uses different queues for the MSP and the MTA
and the mail will be saved to both in that situation. See SuperSafe
config option.
If you have slow disks, this can take seconds to finish and go out.
--
kind regards
Marco

Send spam to ***@cartoonies.org
Loading...