- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Daylight Saving Time Simple Question
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2007 10:11 AM
04-10-2007 10:11 AM
So my question is 1) Is CST6 the proper setting for Central Standard Time? and 2) How do I change it on the server if it is not an option?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2007 10:24 AM
04-10-2007 10:24 AM
SolutionNOTE: Should any of your user define their unique TZ value then it will take precedence over your system TZ setting -- just as it should because TZ actually only controls how time is displayed; the system simply counts seconds since 1-Jan-1970.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2007 02:46 PM
04-10-2007 02:46 PM
Re: Daylight Saving Time Simple Question
The man page for environ tells everything about TZ. First, there is no proper setting. TZ can be anything you want. Set TZ=BILLH6 and you'll get exactly the same behavior as TZ=CST6 (man environ). The TZ value can be any 3 (or more) characters followed by the offset from UTC (aka, GMT) and that offset is not limited to hours. Here are some examples:
TZ=CST6CDT date
TZ=CST6 date
TZ=BILLH5 date
TZ=SILLY8:35:26 date
In these examples, the TZ variable is set temporarily for the date command so you see the result. That's the beauty of the TZ variable -- it controls the representation of the kernel's time (which is always GMT, no daylight saving time).
The /usr/lib/tztab is a shorthand way to track the past, present and future time changes. The CDT extension is just an additional but optional rule. However TZ doesn't have to be set to any of those rules. Define TZ as you want it, edit /etc/TIMEZONE and now everyone will see the new time. Be sure to reboot sometime so kernel processes and daemons will see the same TZ value. And TZ is very versatile. Each user can have their own TZ value so logins can be customized for users all over the world.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2007 08:19 PM
04-10-2007 08:19 PM
Re: Daylight Saving Time Simple Question
Adding an entry like this to /usr/lib/tztab will enable the default display of time as you wish, and set /etc/TIMEZONE to match
CST6
0 1 1-7 3 2007-2038 0 CST6
N.B. keep a copy of this entry so you can put it back since hp patching will overwrite this file from time to time.
As the others indicate the TZ variable controls the time display in a shell.
In order to get the kernel routine time stamps to come out the same way (since they do not use the TZ variable especially at boot time), set the timzone kernel parameter to 360 (6 hours west of Greenwich, the supplied default is 420 PST )
and if you do not want the default time display to change each spring and autumn you may set the dst kernel parameter to 0
Mike
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2007 09:05 PM
04-10-2007 09:05 PM
Re: Daylight Saving Time Simple Question
There is no need to create entries in tztab if they don't have DST. (Unless you just want to document it.) And why did you pick those particular values??
>Mike: N.B. keep a copy of this entry so you can put it back since hp patching will overwrite this file from time to time.
Adding this entry will prevent the file from being patched. :-(
>Mike: the supplied default is 420 PST)
No, that's MST.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2007 01:17 AM
04-11-2007 01:17 AM
Re: Daylight Saving Time Simple Question
As Clay mentions, this will do what I want.
"Yes, if you set TZ=CST6 then the time will always be 6 hours after UTC."
Thanks for all the help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2007 01:19 AM
04-11-2007 01:19 AM