Swap space - max size

T. Srikanth kantsg at netscape.net
Thu May 27 01:44:48 PDT 2004


Jamie,

Run the following script on your system under maximum load.

#!/bin/sh -

ps -o vsz -o rss | grep '[0123456789]' | \
awk '{
    i += $1;
    j += $2;
} END { printf("VSZ=%dK, RSS=%dK\n", i, j); }'

If you see VSZ is very close to the swap size and RSS is getting
closer to the available physical memory, you should have to tune
your system by increasing the swap. A process that is swapped out
is not necessarily swapped in immediately, so you can pick your
choice of the swap size that meets the requirements of VSZ (above).

--Srikanth

--
>From owner-freebsd-questions at FreeBSD.ORG  Tue Mar  2 19:10:18 2004
Return-Path: <owner-freebsd-questions at FreeBSD.ORG>
Delivered-To: freebsd-questions at freebsd.org
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
    by hub.freebsd.org (Postfix) with ESMTP id 4F12116A4CE
    for <freebsd-questions at freebsd.org>;
    Tue,  2 Mar 2004 19:10:18 -0800 (PST)
Received: from floyd.gnulife.org (floyd.gnulife.org [199.86.41.27])
    by mx1.FreeBSD.org (Postfix) with ESMTP id C891B43D1D
    for <freebsd-questions at freebsd.org>;
    Tue,  2 Mar 2004 19:10:17 -0800 (PST)
    (envelope-from jamie at gnulife.org)
Received: from floyd.gnulife.org (localhost.gnulife.org [127.0.0.1])
    by floyd.gnulife.org (8.12.11/8.12.11) with ESMTP id i2349Lvt072292
    for <freebsd-questions at freebsd.org>;
    Tue, 2 Mar 2004 22:09:21 -0600 (CST)
    (envelope-from jamie at gnulife.org)
Received: from localhost (jamie at localhost)i2349Lml072289
    for <freebsd-questions at freebsd.org>;
    Tue, 2 Mar 2004 22:09:21 -0600 (CST)
    (envelope-from jamie at gnulife.org)
X-Authentication-Warning: floyd.gnulife.org: jamie owned process doing -bs
Date: Tue, 2 Mar 2004 22:09:21 -0600 (CST)
From: Jamie <jamie at gnulife.org>
To: freebsd-questions at freebsd.org
Message-ID: <20040302220558.R72279 at floyd.gnulife.org>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
X-Scanned-By: MIMEDefang 2.39
Subject: Swap space - max size
X-BeenThere: freebsd-questions at freebsd.org
X-Mailman-Version: 2.1.1
Precedence: list
List-Id: User questions <freebsd-questions.freebsd.org>
List-Unsubscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-questions>,
    <mailto:freebsd-questions-request at freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/freebsd-questions>
List-Post: <mailto:freebsd-questions at freebsd.org>
List-Help: <mailto:freebsd-questions-request at freebsd.org?subject=help>
List-Subscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-questions>,
    <mailto:freebsd-questions-request at freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 03 Mar 2004 03:10:18 -0000



   Is there any point in adding more than 2 Gb of swap space on an x86 if
you have 2 Gb of ram? From what I've read, x86 can address 4 Gb of memory,
so it would seem that more than 4 Gigs of combined memory and swap space
would be wasted. Am I right?



    Thanks,

    - Jamie




Greetings from Minneapolis, MN, United States

"A friend is someone who lets you have total freedom to be yourself."




More information about the freebsd-questions mailing list