My shell script will not run without errors. I have tried many different ways in implementing the script and
nothing appears to work. In my code, Sudo runs cleanwork. In order for cleanwork to execute
it needs to point to a tmp or a work directory that has long running processes that are called orphans. Those orphans
need to be remove because of disk space.
cleanwork is not a directory.
cleanwork is not in the same path as sasworks directory. This code run successfully using the command line but not in a shell script.
I am prompted for a password. I typed the password in and I get error messages which are as follows: sudo: no command found, cleanwork: no file and saswork directory does not exist.
Here is the code:
sudo ./cleanwork $WORK
sudo ./cleanwork $saswork