ofp-kill(8)

NAME
ofp-kill - kills processes given their pidfiles

SYNOPSIS
ofp-kill [options] pidfile [pidfile...]

DESCRIPTION
The ofp-kill program reads each pidfile specified on the command line and sends a signal to the program associated with it, if any. It reads one line of text from pidfile, which must contain the PID of the process to kill as a text string. It then uses fcntl(2) to verify that a process with the PID from the file owns a lock on pidfile before it sends the signal. A pidfile whose name begins with / is used literally. Otherwise, /usr/local/var/run/ is prefixed. This program exists for use by ofp-switch-setup, which cannot easily implement its functionality since Perl has no portable interface to fcntl-based file locking.

OPTIONS

-s number|name, --signal=number|name
    Sets the signal to be sent to each process. Signals may be given by number (e.g. 1) or by name (e.g. HUP or SIGHUP). By default, SIGTERM is sent.

-f, --force
    Causes ofp-kill to ignore all errors without printing a message to stderr, and to exit with return code 0.

-h, --help
    Prints a brief help message to the console.

-V, --version
    Prints version information to the console.

EXIT CODE
Without -f or --force, ofp-kill exits with status 0 if at least one pidfile was given and the process represented by every pidfile was signaled successfully, otherwise with status 1. With -f or --force, ofp-kill always exits with status 0.

BUGS
There is a race between verifying the lock on pidfile and actually killing the process. ofp-kill does not wait for the signaled processes to die before exiting.

SEE ALSO
ofp-switch-setup(8)