[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Swap space not used



On Thu, May 03, 2012 at 09:48:59AM +0200, Claudius Hubig wrote:
> Hello Stephen,
> 
> Stephen Powell <zlinuxman@wowway.com> wrote:
> > It is my understanding that,
> > assuming suspend/resume is supported, your swap partition
> > should be AT LEAST as large as TWICE the amount of RAM.
> > Suspend/resume will consume a RAM's worth right out of the
> > starting gate.  The rest is then available for regular swap
> > file activity.
> 
> This is - more or less - wrong. Suspend/Resume will consume at most
> swap space corresponding to the used RAM (i. e. with compression and
> dropping of buffers/caches, it can be far less). However, this swap
> space is not used during runtime but only on suspend, so if there is

If the swap space is available during normal usage, then it's entirely
possible to have no space to suspend to. This is why windows uses a
separate hibernation file (though Windows' memory management is rather
poor to start with).

It'd be perfectly reasonable practice to have a separate swap
file/partition for hibernating to and swapon that before hibernating.

> no need to suspend under heavy load (used swap usually indicates
> heavy load on a desktop and I fail to imagine a reason why you’d like
> to suspend a server…), swap the size of RAM is definitely enough.
> 
> Best regards,
> 
> Claudius


Attachment: signature.asc
Description: Digital signature


Reply to: