There are 2 possible solutions. - Recommended: Fix the permissions on the /tmp directory so that non-root users can delete files.
OR
- Set the $SU_KILL_SCRIPT variable to a different path.
BEWARE: When the KILL script is moved to another location for SURUN, it may or may not be able to execute for every user (meaning hung PIDS) and the file may or may not be removed (files remain). Therefore this change is not recommended and will not be supported by Automic. Should issues arise in the future as a result of setting this variable to a different path, Automic will require you to revert the change.
Steps to set the $SU_KILL_SCRIPT variable:
- Create a directory in the Applications Manager's /tmp directory named KILLJOBS
- Edit the $AW_HOME/exec/SURUNP script and add the following lines to the script above the line "echo in SURUNP"
SU_KILL_SCRIPT= <path to the $AW_HOME/tmp directory>/KILLJOBS; export SU_KILL_SCRIPT
- Change to the directory $AW_HOME/exec
cd $AW_HOME/exec
- Change the owner of KILLJOBS to root and set the uid bit. This will allow the KILLJOBS script to be able to delete files from the $AW_HOME/tmp directory that are owned by root.
chown root KILLJOBS
chmod 4711 KILLJOBS
- Save the file, and when an SURUN job is killed the KILLJOBS files will be deleted from the $AW_HOME/tmp/KILLJOBS directory, and will no longer be created in the /tmp directory.
Fix Status: No Fix
Fix Version(s):
N/A