To read all comments associated with this story, please click here.
yeah, this makes much more sense.
just target a memory size that your system needs and make the swap size with whats missing from your ram !
with the weird calculations that the article mentions, sometimes its "better" ( as in you have less swap ) with less ram !
i just target the 2GB size. As i already have 2 gb of ram there isnt any swap needed.
if you have 512MB, dont make a 1 gb swap , as your system will only have 1.5 GB memory capacity, but a 1.5 GB swap so it reaches the 2GB capacity. ( just in theory, since linux will hardly ever need that for normal desktop usage )
having said that, from the article i guess i better make a 3 gb swap so my laptop can suspend to ram. (anyways, whats 3 gb more or less in my hardrive ?!?
)
No, 32 bit linux can address more than 4 GB with Physical Address Extension (PAE) support ( which every processor has had since Pentium Pro) .
http://en.wikipedia.org/wiki/Physical_Address_Extension






Member since:
2008-05-22
Admittedly, I never could follow the reasoning for this 2x-RAM-rule.
About any piece of software out there requires some absolute amount of RAM and doesn't care wether this RAM is available physically or not. So multiplying the physical amount of RAM with any number is meaningless. What you really want is a rule of thumb for an absolute number.
Example: Running Ubuntu with some desktop stuff needs about 1.5 GB of RAM (worst case scenario), so make sure you have 2 GB of RAM available to be on the safe side. If you have 0.5 GB physical RAM, allocate 1.5 GB swap. If you have 1 GB physical RAM, 1 GB swap is sufficient.
Nowadays, with most desktop PCs having 2 GB physical RAM or more, it's actually questionable wether you need swap at all. If you install a 32-bit OS on a machine with 4 GB physical RAM you can safely ignore swap as the OS can't even address the extra. A common scenario these days, yet most Linux distros still insist on allocating a swap partition.