HP-UX System Administrator's Guide: Overview
Lazy Swap
Another technology that takes advantage of the fact that not all swap space that is
reserved is actually used is lazy swap. The lazy swap feature causes HP-UX to not reserve
swap space for a process-private page until the associated process actually modifies
the page. This can significantly reduce the amount of allocated swap space.
Lazy swap is configured on a process by process basis. There are programmatic ways
to enable lazy swap or a user can modify a binary executable file to enable lazy swap
by using the +z option to the chatr command. See the chatr(1) manpage for details.
Primary and Secondary Swap Space
HP-UX must have at least one device swap area available when it boots. This area is
known as the primary swap area.
4
Primary swap, by default, is located on the same disk
as the root file system (though in a different logical volume). Use the swapon command
(see swapon(1M)) to define swap space.
Other swap space may be used in addition to primary swap. This is known as secondary
swap space. If you are using device swap as your secondary swap space, for better
performance allocate the secondary swap space on a disk drive other than where the
primary swap is located.
File system swap is always secondary swap.
Figure 3-6 Swap Space - Possible Locations for Paging
Swap
Lvol3
/opt
lvol1
File System
Swap
Dedicated
Swap Volume
Device Swap
(end of device)
Dedicated
Swap Device
Estimating Your Swap Space Needs
Your swap space must be large enough to hold all the processes that could be running
at your system’s peak usage times.
If your system performance is good, and, in particular, if you are not getting swap
errors such as “Out of Memory” or those to the effect that a process was killed due
to no swap space, then your system has adequate swap space.
4. Primary swap is not mandatory if pseudo swap is enabled, however, it is strongly recommended.
Storage on HP-UX 71