Solved

System Time - SuSe Linux

Posted on 2007-03-23
4
1,409 Views
Last Modified: 2013-12-05
I have a machine running SuSe Linux 9.0.  I have changed the time on this machine twice...it sticks for a little while (a couple of hours) and then changes back to one hour earlier (darn early Daylight Savings Time change!).

I've changed the time both via command line as root and also through the GUI.  I'm guessing that this machine is going out to the web and getting an updated time from somewhere, but I can't find how to turn that off, if that is, in fact, what's happening.

Any ideas?
0
Comment
Question by:biffsmith
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 35

Accepted Solution

by:
ShineOn earned 500 total points
ID: 18787241
Did you update the Zones databases and the etc/localtime or did you just manually change the system clock?

If the system is using UTC (as is normal) but displaying local time, if you don't fix your zones databases and etc/localtime to reflect the proper DST, when you change the clock, you're changing its UTC time to be different from reality.

If it is accessing an NTP time source, then it will sync its time back to "reality" it gets from the time source.  Without the  correct offsets in your zones tables, it will change the displayed local time accordingly.

Go to ftp://elsie.nci.nih.gov/pub/ and download the current tzdata tarball, and install it.
0
 
LVL 35

Expert Comment

by:ShineOn
ID: 18787251
Oh, after you untar it, you use the zic (zone info compiler) to compile the new info into your zones databases.

SuSE Linux 9.0 should be smart enough to link the databases to your local zone setting in /etc

However - since it's SuSE Linux 9 (don't know if it's Enterprise or not, but...) you should check the Novell site.

Here's a link for the official patches for SLES: http://www.novell.com/support/dynamickc.do?externalId=3853518&sliceId=SAL_Public&command=show&forward=nonthreadedKC&kcId=3853518
0
 

Author Comment

by:biffsmith
ID: 18788087
Thanks, ShineOn!   I updated my zone info and now the date on my intranet web pages (that are housed on this machine) is correct (they are php pages just using the PHP date command), but when I run the unix date command at the prompt it's showing 1 hour later.  This is bizarre.

Any reason why that is?

0
 
LVL 35

Expert Comment

by:ShineOn
ID: 18788507
Is the date command displaying the correct time zone?

Did you re-establish the symlink to the correct zone in /etc/localtime?

Did you make sure PHP is using the correct time zone?  PHP has its own zone settings, in various places. Only if no other TZ settings are found does PHP do a "magical guess" at the timezone based on the host OS settings.

Check your code for the date_default_timezone_set function.  Check config.php.  Check for a TZ environment variable. Check for a userconfig.php.  Look for date.timezone.  
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!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you sitting there reading this and wondering how to get started with Linux? It almost seems like picking the right Linux distribution is about like picking the right college or buying a new car if you read some of the article out there. Relax… l…
This document is written for Red Hat Enterprise Linux AS release 4 and ORACLE 10g.  Earlier releases can be installed using this document as well however there are some additional steps for packages to be installed see Metalink. Disclaimer: I hav…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question