NAME
loadwatch - run a program when machine is idle
SYNOPSIS
loadwatch [options] -p pid | [--] prog [args]
DESCRIPTION
loadwatch either spawns a child process prog with the arguments args
and controls it with all its process group, or takes control of an
already running process with pid pid with all its process group.
loadwatch allows the controlled processes to run while the load average
remains below high_limit. Every delay seconds, loadwatch checks the
load average. If the load is above high_limit, the child is suspended;
the child is resumed when the load falls below low_limit.
OPTIONS
A summary of options is included below.
-h high_limit
A decimal value that sets the system load at which the child
process will be suspended. (Default: 1.25)
-l low_limit
A decimal value that sets the system load at which the child
process will be resumed. (Default: 0.25)
-d delay
An integral number of seconds that sets how often the system
load will be checked. (Default: 10)
-n copies
An integer value that sets the number of copies of prog to run.
(Default: 1)
-u file
Create a UNIX domain socket file for use by lw-ctl.
-p pid The pid of the program that should be controlled by loadwatch
(with all its process group).
SEE ALSO
lw-ctl(1), nice(1)
BUGS
You should choose low_limit and high_limit carefully. When the load
drops below low_limit, the process(es) will be resumed, and it should
not, by itself, cause the load to raise above high_limit, or the whole
will oscillate, periodically suspending and resuming the process(es).
Similarly, if several instances of loadwatch are running, they may
resume their processes at the same time, leading to oscillations if the
limits are not carefully chosen. Hence, each instance of loadwatch
affects every other instance on the computer, and should not be
considered in isolation.
AUTHOR
This manual page was written by Dale E. Martin <dmartin@debian.org>,
for the Debian GNU/Linux system (but may be used by others). It was
then updated by Nicolas Boullis <nboullis@debian.org>.
July 2003