From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 10 21:01:41 2003 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0E1A816A4CF; Wed, 10 Dec 2003 21:01:41 -0800 (PST) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id BC08643D2A; Wed, 10 Dec 2003 21:01:39 -0800 (PST) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (localhost [127.0.0.1]) by fledge.watson.org (8.12.10/8.12.10) with ESMTP id hBB51MUd081781; Thu, 11 Dec 2003 00:01:22 -0500 (EST) (envelope-from robert@fledge.watson.org) Received: from localhost (robert@localhost)hBB51KYk081778; Thu, 11 Dec 2003 00:01:21 -0500 (EST) (envelope-from robert@fledge.watson.org) Date: Thu, 11 Dec 2003 00:01:20 -0500 (EST) From: Robert Watson X-Sender: robert@fledge.watson.org To: Dan Nelson In-Reply-To: <20031210063845.GG2435@dan.emsphone.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: nbari@unixmexico.com cc: freebsd-isp@freebsd.org cc: freebsd-hackers@freebsd.org Subject: Re: adding more ram X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Dec 2003 05:01:41 -0000 On Wed, 10 Dec 2003, Dan Nelson wrote: > In the last episode (Dec 10), nbari@unixmexico.com said: > > I have a server with 1GB of RAM and a swap partition of 2GB i will > > upgrade the memory server to 2GB so my questions are: > > > > should i fix the swap partition to have now 4GB of space ? > > Depends. Have you ever used up that 2gb of swap? If not, you'll > probably never consume 4gb either :) If this is a database server, or > something similar where a few processes allocate large amounts of > memory, you don't need much swap anyway, since if any of those processes > actually has to swap, you end up thrashing the system as it tries to > swap 500mb processes in and out of memory. I really can't think of a > system that would still perform well with 2 or 3GB of process space in > swap. At the 2gb RAM point, you usually have a system where any > swapping == bad news. Actually, the thing I use swap for most now is to make sure I can allocate large temporary file systems without consuming excessive kernel address space. I.e., I'll often create a 512mb swap-backed md device for /tmp, and make sure I have enough swap to fully back it and everything else, even though the chances are I won't touch it in normal operation. I just don't want to run out in the event something does need it... Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Senior Research Scientist, McAfee Research