Jump to content

Recommended Posts

Posted

Hi there. I tried to add a cronjob on Tommy Server for a simple SQL update query on my DB using the command below, but it didn't work:

 

mysql --user=DBUSER --password=PASS --database=DBNAME --execute="UPDATE table SET colunm=value;"

 

 

I've set this cronjob to 13:30 20th MAR but nothing happened. Do you guys have any tip on the syntax I used or where can I see the log for this query ?

 

Thanks!

Paulo.

 

 

 

Posted

I also tried running a cronjob from a php command: php -q /home/atn2017/public_html/cronjob.php

 

But it didn´t work anyway.

 

Any tip ?

Posted

 

I've set this cronjob to 13:30 20th MAR but nothing happened. Do you guys have any tip on the syntax I used or where can I see the log for this query ?

 

Thanks!

Paulo.

 

Your cron hasn't run yet. The server time is PST. As of the time of this post, it was 8:36 am.

  • Like 1
Posted

Output is sent to the default cpanel mail account (username@server.heliohost.org). You can check that mailbox via the webmail to see the results.

Posted

@Krydos & wolstech, I set up a cron to test with this syntax:

35 8 * * * php -q /home/byron/public_html/php/mail.php

And it ran at 8:35 am PST.

  • Like 1
Posted

 

 

I've set this cronjob to 13:30 20th MAR but nothing happened. Do you guys have any tip on the syntax I used or where can I see the log for this query ?

 

Thanks!

Paulo.

 

Your cron hasn't run yet. The server time is PST. As of the time of this post, it was 8:36 am.

 

Thanks ! I was wondering about it... Because I checked tommy time zone at http://heliohost.grd.net.pl/server-time/, but I think it's wrong....

Posted

@Krydos & wolstech, I set up a cron to test with this syntax:

35 8 * * * php -q /home/byron/public_html/php/mail.php

And it ran at 8:35 am PST.

 

:D

 

@Krydos & wolstech, I set up a cron to test with this syntax:

35 8 * * * php -q /home/byron/public_html/php/mail.php

And it ran at 8:35 am PST.

 

By the way, are you on Tommy ? PST right now is 8:07 AM......

Posted

...I hate timezones.

 

I'm guessing cron honors the local timezone settings since the server clock is UTC...

 

My 1st attempt was using UTC, but didn't work. I'm now trying Pacific Time..... Let's see....

 

 

 

well... I check up on https://time.is/PST ... it says 1h earlier..... I'll do again with 1h later....

 

Worked, @Byron ! Thanks, pal....

 

Sorry about that. We're actually on PDT (Pacific Daylight Time). https://www.google.com/search?q=Pacific+Daylight+Time

 

Perfect... Is there a way to confirm it in the future ?

  • 2 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...