swapmon man page on DragonFly

Man page or keyword search:  
man Server   44335 pages
apropos Keyword Search (all sections)
Output format
DragonFly logo
[printable version]

swapmon(1)		  BSD General Commands Manual		    swapmon(1)

NAME
     swapmon — monitor swapusage, add swapspace as needed

SYNOPSIS
     swapmon [start|stop|-F] add/remove swapspace automatically as needed

DESCRIPTION
     swapmon will check the current swapusage and if more than SWAP_HIGH per‐
     cent of swapspace is in use it will create a new swapfile with a size of
     size of SWAP_STEP percent of the current swapspace and activate it.  If
     less than SWAP_LOW percent of swapspace is in use it will deactivate a
     previously added swapspace file and remove it.

     If called with start it will fork into the background and run as a dae‐
     mon. It will check and then sleep for DELAY seconds before checking
     again. Messages about the operation will be piped to LOGGER. The pid of
     the daemon will be written to PIDFILE.

     If called with stop it stop a previously forked swapmon daemon.

     If called with -F it will run as a daemon but not detach from the termi‐
     nal. Messages will still be piped to LOGGGER and not to the terminal by
     default. You may specify "/bin/cat" as LOGGER to get the messages on the
     terminal.

     Default values:

     SWAP_HIGH
	      75

     SWAP_LOW
	      45

     SWAP_STEP
	      100-SWAP_HIGH (=25)

     SM_HOME  "/usr/.swap/"

     DELAY    30

     LOGGER   /usr/bin/logger

     PIDFILE  /var/run/swapmon.pid

     swapmon can be called via cron(5). In that case you would receive mes‐
     sages about the swapspace being adjusted via e-mail. To use it that way
     add a crontab entry to the root crontab similar to this:

     * * * * * /usr/local/sbin/swapmon

FILES
     /usr/local/etc/swapmonrc  optional configuration file for overwriting the
			       defaults above
     $SM_HOME		       The "homedirectory" of swapmon. In here the
			       swapfiles as well as a lockfile and the swap‐
			       file list will be created.

SEE ALSO
     swapctl(8), mdconfig(8), truncate(8), logger(1), crontab(5)

FreeBSD				April 29, 2024			       FreeBSD
[top]

List of man pages available for DragonFly

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net