|
NAMErunlock - run another program with a lockfileSYNOPSISrunlock [-bpx] lockfile program [ args ... ]runlock -c [-q] lockfile runlock -V | -h DESCRIPTIONrunlock may be used to run a program with a lockfile, or to check a lockfile for the presence of an existing lock.In the first form of the command, lockfile is a filename and program is an executable program. runlock opens lockfile for writing (creating it if it does not exist), obtains an exclusive posix advisory lock on it (see fcntl(2)), and then runs program with any remaining arguments. If the specified program name does not contain a ``/'' slash character, runlock will search for the executable in the search path defined in the environment by the PATH variable. As long as program does not itself explicitly release the lock or close the descriptor for lockfile, the lock will remain until the program exits. Cooperative programs may test for the existence of a lock on lockfile to limit the execution of program to a single instance. In the second form of the command (with the -c option), runlock will check lockfile for an existing lock. If lockfile exists and can be opened for writing, runlock will report the pid of the process which holds a lock on the file. Note that the usefulness of this check is limited. A lock on lockfile may be acquired or released by another process at anytime. OPTIONS
EXIT STATUSrunlock exits with one of the following values:
AUTHORWayne Marshall, http://b0llix.net/perp/SEE ALSOruntools_intro(8), runargs(8), runargv0(8), runchoom(8), rundetach(8), rundeux(8), runenv(8), runfile(8), runlimit(8), runpause(8), runsession(8), runtool(8), runtrap(8), runuid(8)
Visit the GSP FreeBSD Man Page Interface. |