Activates paging or swapping to a designated block device.
Standard C Library (libc.a)
#include <sys/vminfo.h>
int swapon ( PathName)
char *PathName;
The swapon subroutine makes the designated block device available to the system for allocation for paging and swapping.
The specified block device must be a logical volume on a disk device. The paging space size is determined from the current size of the logical volume.
PathName | Specifies the full path name of the block device. |
If an error occurs, the errno global variable is set to indicate the error:
Other errors are from calls to the device driver's open subroutine or ioctl subroutine.
The swapoff subroutine,swapqry subroutine.
The swapoff command, swapon command.
The Subroutines Overview in AIX 5L Version 5.2 General Programming Concepts: Writing and Debugging Programs.