command [arguments ...]


DESCRIPTION

     timelimit executes a given command with the supplied arguments and termi-
     nates the spawned process after a given time with a given signal.  If the
     process exits before the time limit has elapsed, timelimit will silently
     exit, too.

     Options:

     -q      Quiet operation - timelimit does not output diagnostic messages
             about signals sent to the child process.

     -S killsig
             Specify the number of the signal to be sent to the process
             killtime seconds after warntime has expired.  Defaults to 9
             (SIGKILL).

     -s warnsig
             Specify the number of the signal to be sent to the process
             warntime seconds after it has been started.  Defaults to 15
             (SIGTERM).

     -T killtime
             Specify the maximum execution time of the process before sending
             killsig after warnsig has been sent.  Defaults to 120 seconds.

     -t warntime
             Specify the maximum execution time of the process in seconds
             before sending warnsig.  Defaults to 3600 seconds.


ENVIRONMENT

     KILLSIG
             The killsig to use if the -S option was not specified.

     KILLTIME
             The killtime to use if the -T option was not specified.

     WARNSIG
             The warnsig to use if the -s option was not specified.

     WARNTIME
             The warntime to use if the -t option was not specified.


EXAMPLES

     The following examples are shown as given to the shell:

           timelimit /usr/local/bin/rsync rsync://some.host/dir /opt/mirror

     Run the rsync program to mirror a WWW or FTP site and kill it if it runs
     longer than 1 hour (that is 3600 seconds) with SIGTERM.  If the rsync
     process does not exit after receiving the SIGTERM, timelimit issues a
     default SIGKILL after 30 more seconds.


SEE ALSO

     kill(1), rsync(1), signal(3), tcpserver(n)


STANDARDS

     No standards documentation was harmed in the process of creating
     timelimit.


BUGS

     Please report any bugs in timelimit to the author.


AUTHOR

     timelimit was conceived and written by Peter Pentchev <roam@orbitel.bg>
     with contributions by Karsten W Rohrbach <karsten@rohrbach.de>.

BSD                              May 16, 2001                              BSD

Man(1) output converted with man2html