public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Swap size for a machine with 2GB of memory
@ 2001-08-19  6:42 Eric S. Raymond
  2001-08-19  8:25 ` Andrzej Krzysztofowicz
                   ` (5 more replies)
  0 siblings, 6 replies; 18+ messages in thread
From: Eric S. Raymond @ 2001-08-19  6:42 UTC (permalink / raw)
  To: Linux Kernel List; +Cc: gars

The Red Hat installation manual claims that the size of the swap partition
should be twice the size of physical memory, but no more than 128MB.

The screaming hotrod machine Gary Sandine and I built around the Tyan S2464
has 2GB of physical memory.  Should I believe the above formula?  If not,
is there a more correct one for calculating needed swap on machines with
very large memory?

(No further hangs, BTW.)
-- 
		<a href="http://www.tuxedo.org/~esr/">Eric S. Raymond</a>

.. a government and its agents are under no general duty to 
provide public services, such as police protection, to any 
particular individual citizen...
        -- Warren v. District of Columbia, 444 A.2d 1 (D.C. App.181)

^ permalink raw reply	[flat|nested] 18+ messages in thread
* Re: Swap size for a machine with 2GB of memory
@ 2001-08-20  0:08 Andries.Brouwer
  2001-08-21 23:14 ` Kurt Garloff
  2001-08-24 12:45 ` Rogier Wolff
  0 siblings, 2 replies; 18+ messages in thread
From: Andries.Brouwer @ 2001-08-20  0:08 UTC (permalink / raw)
  To: ebiederm, esr, sct; +Cc: gars, linux-kernel

    From: ebiederm@xmission.com (Eric W. Biederman)
    Date:     19 Aug 2001 14:49:23 -0600

    "Eric S. Raymond" <esr@thyrsus.com> writes:

    > The Red Hat installation manual claims that the size of the
    > swap partition should be twice the size of physical memory,
    > but no more than 128MB.
    > 
    > Should I believe the above formula?

You give two statements. The 128 MB bound was claimed by Microsoft
and we screamed loudly that that was a lie - now it is claimed
by both SuSE and RedHat. Funny.
No, the bound is not 128 MB. See mkswap(8).

    With respect to swap partitions the current limit is about 64Gig.
    You can actually make a larger swap partition but the kernel on x86
    only uses 24 offset bits into that partition.  The 128MB partition
    existed but was removed long ago.

Long ago I wrote in mkswap(8) that the max on i386 is about 2 GiB.
I seem to recall that at some point in time the swap size in
bytes had to fit in a signed long, and indeed, 2.1.117 has
        if (p->max >= 0x7fffffffL/PAGE_SIZE ...
2.2.0pre9 changed this into
        if (p->max >= SWP_OFFSET(SWP_ENTRY(0,~0UL)))
deleting this restriction.
If it is no longer there, I suppose I should change mkswap.c.
Stephen, can you confirm?

Andries

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2001-08-24 12:45 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-08-19  6:42 Swap size for a machine with 2GB of memory Eric S. Raymond
2001-08-19  8:25 ` Andrzej Krzysztofowicz
2001-08-19  9:46 ` Ignacio Vazquez-Abrams
2001-08-19 16:15   ` Ingo Oeser
2001-08-19 14:08 ` Alan Cox
2001-08-19 16:48   ` Eric S. Raymond
2001-08-19 14:39 ` Steven Cole
2001-08-19 17:29 ` Luigi Genoni
2001-08-19 15:52   ` Steven Cole
2001-08-19 22:16     ` Luigi Genoni
2001-08-19 20:49 ` Eric W. Biederman
2001-08-19 21:15   ` Eric S. Raymond
2001-08-20  0:05   ` Kevin Krieser
2001-08-20 17:42     ` Eric W. Biederman
2001-08-20 23:09       ` Kevin Krieser
  -- strict thread matches above, loose matches on Subject: below --
2001-08-20  0:08 Andries.Brouwer
2001-08-21 23:14 ` Kurt Garloff
2001-08-24 12:45 ` Rogier Wolff

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox