Use of floating point on typical mailserver

Jeff A. Earickson jaearick at colby.edu
Fri Feb 2 14:39:38 CET 2007


n Fri, 2 Feb 2007, Greg Matthews wrote:

> Date: Fri, 02 Feb 2007 10:05:00 +0000
> From: Greg Matthews <gmatt at nerc.ac.uk>
> Reply-To: MailScanner discussion <mailscanner at lists.mailscanner.info>
> To: MailScanner discussion <mailscanner at lists.mailscanner.info>
> Subject: Re: Use of floating point on typical mailserver
> 
> Jeff A. Earickson wrote:
>> We have two 8-core T2000s and three 8-core T1000s onsite.  The three T1000s
>> handle our webmail front end (horde/imp and associated apache stuff). One 
>> T2000 is a web server, and the second T2000 came online a couple of
>> weeks ago to handle our IMAP service (dovecot 1.0rc18 currently).  This
>> box has an HP MSA50 disk array with fourteen 72GB disks in a mirrored/
>> striped ZFS disk pool for homedirs.  All of these systems do a great job,
>> and barely break a sweat doing it.
>> 
>> While I can't speak to the FPU issue directly, I got a bit of advice from
>> a Sun engineer on which chipset to buy for what use in Sun-land.  If you
>> want floating-point computation speed, buy x86 boxes (Sun V20's, etc) 
>> because
>> the clock cycle of the x86 chips is so much faster.  If the work is non
>> floating-point, then buy Coolthreads servers if the ratio of threads to
>> processes is > 4.  How to find out?  Run "prstat" and look at the bottom
>> line.  Take the ratio of processes to LWPs.  If the ratio is less than
>> four, then buy standard Sparc.  Sparc chips have the advantage that they
>> are RISC chips while x86 aren't.  His advice, passed along.
>
> thanks Jeff... the problem is how do I know if my MS/SA/AV/MW boxes use a lot 
> of FP?

Some quick thoughts here.  Search the source code that you compile (eg, 
sendmail code) for uses of "float", "double", or "math.h" (math lib):

find . -name '*.[ch]' -print | xargs egrep 'math|float|double'

I didn't find much in sendmail 8.13.8 source code.  Examine the dynamic 
libraries that you use with ldd and look for libm (mathlib).  Do an lsof
as root and look to see if libm is in use by anything.  These quick checks
on my mail server didn't show much.  Mathlib tends to be the heavy hitter
for floating-point, since it has trig/log functions and the like in it.

> It seems crazy looking back but our relays used to run on Sun Ultra 5s, they 
> were replaced by v60z's (Sun Xeon boxes - not very popular) which have done a 
> great job since then but are starting to look a bit long in the tooth. 
> Tripling the memory gave them a new lease of life! Whatever we replace them 
> with needs to have a reasonable chance of coping for another 4 years or so.
>
> most of the grunt work of MS and SA is perl text processing which I wouldnt 
> expect to use a lot of FP. I would expect AV engines to be similar (searching 
> for signature patterns etc) so my hunch is that there is little FP work going 
> on... I'll try asking similar questions elsewhere to see if I can figure it 
> out...
>
> Not sure I follow the threads/process argument as it seems to assume that you 
> will have the same number of processes running on each box. But if I have a 
> "32-way" host, I'll increase the maximum number of MS and MTA processes to 
> fill the pipes.

The idea with threads/processes is that the current Niagara chips can run
4 threads per CPU.  If the ratio of threads to processes is high, then
you can keep the CPU busy with threads.  If the ratio is low, then you are
wasting your money on the CoolThreads CPUs, because you can't keep them 
busy.  Buy regular Sparc chips instead.

Jeff Earickson
Colby College


More information about the MailScanner mailing list