In some rare cases, a long process may hang indefinitely and be difficult for system administrators to detect. The
/usr/local/cpanel/bin/is_script_stuck script checks how long a script's current PID has run, and can notify a WHM user or kill the process.
For example, if you experience problems with hung backup processes, you could use this script in a cron job to monitor backup processes.
To run the
/usr/local/cpanel/bin/is_script_stuck script on the command line, use the following format:
You can use the following options with this script:
The absolute path to the script that you wish to check.
The amount of time that the specified script can run before the
You can append one of the following units of measure:
If you do not append a unit of measure, the script treats this value as a number of seconds. For example, specify
|The WHM username to which you wish to send a notification of the script's results.|
|Use this option if you want the script to stop (kill) the specified script if it runs longer than the specified time.|
|Print help information for the |