[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 285
  • Last Modified:

How do Timezones work w/ Linux?

Hi ,
I am using Linux at work. I need to figure out how to change timezones etc... I'd also like a complete explanation of Date, how it works and so on. I have researched and found little explanation. So if someone out there has this knowledge, I would like it, I might be over or underpricing this, it seems so simple and yet I couldn't find the answer.

Red Hat 5.0 Is what we're using.
0
M0nkeyB0y
Asked:
M0nkeyB0y
  • 4
  • 2
1 Solution
 
chrismithCommented:
You need to set the TZ environment variable to the appropriate country (eg GB for england). The available choices are in /usr/share/zoneinfo (RH 5.1) or possibly /usr/lib/zoneinfo on oler systems. One source of info is the man pages for 'tzset' and 'tzfile'

Hope this helps.


0
 
M0nkeyB0yAuthor Commented:
hey,yeah, you pointed me in the right direction.... but could you tell me like how to change from central to eastern or pacific time....? I'm rather new to linux and unix in general and I guess I'm having trouble understanding the Man pages.... I will award the points, I just want a simple "sock puppet" explanation.
0
 
M0nkeyB0yAuthor Commented:
I'm sorry I huess I wasn't succinct in my Question.... I apologize all i need is to  know how to set the timezone.... I'm reading those man pages now, but it really isn't helping
for example I am sending a box to LA and I want to change from central to pacific time.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
M0nkeyB0yAuthor Commented:
I'm sorry I huess I wasn't succinct in my Question.... I apologize all i need is to  know how to set the timezone.... I'm reading those man pages now, but it really isn't helping
for example I am sending a box to LA and I want to change from central to pacific time.
0
 
chrismithCommented:
Ok, look at the link /etc/localtime it will point to something like /usr/share/zoneinfo/US/Central change it to /usr/share/zoneinfo/US/Pacific and hey presto - all will be well!


0
 
marcelofrCommented:
use setup -> timeconfig and DON'T tag hardware time to GMT...
0
 
M0nkeyB0yAuthor Commented:
hey thats just what I needed!
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

  • 4
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now