Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

tuning Load Average for sendmail

984 views
Skip to first unread message

RICCARDO

unread,
May 13, 2010, 4:11:52 AM5/13/10
to
I'm using sendmail 8.12.10-1.1.1 and amavisd (with linked uvscan) for
my mail server, which process about 700 mail messages a day.There is
no other software on this mail server...
In maillog files I can see "rejecting connections on daemon MTA: load
average: XX" where XX is a number among 12 and 36. It occurs in a
changeable time, 40÷ 240 messages of rejecing connections" a day.
My sendmail.cf says:

#O QueueLA=8
#O RefuseLA=12
#O DelayLA=0

Can I modify it in this way ?
What do you think ?

#O QueueLA=20
#O RefuseLA=36
#O DelayLA=0

Or I can try to disable uvscan process to reduce load average ?

Andrzej Adam Filip

unread,
May 13, 2010, 6:27:48 AM5/13/10
to

1) Do you run your sendmail on Linux?
YES => Linux count LA unlike other OSes - it counts IO-waiting too

Nick stated he usually used RefuseLA between 12 and 20 on non Linux OSes
(based on *many* factors).

References:
pages 139-140
http://www.amazon.com/sendmail-Performance-Tuning-Nick-Christenson/dp/0321115708
http://www.jetcafe.org/~npc/book/sendmail/


2) Do you use some DNSBLs to block connections from "low reputation"
sources before using more "CPU hungry filtering"?

Optimizing SMTP mail servers is almost always about *peak* load,
it is hardly ever about average load -> your load peaks are quite
likely caused by spam peaks (with 700 mails a day).

--
[pl>en Andrew] Andrzej Adam Filip : an...@onet.eu : Andrze...@gmail.com
http://open-sendmail.sourceforge.net/ http://anfi.homeunix.org/
I never killed a man that didn't deserve it.
-- Mickey Cohen

RICCARDO

unread,
May 13, 2010, 3:40:19 PM5/13/10
to
On 13 Mag, 12:27, Andrzej Adam Filip <a...@onet.eu> wrote:

> RICCARDO <ric.castell...@alice.it> wrote:
> > I'm using sendmail 8.12.10-1.1.1 and amavisd (with linked uvscan) for
> > my mail server, which process about 700 mail messages a day.There is
> > no other software on this mail server...
> > In maillog files I can see "rejecting connections on daemon MTA: load
> > average: XX" where XX is a number among 12 and 36. It occurs in a
> > changeable time, 40÷ 240 messages of rejecing connections" a day.
> > My sendmail.cf says:
>
> > #O QueueLA=8
> > #O RefuseLA=12
> > #O DelayLA=0
>
> > Can I modify it in this way ?
> > What do you think ?
>
> > #O QueueLA=20
> > #O RefuseLA=36
> > #O DelayLA=0
>
> > Or I can try to disable uvscan process to reduce load average ?
>
> 1) Do you run your sendmail on Linux?
> YES => Linux count LA unlike other OSes - it counts IO-waiting too
>
> Nick stated he usually used RefuseLA between 12 and 20 on non Linux OSes
> (based on *many* factors).
>
> References:
>  pages 139-140
>  http://www.amazon.com/sendmail-Performance-Tuning-Nick-Christenson/dp...

>  http://www.jetcafe.org/~npc/book/sendmail/
>
> 2) Do you use some DNSBLs to block connections from "low reputation"
> sources before using more "CPU hungry filtering"?
>
> Optimizing SMTP mail servers is almost always about *peak* load,
> it is hardly ever about average load -> your load peaks are quite
> likely caused by spam peaks (with 700 mails a day).
>
> --
> [pl>en Andrew] Andrzej Adam Filip : a...@onet.eu : Andrzej.Fi...@gmail.comhttp://open-sendmail.sourceforge.net/http://anfi.homeunix.org/

> I never killed a man that didn't deserve it.
>   -- Mickey Cohen

1) Yes I run my sendmail on Linux, Fedora Core 1
Do you think 36 as RefuseLA value is too high ?

2) Yes I'm using some DNSBLs to block connections but using firewall
which is before my mail server , even if I have problems with them
because it often occurs
mail servers, which are used by customers, go to these blacklists.
Do you know reliable DNSBL to use ?
Have you got suggestions to reduce peak ?

Joe Zeff

unread,
May 13, 2010, 5:42:37 PM5/13/10
to
On Thu, 13 May 2010 12:40:19 -0700, RICCARDO wrote:

> 1) Yes I run my sendmail on Linux, Fedora Core 1

You do realize, don't you, that FC 1 is seven years out of date, and
almost that long past End of Support? The current version is Fedora 12,
with Fedora 13 coming out within the month. I doubt that this is part of
the issue, but still, you might at least consider upgrading to a more
recent version on general principles. Or, if you're more concerned with
stability, consider CentOS.

--
Joe Zeff -- The Guy With The Sideburns:
http://www.zeff.us http://www.lasfs.info
A Jewish friend once, as he termed it, "summarised" Jewish holidays
to me: "They tried to kill us. We won. Let's eat."

David F. Skoll

unread,
May 13, 2010, 10:31:59 PM5/13/10
to
RICCARDO wrote:

> #O QueueLA=8
> #O RefuseLA=12
> #O DelayLA=0

The Sendmail defaults are utterly inappropriate for Linux. I use:

O QueueLA=1000
O RefuseLA=500

Or in .mc language:

define(`confQUEUE_LA',`1000')dnl
define(`confREFUSE_LA',`500')dnl

In other words, I don't want sendmail to stop, regardless of load
average. And I *certainly* don't want it queueing, but not
delivering, if the load average is high.

I have seen Linux boxes with load averages over 200 happily processing mail.

Regards,

David.

Andrzej Adam Filip

unread,
May 13, 2010, 11:22:52 PM5/13/10
to

For my curiosity:
Is there a way to get "non Linux" LA (Load Average) on Linux?
[ LA without processes in IO-waiting state ]

--

People never lie so much as after a hunt, during a war, or before an election.
-- Otto Von Bismarck

RICCARDO

unread,
May 14, 2010, 4:30:41 AM5/14/10
to
On 13 Mag, 23:42, Joe Zeff <the.guy.with.the.sidebu...@lasfs.info>
wrote:

> On Thu, 13 May 2010 12:40:19 -0700, RICCARDO wrote:
> > 1) Yes I run my sendmail on Linux, Fedora Core 1
>
> You do realize, don't you, that FC 1 is seven years out of date, and
> almost that long past End of Support?  The current version is Fedora 12,
> with Fedora 13 coming out within the month.  I doubt that this is part of
> the issue, but still, you might at least consider upgrading to a more
> recent version on general principles.  Or, if you're more concerned with
> stability, consider CentOS.
>
> --
> Joe Zeff -- The Guy With The Sideburns:http://www.zeff.ushttp://www.lasfs.info

> A Jewish friend once, as he termed it, "summarised" Jewish holidays
> to me: "They tried to kill us.  We won.  Let's eat."

I agrre you infact I'm going to upgrade but now I have to solve
problem.
For stability I know debian is good os.

Per Hedeland

unread,
May 14, 2010, 4:41:08 AM5/14/10
to
In article <66f9a$4becb619$d1d97a75$29...@PRIMUS.CA> "David F. Skoll"

<d...@roaringpenguin.com> writes:
>RICCARDO wrote:
>
>> #O QueueLA=8
>> #O RefuseLA=12
>> #O DelayLA=0
>
>The Sendmail defaults are utterly inappropriate for Linux. I use:
>
>O QueueLA=1000
>O RefuseLA=500
>
>Or in .mc language:
>
>define(`confQUEUE_LA',`1000')dnl
>define(`confREFUSE_LA',`500')dnl
>
>In other words, I don't want sendmail to stop, regardless of load
>average. And I *certainly* don't want it queueing, but not
>delivering, if the load average is high.

This is an important point - whether Linux or not, and regardless of the
absolute size of the numbers, on a dedicated mail server you always want
to have QueueLA higher than RefuseLA. The defaults are from an ancient
time when processing mail was typically just one of many tasks on a
general-purpose server, and you didn't want it to impact more
"interactive" functions at times of high load. If the load is *caused*
by mail processing, having QueueLA lower than RefuseLA will just make
things worse.

--Per Hedeland
p...@hedeland.org

Andrzej Adam Filip

unread,
May 14, 2010, 6:12:01 AM5/14/10
to

You are most likely right in *most* cases but I would not dare such
"too simple statement" - there are exceptions (e.g. with "costly" local
mailer forking one process per recipient under multiple recipient load).

For postmaster chasing "simplicity" sendmail is hardly ever the
preferred choice nowdays, is not it? :-)

--
http://open-sendmail.sourceforge.net/ http://anfi.homeunix.org/
It's getting harder and harder to think out loud. One of these days
someone's gonna go off and kill Thomas a'Becket for me...
-- Larry Wall in <1997092420...@wall.org>

Andrzej Adam Filip

unread,
May 14, 2010, 6:20:40 AM5/14/10
to
RICCARDO <ric.cas...@alice.it> wrote:
> [...]

> 1) Yes I run my sendmail on Linux, Fedora Core 1
> Do you think 36 as RefuseLA value is too high ?

Current Fedora Core release and "LA for Linux" has been covered in
replies by other people.

> 2) Yes I'm using some DNSBLs to block connections but using firewall
> which is before my mail server , even if I have problems with them
> because it often occurs mail servers, which are used by customers, go
> to these blacklists. Do you know reliable DNSBL to use ?
> Have you got suggestions to reduce peak ?

Could you create list of your customers nets/ip addresses to exclude
them from DNSBL checks?
[It is possible via "X OK" entries in access table]

Have you considered using "variable strength" checks based on
"country of origin"?
[There are IP_address->country maps available via DNS]

e.g. using FEATURE(`anfi/rsdnsbl') you can use "basic checks" for
"near by countries"/neighbors, add some check for all other countries
and some extra (very picky) checks for "black sheep" countries.

<Stealth> How do I bind a computer to an NIS server?
<Joey> Use a rope?
-- Seen on #Debian

Joe Zeff

unread,
May 14, 2010, 1:07:19 PM5/14/10
to
On Fri, 14 May 2010 01:30:41 -0700, RICCARDO wrote:

> I agrre you infact I'm going to upgrade but now I have to solve problem.
> For stability I know debian is good os. What do you think ?

*Shrug!* The only debian I know is Ubuntu, because my sister uses it and
I'm her support. Going from FC 1 to CentOS has the advantage of keeping
you in a RedHad-based distro, meaning that the package management is
sitll what you're used to. YMMV, and your boss may well have the last
word.

--
Joe Zeff -- The Guy With The Sideburns:
http://www.zeff.us http://www.lasfs.info

Sendmail should be boycotted for not properly crediting Lovecraft
in the design of sendmail.cf.

Loki Harfagr

unread,
May 14, 2010, 2:04:34 PM5/14/10
to
Fri, 14 May 2010 01:30:41 -0700, RICCARDO did cat :

as for stability and span of life I'd still recommend Slackware,
as for PHB advices you'll find out most will commit you to use RH kin,
that's unfair and stoopid but that's life, especially when you have PHBs.

on the subject of Load average settings my uses are quite like those that
David F. Skoll exposed, just varying a bit on some servers just regarding
what the customers prefer to put as number one point of known return,
either have a smooth and vivid queue (with possible bursts in Load) or
have a very quiet and slow life with probable bursts of tickets about
VIP uberimportant emails being some krazzzy ten or even thirty minutes laaaaaaaate!
In any case queuing mails is the important stuff to favor, then you may
play with different scaling between Delay and Refuse.

Per Hedeland

unread,
May 14, 2010, 5:33:29 PM5/14/10
to

You avoid that cost whether you queue or refuse - but as long as you
keep queueing in an overload situation, you keep causing load from that
processing, and keep building up future load that will hit you when you
start processing the huge queue - if you ever get below QueueLA, that
is.

As you just quoted Nick's book in another post, go read what he has to
say on the subject... (and it wasn't new wisdom when he wrote it).

--Per Hedeland
p...@hedeland.org

terryc

unread,
May 15, 2010, 1:16:02 AM5/15/10
to
On Fri, 14 May 2010 01:30:41 -0700, RICCARDO wrote:


> I agrre you infact I'm going to upgrade but now I have to solve problem.
> For stability I know debian is good os. What do you think ?

Generally, when you upgrade a version of linux, you stay within the same
distribution; RHFC in your case.

The reasons are that;
1) the upgrades are designed to work, nay are required,
2) the steps to perform the upgrade are well documented including any
essential before you start requirements
3) many other people will/have already performed the same upgrade,
4) there will be a lot of support (documentation and people) to assist
you.

Unfortunately, give the number of upgrades that haven't been performed,
you could just as easily back up all required data, then do a fresh
install of any distro.

I went to Debian from RH before they started the FC sequence. It was like
relearning half of what I already about linux again.

Ubuntu is basically an add onto Debian, that IMO is designed for brain
dead morons with lots of money who buy the latest hardware continuously.

Debian is not for everyone as it doesn't have all the latest toys
although there is still plenty of crap to bloat your computer if you are
not careful.

I have found it a great distro for server needs and like the easy
updating system(s) they have. YMMV

Andrzej Adam Filip

unread,
May 15, 2010, 4:31:49 AM5/15/10
to

Nick [unlike you ;-)] used phrase "on *almost all* *busy* email servers"
when issuing "warning+" against using QueueLA lower than RefuseLA.
Nick also explained *why*: such servers can become very easily limited
by queue (disk) IO.

I also *very easily* agree that QueueLA may be a good idea when dealing
with "short" (peak) overload on server ready for very high peak load
(almost "idle" for most of the time) but it may be a "*horrible*
disaster in making" when dealing with *LONG* "overloads".

IMHO server with 700 messages per day is unlikely to be IO bound,
it seems to be CPU bond by "in SMTP session checks".

I have also seen/heard about installation using two stage AV/AS checks.
"Simple" checks in SMTP session (with in SMTP session refusal to take
over responsibility for delivery) and "very detailed" checks from queue.
In such configurations QueueLA makes sense to deal with peak load.

BTW IMHO It would be a *great* idea to make QueueLA dependent on number
of queued messages.

URL(s):
http://www.jetcafe.org/~npc/book/sendmail/
http://www.amazon.com/sendmail-Performance-Tuning-Nick-Christenson/dp/0321115708

Just don't make the '9' format pack/unpack numbers... :-)
-- Larry Wall in <1997100914...@wall.org>

0 new messages