Re: TIMEZONE format (418 Views)
Reply
Trusted Contributor
Vishu
Posts: 407
Registered: ‎03-27-2007
Message 1 of 6 (437 Views)

TIMEZONE format

Hi All,

 

Little confusion here. Got stuck with the Timezone format.

 

In HP-UX 11.11, we use TZ variable to define Timezone. its value usually set as

 

EST5EDT

EST5EST

EST5CDT

 

My confusion is:

1) how this format operates? i mean we want to set timezone as EDT, why dont we use EDT...and how do we know if the timezone is set to EDT or EST... and what is this format means like EST(timezone) 5 (numeric value) EST(timezone).

 

Can you please explain me this : timezone:numeric value: timezone  stuff?

 

Thanks

Vishu

Please use plain text.
Outstanding Contributor
Pete Randall
Posts: 16,205
Registered: ‎11-03-1996
Message 2 of 6 (435 Views)

Re: TIMEZONE format

EST5EDT means 5 hours ahead of GMT and switches to Daylight Savings Time

EST5EST means 5 hours ahead of GMT and does not switch to DST

EST5CDT means 5 hours ahead of GMT, does switch, but it's actually a Central Time Zone (I think)

 

The simple answer for you is, most likely, EST5EDT, unless you are in a locale that does not set the clocks forward in the spring and back in the fall.


Pete
Please use plain text.
Acclaimed Contributor
James R. Ferguson
Posts: 21,184
Registered: ‎07-06-2000
Message 3 of 6 (431 Views)

Re: TIMEZONE format

Hi:

 

You can understand how HP-UX interprets the TZ variable by looking at the manpages for 'tztab(4)'.  The '/usr/lib/tztab' file is cached by the libC routines which in turn, provide the standard interfaces to localtime using the TZ environmental variable.

 

You can also understand how Daylight Saving time works with the 'cron' daemon by reading the 'cron(1M)' manpages.

 

Regards!

 

...JRF...

 

 

Please use plain text.
Exalted Contributor
Steven E. Protter
Posts: 33,806
Registered: ‎08-15-2002
Message 4 of 6 (429 Views)

Re: TIMEZONE format

Shalom,

Unless you are in Indiana EST5EDT is the way to go.

I think EST5... means 5 hours behind GMT not ahead. Our day starts 5 hours later than GMT.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Please use plain text.
Outstanding Contributor
Pete Randall
Posts: 16,205
Registered: ‎11-03-1996
Message 5 of 6 (428 Views)

Re: TIMEZONE format

Behind, ahead, whatever.  I thought about that for a second and decided it didn't really matter, but Thanks, Steve!


Pete
Please use plain text.
Acclaimed Contributor
Dennis Handly
Posts: 24,779
Registered: ‎03-06-2006
Message 6 of 6 (418 Views)

Re: TIMEZONE format

>EST5EDT EST5EST EST5CDT

 

I'm not sure why you have all 3 and not just one?

 

>1) how this format operates?

>Can you please explain me this: timezone:numeric value: timezone  stuff?

 

This is all under environ(5) (TZ).  And more info in tztab(4).

 

>Pete:

EST5EST means 5 hours behind of GMT and does not switch to DST

EST5CDT means 5 hours behind of GMT, does switch, but it's actually a Central Time Zone

 

Whether it switches or not depends on tztab(4).

If in tztab, it tells how much.  If not, it will switch based on USA rules.

 

If you don't want it to switch, you leave off the DST field and use: EST5

Please use plain text.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation