Swap partition sizes Was: Best partition size for Ubuntu Root

Avi Greenbury avismailinglistaccount at googlemail.com
Fri May 2 13:54:04 UTC 2008


On Fri, 02 May 2008 07:24:56 -0600
Charlie Kravetz <cjk at teamcharliesangels.com> wrote:

> 
> On Fri, 2008-05-02 at 14:08 +0100, Avi Greenbury wrote:
> > On Fri, 02 May 2008 20:05:57 +0800
> > SYNass IT Ubuntu / Linux <i-ubux at synass.net> wrote:
> > 
> > > Hi Leafman, 
> > > I second Ioannis statement with 2* RAM size !
> > > I would recommend first 2* (system's max) RAM size !!
> > > 
> > 
> > Doesn't this date from Solaris 7 or something? Actually, even that was swap == system memory, I think.
> > 
> > If I've 4Gb of RAM, chances are there's little cause for me to want 4Gb of swap on top of that. 
> > In fact, in order to hibernate, I've got 4Gb of swap. I've only ever once see it use swap (a whole 2% when running Vista and XP VMs).
> > 
> > I'd go with (system memory)+(swap)+(a bit) = (normal system memory requirements at normal load).
> > 
> > -- 
> > Avi Greenbury
> > 
> No, I believe it might come from the
> http://www.tldp.org/HOWTO/Multi-Disk-HOWTO.html
> which describes how to partition your hard drives for any distribution.

Which agrees with me somewhat when, in Section 4 (page 20 of the pdf[1]) it says:

"A more thorough approach is to consider swap space plus RAM as your total working set, so if you
know how much space you will need at most, you subtract the physical RAM you have and that is the
swap space you will need."


> You might also check out the Ubuntu Installation Guides, included on the
> installation cds, attachment C, which also discusses partitions for
> Ubuntu, including swap sizes.

That says "One rule of thumb which works well is to use as much swap as you have system memory"

Which is substantially less twice the system memory size.

[2] is in line with a lot of what I've seen on the subject, if not from the most reliable of sources.

[1] http://www.ibiblio.org/pub/Linux/docs/HOWTO/other-formats/pdf/Multi-Disk-HOWTO.pdf 
[2] http://wombat.san-francisco.ca.us/faqomatic/cache/53.html
-- 
Avi Greenbury




More information about the ubuntu-users mailing list