SWAP(3)                                                   SWAP(3)

     NAME
          swap - memory usage statistics and swap file control

     SYNOPSIS
          bind -a #ΒΆ /dev

          /dev/swap

     DESCRIPTION
          The swap device holds a text block giving memory usage
          statistics:

               n memory
               n pagesize
               n kernel
               n/m user
               n/m swap
               a/n/m kernel malloc
               a/n/m kernel draw
               a/n/m kernel secret

          These are total memory (bytes), system page size (bytes),
          kernel memory (pages), user memory (pages), swap space
          (pages), kernel malloced data (bytes), kernel graphics data
          (bytes) and kernel secret data (bytes).  The expression n/m
          indicates n used out of m available.  For kernel malloc and
          kernel draw, a indicates the current allocation in bytes.
          These numbers are not blank padded.

          To turn on swapping, write to swap the textual file descrip-
          tor number of a file or device on which to swap.

          Only the hostowner is allowed to enable swapping. The pages
          written to the swap file are transparently encrypted by the
          kernel using a random key.

     SEE ALSO
          memory(8), swap(8).

     SOURCE
          /sys/src/9/port/devswap.c

     Page 1                       Plan 9            (printed 11/18/24)