Solved

delayed send of emails

Posted on 2004-08-30
14
937 Views
Last Modified: 2013-12-17
Using solaris 2.7 and sendmail
/etc/init.d $ echo \$Z | /usr/lib/sendmail -bt -d0
Version 8.12.11
 Compiled with: DNSMAP LOG MAP_REGEX MATCHGECOS MIME7TO8 MIME8TO7
                NAMED_BIND NDBM NETINET NETUNIX NIS NISPLUS PIPELINING SCANF
                XDEBUG


mails sent with mailx and mail are being deplayed significantly, however mails sent using pine are being sent immediately.
Here is an header
V6
T1093878103
K0
N0
P224671
Fs
$_localhost [127.0.0.1]
$rESMTP
$swilma.showingtime.com
${daemon_flags}
S<root@xxx.xxx.com>
rRFC822; xxx@xxx.xxx.com
RPFD:<xxx@xxx.com>
H?P?Return-Path: <g>

nothing major was noticed while running it in the debug mode ( however Iam not sure if I had the right flags)
The P value indicates the priority, is that the cause?

/etc/init.d $ /usr/lib/sendmail -oQ/var/spool/mqueue
can not chdir(/var/spool/mqueue/): Permission denied
Aug 30 10:34:58 wilma sendmail[3729]: NOQUEUE: SYSERR(root): can not chdir(/var/spool/mqueue/): Permission denied
Program mode requires special privileges, e.g., root or TrustedUser.

How do I force the emails and how do I fix the delay in sending the email?


Thanks
danths


0
Comment
Question by:danths
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 8
  • 6
14 Comments
 
LVL 40

Expert Comment

by:jlevie
ID: 11933339
Since you are running Sendmail 8.12.11 on a Solaris 2.7 system I'd assume that you've manually upgraded Sendmail. When doing so did you set up the MSP instance of Sendmail? 8.12.x is different from 8.11 & prior in that one must run both the usual MTA instance and an MSP instance.  The MSP is used to collect mail from local clients like mailx or from directly invoking sendmail and pass them to the MTA for delivery.

Typically, the MSP would be started with something like:

sendmail -L msp -Ac -q 30m

Also one needs to be aware that 8.12 is much pickier about file/dir ownership that previous versions. All of this covered in the Sendmail Docs included with the 8.12.11 distribution. Exactly what ownership things need to be depends on what was specified when Sendmail was built.
0
 
LVL 6

Author Comment

by:danths
ID: 11933613
thx! for the reply.
I did start the MSP, however even before executing the above command, I was still getting the emails it was just that they were delayed abnormally. Now even after executing the cmd the emails are just queued up...

any thoughts???

output of mailq
========================================================
i7UFjCGU003945X     679 Mon Aug 30 10:45 <CustomerService@xxx.com>
                 (Deferred: Connection refused by moriseiki.co.com.)
                                         <lvale@moriseiki.co>
i7UEdLQt002669X  353254 Mon Aug 30 09:39 <root@server.xxx.com>
                                         <user1@yahoo.com>
i7UEeNxO002715X  353254 Mon Aug 30 09:40 <root@server.xxx.com>
                                         <user1@yahoo.com>
i7UDalZG001720X  353254 Mon Aug 30 08:36 <oracle@server.xxx.com>
                                         <perf-monitors@xxx.com>
i7UEoZc0002914X  353254 Mon Aug 30 09:50 <root@server.xxx.com>
                                         <user2@xxx.com>
                                         <user1@yahoo.com>
0
 
LVL 40

Expert Comment

by:jlevie
ID: 11934153
What command line is used to start the MTA & MSP?

What are the ownership & perms on /var/spool/mqueue & /var/spool/clientmqueue?
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 
LVL 6

Author Comment

by:danths
ID: 11934858
/var/spool $ ls -ld mqueue
drwx------   2 root     root        4608 Aug 30 14:07 mqueue
/var/spool $ ls -ld clientmqueue
drwxrwx---   2 smmsp    smmsp        512 Aug 30 14:01 clientmqueue



0
 
LVL 40

Expert Comment

by:jlevie
ID: 11934924
That looks okay. What about the command lines used to start the MTA & MSP?
0
 
LVL 6

Author Comment

by:danths
ID: 11935062
  smmsp  7562     1  0 14:16:42 ?        0:00 /usr/lib/sendmail -L sm-msp-queue -Ac -q15m
    root  7737  7558  0 14:28:30 ?        0:00 /usr/lib/sendmail -bd -L sm-mta -q15m
    root  7558     1  0 14:16:42 ?        0:00 /usr/lib/sendmail -bd -L sm-mta -q15m
0
 
LVL 40

Expert Comment

by:jlevie
ID: 11935212
That looks okay also. What happens if you do '/usr/lib/sendmail -v -q' as root?
0
 
LVL 6

Author Comment

by:danths
ID: 11935499
/export/home/root/xx $ /usr/lib/sendmail -v -q                                      
/export/home/root/xx $

Nothing.  no output, doesn't that mean that sendmail thinks that there are no messages in the queue.
0
 
LVL 6

Author Comment

by:danths
ID: 11935746
as a side note, the emails which are in the queue are the ones with more than 5 cc addresses or one which are decent sized.

mailq -Ac
/var/spool/clientmqueue is empty
                Total requests: 0

while mailq -v
i7UJB6vL007457X    1808     212255 Aug 30 14:11 email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
i7UJA5Ud007435X    1818     212261 Aug 30 14:10 email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
i7UJ72kD007384X    1822     212266 Aug 30 14:07 email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
i7UJ70EB007382X    1827     212269 Aug 30 14:07 email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
i7UJ70Ox007380X    1844     212294 Aug 30 14:07 email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
                                    email@xxx.com
i7UJHtmw007578X  194330     224667 Aug 30 14:17 email@xxx.com
                                    email@xxx.com



Thanks
0
 
LVL 6

Author Comment

by:danths
ID: 11935945
was reading a bit more on mailq
 The status characters are either
     * to indicate the job is being processed; X to indicate that
     the  load  is too high to process the job; and - to indicate
     that the job is too young to process.  The  following  lines
     show message recipients, one per line.

Now how is the load determined and how can I change it?
0
 
LVL 6

Author Comment

by:danths
ID: 11936124
http://www.uwsg.iu.edu/usail/mail/op/op-sh-4.4.html

more info
# load average at which we just queue messages
#O QueueLA=8
O QueueLA=25

Earlier it was set to O QueueLA=0, I guess "0" is valid for other parms but NOT this. But in any case why would it have worked in the first place, shouldn't everything have been queued up????

I changed the value to 25 and did sendmail -q -v and it immediately started spewing output and sending emails. At this point its purely of academic value but would still like to hear a pausible explanation.

Thanks

0
 
LVL 40

Expert Comment

by:jlevie
ID: 11937366
The default in the M4 files used to build a sendmail.cf is 8, not zero, which is what "#O QueueLA=8" is saying. When you upgraded to 8.12.11 did you build a new sendmail.cf using the cf hierarchy from 8.12.11?
0
 
LVL 6

Author Comment

by:danths
ID: 11941888
Yes, I did and I guess it was around that time I went for 0 rather than 8 with the assumption that no emails will be queued up and will be processed as soon as they are recieved.
0
 
LVL 40

Accepted Solution

by:
jlevie earned 500 total points
ID: 11942363
Oh, so you set QueueLA to 0. As you've found that's a bad thing to do and it was a result of simply misunderstanding what QueueLA is used for.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft has released various new features which are capable of handling various tasks. One of these tasks is ‘Migration from pop3 to Exchange Server’. Pop3 data stores various data along mailboxes like contacts, tasks, etc. So, it becomes the need…
Marketers need statistics and metrics like everybody else needs oxygen. In this article we explain how to enable marketing campaign statistics for Microsoft Exchange mail.
Familiarize people with the process of utilizing SQL Server stored procedures from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Micr…
In this video we show how to create an Address List in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Organization >> Ad…

635 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question