Uwe Thiem wrote:
3. because it is always better to have too much ram/swap then too little
Nnnnot always. There are circumstances when you do not want swap at all.
This is never true. Swap is *always* called for, and for a good reason.
Your example of having a real-time responsive app requiring memory
residence is a determining factor of how much physical memory you'll
need to keep the app resident.
But the truth of the matter is this will not be your only app running on
the system. Throw some big memory hogs into play, i.e. an active X
session running locally and that remote X session you've started from
work, and pretty soon you can find yourself eating up that 1gb that you
thought would be fine.
Except that since you did not have any swap enabled, once you reach the
1gb limit, processes start failing. You find yourself unable to log
into the box because there's not enough memory to spawn a new shell.
You're forced to hard-boot the system and hope that the HD caches were
flushed to the disk before you hit the reset button.
Having swap is just another manner of safe-guarding your system. Once
you breach the physical limit, there's always swap to fall back on.
Sure all of your apps will suffer while swapping occurs, but at least
you stand a chance of cleaning up the situation w/o facing the hard
reboot option.
--
gentoo-user@gentoo.org mailing list