D
D
Dmitry Sidorenko2015-11-16 15:51:16
send mail
Dmitry Sidorenko, 2015-11-16 15:51:16

Why does sendmail hang for 40 seconds before sending mail?

Centos 7
In the console I enter

echo "Subject:тема письма" | /usr/sbin/sendmail -f "[email protected]" "[email protected]"

and everything thinks for 40 seconds.
The letter arrives successfully
domkaminov.ru/mail.php there is a simple mail sending script:
<?php
error_reporting(E_ALL);
$mail = mail('[email protected]', 'Test message', 'Testing email function');
var_dump($mail);
?>
and it also freezes the page for about a minute, but works out.
All today I have been reading information on this topic
Server, by the way, from Slectel (they have terrible support and they often crash), but the project is educational, so it's tolerable.
I found a similar problem here Selectel, Ubuntu 10.04, sendmail hard stupefied but did not understand its solution at all =)
I found the error log, here is its content:
vi /var/log/maillog
Nov 16 14:46:58 lokhaym sendmail[753]: My unqualified host name (lokhaym) unknown; sleeping for retry
Nov 16 14:47:13 lokhaym sendmail[2238]: My unqualified host name (lokhaym) unknown; sleeping for retry
Nov 16 14:47:58 lokhaym sendmail[753]: unable to qualify my own domain name (lokhaym) -- using short name
Nov 16 14:47:58 lokhaym sendmail[2239]: starting daemon (8.14.7): [email protected]:00:00
Nov 16 14:47:59 lokhaym sm-msp-queue[2248]: My unqualified host name (lokhaym) unknown; sleeping for retry
Nov 16 14:48:13 lokhaym sendmail[2238]: unable to qualify my own domain name (lokhaym) -- using short name
Nov 16 14:48:14 lokhaym sendmail[2238]: tAGBmDcO002238: [email protected], size=30, class=0, nrcpts=1, msgid=<[email protected]>, [email protected]
Nov 16 14:48:14 lokhaym sendmail[2250]: tAGBmEan002250: from=<[email protected]>, size=290, class=0, nrcpts=1, msgid=<[email protected]>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Nov 16 14:48:14 lokhaym sendmail[2238]: tAGBmDcO002238: [email protected], [email protected] (0/0), delay=00:00:01, xdelay=00:00:00, mailer=relay, pri=30030, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (tAGBmEan002250 Message accepted for delivery)
Nov 16 14:48:14 lokhaym sendmail[2252]: STARTTLS=client, relay=gmail-smtp-in.l.google.com., version=TLSv1/SSLv3, verify=FAIL, cipher=ECDHE-RSA-AES128-GCM-SHA256, bits=128/128
Nov 16 14:48:15 lokhaym sendmail[2252]: tAGBmEan002250: to=<[email protected]>, delay=00:00:01, xdelay=00:00:01, mailer=esmtp, pri=120290, relay=gmail-smtp-in.l.google.com. [173.194.71.26], dsn=2.0.0, stat=Sent (OK 1447674495 or9si25620074lbb.110 - gsmtp)
Nov 16 14:48:59 lokhaym sm-msp-queue[2248]: unable to qualify my own domain name (lokhaym) -- using short name
Nov 16 14:48:59 lokhaym sm-msp-queue[2255]: starting daemon (8.14.7): [email protected]:00:00
Nov 16 14:49:08 lokhaym sendmail[2272]: My unqualified host name (lokhaym) unknown; sleeping for retry
Nov 16 14:50:08 lokhaym sendmail[2272]: unable to qualify my own domain name (lokhaym) -- using short name
Nov 16 14:50:08 lokhaym sendmail[2272]: tAGBo8KK002272: [email protected], size=30, class=0, nrcpts=1, msgid=<[email protected]>, [email protected]

Thanks in advance!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
alegzz, 2015-11-16
@sidorenkoda

add "lokhaym" to /etc/hosts?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question