From owner-freebsd-hackers Thu May 16 15:40:28 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from evilpete.dyndns.org (12-232-26-46.client.attbi.com [12.232.26.46]) by hub.freebsd.org (Postfix) with ESMTP id 3A02337B40E for ; Thu, 16 May 2002 15:40:24 -0700 (PDT) Received: from overcee.wemm.org ([10.0.0.3]) by evilpete.dyndns.org (8.11.6/8.11.6) with ESMTP id g4GMeN105661 for ; Thu, 16 May 2002 15:40:24 -0700 (PDT) (envelope-from peter@wemm.org) Received: from wemm.org (localhost [127.0.0.1]) by overcee.wemm.org (Postfix) with ESMTP id 78ACC380A; Thu, 16 May 2002 15:40:23 -0700 (PDT) (envelope-from peter@wemm.org) X-Mailer: exmh version 2.5 07/13/2001 with nmh-1.0.4 To: Doug White Cc: Omar Thameen , freebsd-hackers@FreeBSD.ORG Subject: Re: tuning a CPU bound server In-Reply-To: <20020514211907.W70761-100000@resnet.uoregon.edu> Date: Thu, 16 May 2002 15:40:23 -0700 From: Peter Wemm Message-Id: <20020516224023.78ACC380A@overcee.wemm.org> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Doug White wrote: > qmail is also very inefficient when it comes to large delivery -- the fork > per message and the qmail-remote trigger-hitting will eventually > bottleneck you. It's probable you've run into it. My sympathies. :) You > might try *dropping* concurrencyremote somewhat to reduce the > context-switch thrash (although your context-switch numbers aren't too > high, I've seen worse and the machine wasn't taxed too heavily). If it isn't done already, make sure all of qmail is statically linked rather than dynamically linked with shared libraries. qmail is well known as being brutal for hammering fork/exec, and that is faster on statically linked executables. No, I am not kidding. If you are not particularly wedded to qmail, you might try postfix or something else like it. postfix avoids fork/exec since it uses persistent processes and file descriptor passing. mx2.freebsd.org (pentium-3/850 w/ 512M of ram) uses an outbound concurrency of 512 and rarely ever gets more than a few percent of cpu in use. Newer versions of postfix support VERP (if you really want one recipient per envelope) and the qmail client-side submission protocols. The only real problem that I know of with postfix is that it still suffers from select(2) collisions (FreeBSD kernel problem) when it tries to shut down a bunch of idle smtp senders. That can cause transient load average spikes - this can be a bit alarming but doesn't actually affect things very much. Cheers, -Peter -- Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com "All of this is for nothing if we don't go to the stars" - JMS/B5 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message