Forum Discussion

safiyet_80777's avatar
Icon for Nimbostratus rankNimbostratus
Apr 04, 2011

scheduled task problem




I want to form a scheduled task. I want to use perl script. For testing cron&crontab, I write a basic script which create a file and write something to the file.



root crontab -l


cron tab for root


1-59/30 * * * * /usr/bin/diskmonitor


*/1 * * * * perl /root/createfile



I suppose that my script should work every minute. I changed it to * * * * * perl /root/createfile for testing but for both cases my script can not run and data.txt was not created.




My script is:





open (MYFILE, '>>data.txt');


print MYFILE "Bob\n";


close (MYFILE); (MYFILE);



I can not find the problem. I supposed that cron & crontab should be working in f5. Is it correct?







1 Reply

  • We use scripts when we form a home crontab with "crontab -e -u " command. our scripts works well. But we can not run scripts in "crontab -l". Can not we use these directories for our scripts? I supposed that the problem is about root user and its permissions. Is this correct?