Alan Cox wrote:
On Wed, 5 Dec 2007 09:39:44 -0500
Kim Goldenberg <[EMAIL PROTECTED]> wrote:

There is an article posted this wee on Linux.com about swap space:

http://www.linux.com/feature/121916

Humm, very confusing in places and missing a key detail.

A lot of stuff isn't swapped. Any page that came from an underlying
executable file and has not been written too (ie most of the code of most
programs) is simply discarded and re-read from the file system. Thats
also usually much faster than swapping it.

Bogus claim: "if you run out of memory and have no swap the
system will crash". It won't. It'll keep trying to get memory by throwing
out stuff which can be thrown out without swap (like code). What it does
when this limit is reached depends on your configuration but it may get
very very slow (ditto with swap if you run out of swap) or you can tell
it to refuse to get into that sort of state and disable overcommit.

The system probably won't crash, but some applications will (and that's
regardless of whether swap exists), and the result of that might be
essentially indistinguishable from a crashed system. I've recently seen
loadaverage well over 40, and that makes systems very difficult to use,
login can timeout before the password prompt, ssh doesn't connect....
Might not be crashed, but a crash might be better.

The commit policy is configurable so you can tune it for a swapless box
that wants memory allocations to fail rather than excessive swapping, and
various embedded boxes use it.

The amount of swap you need really is application dependant. Get rid of
evolution and it halves in my experience.

I don't use Evolution, but Mozilla/Seamonkey/Firefox can bring any
system to its knees.
This is modest:
 7850 summer    15   0  470m 154m  21m S    0 16.7  34:31.43 seamonkey-bin

otoh rsync can use an enormous amount of swap, several times real RAM,
without thrashing.

--

Cheers
John

-- spambait
[EMAIL PROTECTED]  [EMAIL PROTECTED]
-- Advice
http://webfoot.com/advice/email.top.php
http://www.catb.org/~esr/faqs/smart-questions.html
http://support.microsoft.com/kb/555375

You cannot reply off-list:-)

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

Reply via email to