Moving from 10.04 to 12.04
lists at avi.co
Sun Sep 9 22:14:24 UTC 2012
James Freer wrote:
> I actually did this exercise for the first time a couple of weeks
> ago. First time i was a little unsure like yourself. I have a 500G
> disk with 4G RAM. For swap you need twice your RAM but over 2G stick
> with the amount of RAM... is what i read.
Swap as double your RAM has never been a need, it was once a rough
guideline in an old (1990s) Solaris manual.
The only reason to have anything more than about 100MB of swap is for
hibernation, in which case you need as much swap as you're likely to be
using memory when you hibernate. If you're likely to be swapping when
hibernating then you need to still have enough space free for all your
memory plus that swap again. You also need more memory.
[swap size] = 2 x [swap used] + [memory used]
at the point where you hibernate. Realistically, you're unlikely to be
swapping so making it as big as the RAM is a good bet.
Of course, none of this really needs to be thought about when
partitioning if you use a swap file; you can just resize that as needed
inside of any other partition.
More information about the ubuntu-users