Cronjob hitting but not reflecting as expected for URLs
by taru.tarak from LinuxQuestions.org on (#5QYMC)
Hello,
I am using Linux Amazon Linux 2 and as per requirement I have added crontab for a URL.
Below is the crontab file for a URL conjob every 30 minute:
Quote:
I have noticed the log [/var/log/cron] and found that said command is successfully executing through crontab as shown below:
Quote:
Unfortunately, I am not getting the result as expected but I am getting result when I am hitting the URL https://www.mydomain.com/notification on browser manually.
It will be great help if you please let me know what I am doing wrong and how can I fix this.
Thank you in advance.
Regards,
I am using Linux Amazon Linux 2 and as per requirement I have added crontab for a URL.
Below is the crontab file for a URL conjob every 30 minute:
Quote:
#Every 30 minute email notification */30 * * * * wget -O - https://www.mydomain.com/notification >/dev/null 2>&1 |
Quote:
Oct 20 20:02:01 CROND[5167]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) Oct 20 20:03:01 CROND[5174]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) Oct 20 20:04:01 CROND[5181]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) Oct 20 20:05:01 CROND[5187]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) Oct 20 20:06:01 CROND[5193]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) Oct 20 20:07:01 CROND[5199]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) Oct 20 20:08:01 CROND[5205]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) Oct 20 20:09:01 CROND[5212]: (root) CMD (wget -O - https://www.mydomain.com/notification > /dev/null 2>&1) |
It will be great help if you please let me know what I am doing wrong and how can I fix this.
Thank you in advance.
Regards,