[colug-432] Swap science, was: Install and Manually Partition Debian
Rick Troth
rmt at casita.net
Sun Mar 16 20:18:47 EDT 2014
On 03/16/2014 06:33 PM, Brian Miller wrote:
> This isn't exactly based on research, but my current practice is to
> provide a small swap space on my virtual machines (say, 500 MB), and
> then give the guest enough memory to run the application.
Exactly ... give the guest enough memory to run the application.
I run most of my virtual Linuxen with _no swap space_ at all.
> If the server
> writes a small amount to swap, I don't worry about it. But if swap
> keeps growing, I generally increase the amount of RAM. Unless it looks
> like it's caused by a memory leak. Then I tell the application admins
> to set a schedule to re-start their application. I'll even offer to set
> up a notification email to tell them when swap gets to 75% full, if they
> want.
Also keep in mind that _occupied_ swap space is not as "heavy" as
_active_ swap space. If a virtual server dips into swap space when
getting started, no sweat. The thing to avoid is moving pages between
memory and disk during normal operation.
There's no getting around some tuning of guest memory size. Define guest
memory as small as possible to avoid paging/swapping.
It's good to evaluate swapping/paging capabilities of the host
(hypervisor). The z/VM system is really good about paging. As I recall,
some versions of VMware don't actually perform swapping of host memory.
(I really haven't looked at the others on this point at all.)
Ironically, it's better for the host to do it than for the guest to do it.
-- R; <><
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.colug.net/pipermail/colug-432/attachments/20140316/c9f40b5b/attachment.html
More information about the colug-432
mailing list