Sendmail delay: 3 mins 11 secs... Every time.

sendmail, solaris, solaris 11.3, solved

Thread Tools Search this Thread
# 1  
Old 09-01-2017
Sendmail delay: 3 mins 11 secs... Every time.

Hi all,
I would like some help with a sendmail problem:
We have a new system comprising of 4 T7-1 servers, each hosting 5 LDOMs, all domains running Solaris 11.3
All emails sent from every one of these domains (including the control domains) sit in the queue for 3 mins 11 secs (sometime 3m 12s, or 3m 13s) before being delivered.
I've exhausted my googling skills investigating red herrings and blind alleys and now I'm stumped.
I have included some sanitised output below, showing the problem. I used "sendmail -v" here purely for the verbose output: The same delay occurs with mailx.
Any help would be greatly appreciated.
root@myldom:~# sendmail -v < test.txt Connecting to [] via relay...
220 ESMTP Sendmail 8.15.1+Sun/8.15.1; Thu, 31 Aug 2017 16:33:21 +0100 (BST)
>>> EHLO Hello [], pleased to meet you
250 HELP
>>> VERB
250 2.0.0 Verbose mode
>>> MAIL From:<> SIZE=21
250 2.1.0 <>... Sender ok
>>> RCPT To:<>
>>> DATA
250 2.1.5 <>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .

# (Wait 3 mins 11 secs...)

050 <>... Connecting to via esmtp...
050 <>... Connecting to via esmtp...
050 220 Microsoft ESMTP MAIL Service ready at Thu, 31 Aug 2017 16:36:31 +0100
050 >>> EHLO
050 Hello []
050 250-SIZE 37748736
050 250-DSN
050 250-STARTTLS
050 250-AUTH NTLM
050 250-8BITMIME
050 250-CHUNKING
050 250 XRDST
050 >>> STARTTLS
050 220 2.0.0 SMTP server ready
050 >>> EHLO
050 Hello []
050 250-SIZE 37748736
050 250-DSN
050 250-8BITMIME
050 250-CHUNKING
050 250 XRDST
050 >>> MAIL From:<> SIZE=382
050 250 2.1.0 Sender OK
050 >>> RCPT To:<>
050 >>> DATA
050 250 2.1.5 Recipient OK
050 354 Start mail input; end with <CRLF>.<CRLF>
050 >>> .
050 250 2.6.0 <> [InternalId=80298708569789,] Queued mail for delivery
050 <>... Sent (<> [InternalId=80298708569789,] Queued mail for delivery)
250 2.0.0 v7VFXLXx006528 Message accepted for delivery Sent (v7VFXLXx006528 Message accepted for delivery)
Closing connection to []
>>> QUIT
221 2.0.0 closing connection

During the delay before sending, I ran the following in another session:

root@myldom:~# mailq;sendmail -v -q
                /var/spool/mqueue (1 request)
-----Q-ID----- --Size-- -----Q-Time----- ------------Sender/Recipient-----------
v7VFXLXx006528*      21 Thu Aug 31 16:33 <myuser@myldom.fqdn.
                Total requests: 1

Running /var/spool/mqueue/v7VFXLXx006528 (sequence 1 of 1)
v7VFXLXx006528: locked

... And this is what appears in the log:

root@myldom:~# grep v7VFXLXx006528 /var/log/syslog
Aug 31 16:33:21 myldom sendmail[6528]: [ID 801593] v7VFXLXx006528: from=<>, size=382, class=0, nrcpts=1, msgid=<>, proto=ESMTP, daemon=MTA-v4, []
Aug 31 16:36:34 myldom sendmail[6528]: [ID 801593] v7VFXLXx006528: to=<>, ctladdr=<> (111/100), delay=00:03:13, xdelay=00:03:13, mailer=esmtp, pri=30382, 

[], dsn=2.0.0, stat=Sent (<> [InternalId=80298708569789,] Queued mail for delivery)
Aug 31 16:36:34 myldom sendmail[6527]: [ID 801593] v7VFXK30006527:, ctladdr=myuser (111/100), delay=00:03:14, xdelay=00:03:13, mailer=relay, pri=30021, relay=[] [], dsn=2.0.0, stat=Sent 

(v7VFXLXx006528 Message accepted for delivery)

Many thanks in advance

Moderator's Comments:
Mod Comment Please use CODE tags as required by forum rules!

Last edited by RudiC; 09-01-2017 at 07:37 AM.. Reason: Added CODE tags.
# 2  
Old 09-01-2017
Welcome to the forum.

With a delay not attributable to an evident cause, I always suspect a DNS timeout, although more than 3 mins seems very long, and I don't see unresolved addresses in the log.
This User Gave Thanks to RudiC For This Post:
Mysturji (09-05-2017)
# 3  
Old 09-01-2017
Hi Rudi (Oops, RE: code tags)
We do use DNS internally, but FQDNs are in the local hosts files as well.
The weird thing is, it doesn't even seem to try to send it for over 3 minutes. It's like there's a config item that says "wait this long before sending mail" but I can't find it.
Both & (and their corresponding .mc files) seem to be default unmodified.
# 4  
Old 09-01-2017
Assuming sendmail daemon is active:

the sendmail daemon can be set up with queueing - meaning send out mail every x minutes.

There are .cf files in the mail directory tree in /etc. (you did this) Read though them and see what is set. (queueing control can be set here, too): Also review the command used to start smtp (sendmail), there are usually two sendmail processes.

I would help but I do not have a unix box here, and sendmail is beastly in how it does things. I do not remember.

You may also need to check if the box that has the problem has an active mail server or if the smtp request is forwarded to another box.
This User Gave Thanks to jim mcnamara For This Post:
Mysturji (09-05-2017)
# 5  
Old 09-01-2017
This is for solaris 10 - but I think the directories are the same most places.
And can be changed in the .cf files.
Administering the Queue Directories - Managing sendmail Services in Oracle Solaris 11.1

mqueue directory should be in /var/spool tree.
This User Gave Thanks to jim mcnamara For This Post:
Mysturji (09-05-2017)
# 6  
Old 09-01-2017
Hi Jim,
Sendmail daemon is active.

You said:
the sendmail daemon can be set up with queueing - meaning send out mail every x minutes.
How? Presumably it can also be configured to send mail immediately... How?
I'm afraid the contents of the .cf files are hieroglyphics to me.

I came late to this project and this was already set up when I arrived, but as far as I can tell, there has been no customisation done to sendmail - it's all 'out of the box'. There is next to nothing in the and files, and they and the .cf files are all quite old, so presumably the first build.

That link says:
2. Force queue processing and display the progress of the jobs as the queue is cleared.
# /usr/lib/sendmail -q -v

When I ran
sendmail -v -q

(I assumed the "q" meant "query") it replied:
v7VFXLXx006528: locked

To me, this seems intentional. But how? Smilie

It looks like the email is sent to the localhost over the loopback interface and is accepted, then it sits there waiting for a timer to run out before it gets sent on to the Exchange server and actually delivered.
# 7  
Old 09-01-2017
If you're running with 'out of the box' default configuration then in /etc/mail/ the "smart" relay host line probably says:


Try changing that to


That will tell it that its relay host is itself.

---------- Post updated at 04:42 PM ---------- Previous update was at 04:36 PM ----------

Although, of course, there's a delay because the mail daemon wakes up regularly to process mail, I wouldn't have thought that a problem with it would give you the exact same delay every time. So I conclude that this sounds like a configuration issue such as above.
These 2 Users Gave Thanks to hicksd8 For This Post:
jim mcnamara (09-01-2017) Mysturji (09-04-2017)

Thread Tools Search this Thread
Search this Thread:
Advanced Search

More UNIX and Linux Forum Topics You Might Find Helpful
Script to find directory is getting files in every 10 mins, if not then when last time file received sadique.manzar Shell Programming and Scripting 6 08-13-2018 06:07 PM
Sendmail delaying mails for 45 mins badoshi Solaris 4 12-16-2013 04:35 PM
How to get past 30 mins time in Solaris? ambious Shell Programming and Scripting 4 08-06-2013 07:23 AM
Time delay problem in asking password solaris_1977 Emergency UNIX and Linux Support 9 08-31-2012 11:20 AM
Delay in sending email to-from localhost in Sendmail Rohit Bhanot Red Hat 0 06-23-2012 01:15 AM
Login delay after entering id (40 secs) same after entering pw longjon Solaris 8 02-07-2012 07:16 AM
getting time mins ago cka UNIX for Advanced & Expert Users 6 01-05-2011 03:28 PM
how to calculate the time 10 mins ago?? unix k00061804 Shell Programming and Scripting 7 11-17-2010 07:57 AM
Time delay for awk kristinu Shell Programming and Scripting 3 10-24-2010 10:40 AM
Output of prstat for 60 secs nessj Shell Programming and Scripting 3 06-29-2010 07:51 AM
Calculating delay time - bash jbsimon000 Shell Programming and Scripting 5 04-14-2009 12:54 PM
ls -e to find out File modification time in secs rahulkav Shell Programming and Scripting 3 09-12-2008 12:04 PM
how to find difference of 2 timestamps in secs? Alecs UNIX for Dummies Questions & Answers 0 03-24-2008 01:36 PM
lock time delay part-time-user Solaris 2 06-01-2005 05:04 PM
Reduce boot-time delay on FreeBSD? DownSouthMoe BSD 1 03-28-2004 03:07 AM