It is currently Mon, 25 Sep 2023 11:30:43 GMT

Author Message
 Cron using GMT
Hi all,

Is there some way to tell cron to use GMT instead of the server's local

I'd like to create a cron job which fires at midnight GMT (Greenwich Mean
Time) every night, but my server is in Utah somewhere, and its clock is on
MDT (Mountain Daylight Time)...  I know that if I set it up to fire at 18:00
MDT, that'll be 0:00 GMT, but then I'll have to remember to correct it in
October everyone shifts back to standard time :-(


 Sun, 21 Sep 2003 19:07:17 GMT   
 Cron using GMT
I don't think there's any way to do what you're asking, specifically.

Here's a hack that would work, tho... You could schedule your process twice in
your crontab -- once at gmt-7 and once at gmt-6 (I think those are correct for
Mountain time), i.e. midnight GMT standard and daylight times.  Then, have your
process check to see if it's midnight GMT, and if not it should bail.  That way,
each of those cron entries will work for half of the year.

 Mon, 22 Sep 2003 23:13:34 GMT   
 Cron using GMT
"( ) | 3 ]" <> wrote in message

Clever hack!  Thanks for the tip!  It's surprising that one would have to go
to such lengths, though...

 Tue, 23 Sep 2003 10:35:14 GMT   
   [ 3 post ] 

Similar Threads

1. CRON using GMT,...WHY?

2. cron, GMT and TZ

3. GMT+5 or GMT-5

4. imap server is using GMT for timestamp instead of local

5. Convert local time to gmt time without using TimeZone Env variable

6. /bin/login using GMT to report .lastlogin time

7. Date command only uses GMT

8. Convert local time to gmt time without using TimeZone Env variable

9. cron.deny and cron.allow files for CRON management

10. Using cron but if i wanna do more??

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software