scripts is not running thriugh cron ...manually running fine
HI
when i am running this command manually it is working fine . but when i put it in cron there is no logfile generation under /date_export/res_logs/ from cron.log i can see that it is running in cron but files are not generating.....may be my date format is incorrect ....please help me /usr/local/bin/dcli -l root -g /root/mycell "tail -n1000 /opt/oracle.oswatcher/osw/archive/...........l'|awk '{print $1,$2,$8}' |tee /date_export/res_logs/log.`date +%d%m.%T` if i remove that date then it is generating /usr/local/bin/dcli -l root -g /root/mycell "tail -n1000 /opt/oracle.oswatcher/osw/archive/...........l'|awk '{print $1,$2,$8}' |tee /date_export/res_logs/log this is working fine .. but i hv to add date time stamp in `date +%d%m.%T` format... Regards, Ani |
This issue has come up multiple times, here's one thread: https://www.linuxquestions.org/quest...ab-4175427948/
In short: You need to escape the %, they are special when using cron. |
Thank you Druuna
HI Druuna,
Thanks a ton for your quick response. Please let me know if there is anyway to assign ponits, because i am new to this forum. i want to assign points to you. Tnx again. Regards, Ani |
Quote:
Quote:
I see you already seem to have found the helpful button, here's a link explaining the reputation system: https://www.linuxquestions.org/quest...vb3_reputation |
All times are GMT -5. The time now is 04:11 PM. |