I have a Kshell script which executes a java program.
/path/to/java -jar jarfile.jar some parameters > log
Same line 5 times with different parameters appending output to log file.
cat log | mail -s email@email.com
The problem I keep having is when I put this script in cron only the last line which takes the log files & sends email is executed. All the above actual functionally required lines are ignored. I get a blank email on cron scheduled time, but the script should take around 1 hour.
But when I run the script manually, its working fine.
برچسب:
نویسنده: استخدام کار