|
|
1.1 ! root 1: .\" Copyright (c) 1980 Regents of the University of California. ! 2: .\" All rights reserved. The Berkeley software License Agreement ! 3: .\" specifies the terms and conditions for redistribution. ! 4: .\" ! 5: .\" @(#)swapon.2 6.4 (Berkeley) 3/9/86 ! 6: .\" ! 7: .TH SWAPON 2 "March 9, 1986" ! 8: .UC 4 ! 9: .SH NAME ! 10: swapon \- add a swap device for interleaved paging/swapping ! 11: .SH SYNOPSIS ! 12: .nf ! 13: .B swapon(special) ! 14: .B char *special; ! 15: .fi ! 16: .SH DESCRIPTION ! 17: .I Swapon ! 18: makes the block device ! 19: .I special ! 20: available to the system for ! 21: allocation for paging and swapping. The names of potentially ! 22: available devices are known to the system and defined at system ! 23: configuration time. The size of the swap area on ! 24: .I special ! 25: is calculated at the time the device is first made available ! 26: for swapping. ! 27: .SH "RETURN VALUE ! 28: If an error has occurred, a value of \-1 is returned and ! 29: .I errno ! 30: is set to indicate the error. ! 31: .SH ERRORS ! 32: .I Swapon ! 33: succeeds unless: ! 34: .TP 15 ! 35: [ENOTDIR] ! 36: A component of the path prefix is not a directory. ! 37: .TP 15 ! 38: [EINVAL] ! 39: The pathname contains a character with the high-order bit set. ! 40: .TP 15 ! 41: [ENAMETOOLONG] ! 42: A component of a pathname exceeded 255 characters, ! 43: or an entire path name exceeded 1023 characters. ! 44: .TP 15 ! 45: [ENOENT] ! 46: The named device does not exist. ! 47: .TP 15 ! 48: [EACCES] ! 49: Search permission is denied for a component of the path prefix. ! 50: .TP 15 ! 51: [ELOOP] ! 52: Too many symbolic links were encountered in translating the pathname. ! 53: .TP 15 ! 54: [EPERM] ! 55: The caller is not the super-user. ! 56: .TP 15 ! 57: [ENOTBLK] ! 58: .I Special ! 59: is not a block device. ! 60: .TP 15 ! 61: [EBUSY] ! 62: The device specified by \fIspecial\fP has already ! 63: been made available for swapping ! 64: .TP 15 ! 65: [EINVAL] ! 66: The device configured by \fIspecial\fP was not ! 67: configured into the system as a swap device. ! 68: .TP 15 ! 69: [ENXIO] ! 70: The major device number of ! 71: .I special ! 72: is out of range (this indicates no device driver exists ! 73: for the associated hardware). ! 74: .TP 15 ! 75: [EIO] ! 76: An I/O error occurred while opening the swap device. ! 77: .TP 15 ! 78: [EFAULT] ! 79: .I Special ! 80: points outside the process's allocated address space. ! 81: .SH "SEE ALSO" ! 82: swapon(8), config(8) ! 83: .SH BUGS ! 84: There is no way to stop swapping on a disk so that the pack may be ! 85: dismounted. ! 86: .PP ! 87: This call will be upgraded in future versions of the system.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.