[Mimedefang] Tuning MIMEDefang - memory usage, etc.

Cormack, Ken kcormack at acs.roadway.com
Thu Apr 15 14:56:54 EDT 2004


Group,

I'm looking for some feedback regarding memory tuning, for MIMEDefang.

I have a pair of 2GB Compaq DL380 servers with RH Linux 8.0 (kernel 2.4.25),
sendmail 8.12.11, MIMEDefang 2.41, with Mail::SpamAssassin 2.63.  I have a
fairly large number of third-party SA rules (backhair, bigevil, and so on)
in addition to approx. 7000 rawbody rules replicating strings I exported
from the content filters we run on the internal Exchange servers.  Both my
sendmail and MIMEDefang are each configured for 30 max child processes,
mainly to handle production batch jobs that run on some internal servers and
which can pump thousands of emails through my system in periodic bursts
lasting several minutes.

My installation is configured to use MIMEDefang's Embedded perl feature, and
each of my servers uses a 128MB RAM filesystem for /var/spool/MIMEDefang.
Lastly, I have sysctl configuring shmmax and shmall for 1.5GB of shared
memory.

A typical snapshot of "top" on my primary server shows the following memory
usage by MD (chopped here, with relevant fields only, to reduce line-wrap):

SIZE  RSS SHARE %MEM
134M 134M 45568  6.6
133M 133M 45640  6.6
132M 132M 45364  6.5
129M 129M 45772  6.4
127M 127M 45920  6.3
117M 117M 47264  5.7
115M 115M 45836  5.7
114M 114M 46400  5.6
112M 112M 47428  5.5
111M 111M 47292  5.5
111M 111M 47480  5.5
111M 111M 47468  5.5
111M 111M 47460  5.5
111M 111M 47400  5.5
110M 110M 47344  5.4
108M 108M 47704  5.3
108M 108M 47440  5.3
108M 108M 48088  5.3
107M 107M 48128  5.3
107M 107M 47672  5.3
105M 105M  104M  5.2
105M 105M  104M  5.2

My "sar -r" numbers (for memory utilization) look good in my opinion, with
%memused at 50-60% (with spikes into the 70-90% range), and %swpused at < 1%
(with peaks in the 10-30% range) during business hours.

I'm curious to know what some of you may think, regarding any suggested
tuning tweaks you could recommend, particularly for either the max number of
concurrent child daemons, shared memory, or the following MIMEDefang
tuneables, which are currently at their defaults.

# Limit slave processes' resident-set size to this many kilobytes.  Default
# is unlimited.
# MX_MAX_RSS=10000

# Limit total size of slave processes' memory space to this many kilobytes.
# Default is unlimited.
# MX_MAX_AS=30000

Any suggestions that will help maximize my memory utilization would be
appreciated.  Adding the 7000+ rules to SpamAssassin caused the memory
footprint of my MD threads to double in size, and I'd like to know if anyone
has any concerns or suggestions based on my above configuration and memory
usage.

KEN CORMACK, RHCE
Sr. UNIX Systems Analyst,
    Open Systems Group
Sr. Software Analyst,
    TSG Midrange Systems Group
AFFILIATED COMPUTER SERVICES, INC.
    557 E. Tallmadge Ave., Akron, OH  44310
    mailto:kcormack at acs.roadway.com
    mailto:ken.cormack at acs-inc.com
    Phone: (330) 643-6372
    Fax: (330) 643-6367
    Pager: (800) 946-4646 Pin 1412819

"If that that is 'is' is that that is not 'not is', is that that is 'not is'
that that is not 'is'?  It is!" - Ken Cormack

"Sendmail administration is not black magic.  There are legitimate technical
reasons why it requires the sacrificing of a live chicken." - Unknown



More information about the MIMEDefang mailing list