From owner-freebsd-isp Sun Jan 13 23:56:54 2002 Delivered-To: freebsd-isp@freebsd.org Received: from workhorse.iMach.com (workhorse.iMach.com [206.127.77.89]) by hub.freebsd.org (Postfix) with ESMTP id C23B337B402 for ; Sun, 13 Jan 2002 23:56:46 -0800 (PST) Received: from localhost (forrestc@localhost) by workhorse.iMach.com (8.9.3/8.9.3) with ESMTP id AAA22687; Mon, 14 Jan 2002 00:52:27 -0700 (MST) Date: Mon, 14 Jan 2002 00:52:27 -0700 (MST) From: "Forrest W. Christian" To: Hug Me Cc: root@se2600.org, freebsd-isp@FreeBSD.ORG Subject: Re: e-mail client In-Reply-To: <20020113152508.F19327@pitr.tuxinternet.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-isp@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Sun, 13 Jan 2002, Hug Me wrote: > I am going to have around 150 copies of this running at the same time so > it using a small amount of memory is important.. ... > 7.2 meg running in momory.. thats 11.8 gig of memory, just to run MAIL, Your memory math is broken. But not because you can't do regular math - but instead that memory math is different. PID USERNAME PRI NICE SIZE RES STATE TIME WCPU CPU COMMAND 11832 hugme 2 0 9840K 8296K poll 0:02 0.00% 0.00% arrow 11830 hugme 2 0 8084K 7120K select 0:01 0.00% 0.00% postilion.exec 11794 hugme 2 0 7276K 5896K poll 0:01 0.00% 0.00% sylpheed Although each of these do require the size indicated for the first instance, the second instance in a lot of cases takes a lot less. The reason for this is that the FreeBSD system can share common code between the processes. The only real way to tell how much these take on a per-instance case is to load up say 10 and look at the total memory usage. Also, if you have a single app like this which you are going to be running a LOT of copies of, it is in a lot of cases better if the binary is statically linked. This helps with the code sharing as it helps the VM subsystem not dirty code pages. In addition, setting the H option for malloc might be a good idea (YMMV). To do this: ln -s 'H' /etc/malloc.conf This tells the memory allocator to provide hints to the vm subsystem about free pages so that the vm subsystem can better handle freeing up dirty pages which don't contain anything at all. BYW, are you trying to say that you are going to have 150 clients running X apps on this box? This seems kinda scary. I would seriously look at a web-based mail app. I personally recommend IMP (http://www.horde.org/imp) or if you need scheduling, look at twig. The real advantage of a web based app is that one web server instance can actually handle many clients. If you compile apache with php support built in and run IMP, there is virtually no per-process startup penalty and 10 processes or so should be able to handle the 100-150 users you are talking about. - Forrest W. Christian (forrestc@imach.com) AC7DE ---------------------------------------------------------------------- The Innovation Machine Ltd. P.O. Box 5749 http://www.imach.com/ Helena, MT 59604 Home of PacketFlux Technogies and BackupDNS.com (406)-442-6648 ---------------------------------------------------------------------- Protect your personal freedoms - visit http://www.lp.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isp" in the body of the message