Monday, February 9, 2009

Swap Administration

A standard Solaris swap space partition that is not under the control of volume management software cannot be resized. However, you can add swap space by using free space from another partition.

To create a swapfile:
mkfile size swapfile

Here is an example to create an additional 512M swapfile:
mkfile 512M /files0/swapfile

Add the swapfile to system swap space:
swap -a /files0/swapfile

Add an /etc/vfstab entry to have the swapfile added after each reboot:
/files0/swapfile - - swap - no -

Make sure to manually remove this /etc/vfstab entry if you ever delete the additional swapfile with swap -d.


Additional swap commands

List swap space:
swap -l

List swap space statistics:
swap -s

Delete a swapfile:
swap -d swapfile

Readers who read this page, also read:




Bookmark and Share My Zimbio http://www.wikio.com

0 comments: