Author Topic: Ongoing Issue With Crontab  (Read 91 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
Ongoing Issue With Crontab
« on: April 28, 2019, 04:57:42 PM »
So, I wasn't sure where to post this, but I've been having an ongoing issue with Crontab / Cron jobs.

Cron was working perfectly fine up until recently. I'm not sure what exactly changed, I logged in and saw there was updates available for my server and I was unable to update via the control panel, so I went in to SSH.

In SSH I received the following error:
nginx: [warn] the “ssl” directive is deprecated, use the “listen … ssl” directive instead

Came across this thread -
https://community.easyengine.io/t/solution-nginx-warn-the-ssl-directive-is-deprecated-use-the-listen-ssl-directive-instead/10784

that didn't work.

From there, I figured okay, maybe it's just crontab in general.

When I go to CWP and try to add a cronjob, there's no error or anything when I login as root - it doesn't add the cron job anywhere though. Not in CWP nor in the crontab logs / active crons

When I login under a user account and go to add a cron and go to "Crontab for user" I receive the following error:
"Your tasks can not be executed until you solve the error that is presented"

but there is no error(s) shown.

So then I go in and add a cronjob via SSH - last ditch effort.
* */2 * * * curl http://LINK/to/file.php

and it's supposed to run every two hours but it's running every 15 minutes or so, and yet again, in the CWP backend it's not showing under the user account nor the root user when logged in to root, or in to the user account itself.

When I go in to SSH and use the command -
crontab -u USERNAMEHERE -l
it shows the cronjob as active / in the list.

Now finally, when I figure okay, maybe it's just a display issue or something, I check the log file using the command -
tail -n 20 /var/log/cron

According to the log, the cron job was never ran.

Does any one have any ideas or suggestions? I'm at my wits end with this.

Offline
*****
Re: Ongoing Issue With Crontab
« Reply #1 on: April 29, 2019, 05:43:04 AM »
Hello.

You can ignore
Quote
nginx: [warn] the “ssl” directive is deprecated, use the “listen … ssl” directive instead

Try to run in console: curl http://LINK/to/file.php and check what happens.

Offline
***
Re: Ongoing Issue With Crontab
« Reply #2 on: May 13, 2019, 08:05:43 PM »
check /var/spool/cron for existence of cronjobs