We recently tried out the cron service version 3.4.0. We feel that Bug #3031791 (https://sourceforge.net/p/staf/bugs/1357/) was not fixed properly. When the cron.ser file is not accessible by the cron service it does throw an error now, but it goes ahead and adds the entry in the cron anyway. This entry is added in the memory, because we don't see any entry in the cron.ser file. This creates disparity between what is in the memory and what is on the file. It leads to inconsistenties in the cron service.
The correct behavior should be, when the cron service encounters any error it should not add an entry either in memory or in the file.
Below you can find the steps that we tried out --
-bash-3.2$ staf local starcron version
Response
3.4.0
----- Nothing in the cron service
-bash-3.2$ staf local starcron list
Response
-bash-3.2$
----- Request to add entry to cron
-bash-3.2$ STAF local starCRON REGISTER MACHINE local SERVICE PROCESS REQUEST "START COMMAND notepad" HOUR 1
Error submitting request, RC: 19
Additional info
Saving registration data to file /usr/local/staf/data/STAF/service/starcron/cron.ser failed.
java.io.FileNotFoundException: /usr/local/staf/data/STAF/service/starcron/cron.ser (Permission denied)
See the service log for more information and contact the system administrator for the service machine.
-bash-3.2$
-bash-3.2$
**----- Request failed but the entry was added to the cron service
----- This is where the problem is, the entry should not be added.
-bash-3.2$ staf local starcron list
Response
ID Desc Machine Service Request Minute Hour Day Month Weekday Once
1 <none> local PROCESS START COMMA <none> 1 <none> <none> <none> false
ND notepad </none></none></none></none></none>
-bash-3.2$