[exim] Exim on slow Solaris SPARC servers

Inizio della pagina
Delete this message
Reply to this message
Autore: Georg v. Zezschwitz
Data:  
To: exim-users
Oggetto: [exim] Exim on slow Solaris SPARC servers
Hi!

I am running an SMTP relay server with Exim 4.50 on
Solaris 8. Currently, the "cluster" is built up by 2 V.120
servers.

I am looking for some approaches to speed up theses boxes
a bit and would be happy if anybody got an idea, but also
want to "publish" my current findings.

The setup:
- 3 logfiles written (1 by syslog, 1 by file, 1 additional
by a system filter logging specific headers
- no DNS / ident lookups, no spam check, etc.
- routing by a IP lookup table in a flat file (lsearch)
- 28 rewrite rules
- SMTP in / SMTP out via LAN
- Testing with "postal -m 60 -c 1 -p 10 [192.168.2.2]2501 ..."
- Test hardware is a SUN X1 server (Solaris 8 default installation)

This configuration does about 707 mails / minute.
(Right: This makes most 3 year old PC hardware running Linux/BSD
laughing)

The bottleneck is not IO, it is the CPU.

E.g., the vmstat output looks like this:

#vmstat 5
procs     memory            page            disk          faults cpu
r b w   swap  free  re  mf pi po fr de sr dd -- -- --   in   sy   cs us sy id
...
2 0 0 1081192 58424  9 3118 0  6  6  0  0 308 0  0  0 1594 5514 1634 33 67  0
4 0 0 1082008 59080  6 2979 0  9  9  0  0 321 0  0  0 1607 5679 1750 33 66  0
3 0 0 1081960 58824  7 2890 0  6  6  0  0 292 0  0  0 1652 5114 1460 34 64  2
4 0 0 1080832 58176  5 3105 0  8  6  0  0 320 0  0  0 1581 5592 1545 33 67  0
7 0 0 1081112 58576  7 2993 0  3  3  0  0 305 0  0  0 1597 5401 1518 33 67  0


I tried the following steps:

- Removing "queue_only_load", "deliver_queue_load_max" and
"smtp_load_reserve", that I had set to very high values
(> 1000), increased performance by 8%.
I guess that calculating the OS load is rather expensive
when using Solaris.

- Removing the "system filter". It contain mostly a "logwrite"
directive.
Resulted in < 1 % performance increase

- Removal of the 28 rewrite rules (main configuration):
Nearly no effect

- Moving the routing information from a flat file to a DBM
file (builtin Solaris ndbm) decreased the performance.
The flat-file had 36 data lines.

- Putting everything (logfiles, spooling, hint-dbs) into RAM
(/tmp with RAM-fs) instead of the disk increased the
throughput by 13.6 %.

A *very* helpful hint from Philip was to use

deliver_drop_privilege=true

In my environment, Exim is neither setuid nor running
as root. It runs *always* as the same non-root user.
This is quite uncommon, and Exim does a (in my
case) useless reexecution of itself unless this parameter
is set. That made Exim 23% faster. All numbers above are
already based on this optimization.

Has anybody a suggestion for further optimizations to
evaluate?

Regards,


Georg