LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-30-2005, 01:12 PM   #1
pvlogin
LQ Newbie
 
Registered: Oct 2005
Posts: 2

Rep: Reputation: 0
modification time off 1 hour between linux and windows after DST adjustment


Hi all,

I am not sure if it's linux or windows (or both) but I am trying to understand why after every daylight time adjustment the modification times of my files are off by one hour between the 2 systems. I have windows client (Windows XP) and Linux server (Suse Prof. 9.x) which exports a backup fs via samba. I regularly perform rsync from the windows machine to the backup fs on the linux server. Nothing fancy - the windows machine just maps the samba exported fs and I use cygwin rsync to sync the files.

The time has just moved one hour back this weekend - the Windows machine corrected the time automatically. The linux server had to be manually adjusted. But why are the file modification times off by one hour? All the modification times are one hour older on the linux server. Why?

Could it be that when you create a file on a windows machine in summer it will actually create a file with modtime one hour back on the disk but reports it with DST adjustment? That's the only explanation I can think of.

Windows XP - NTFS fs

Linux 9.x Suse - ext3, reiserfs, time is kept in local time in RTC.

thanks

--pv
 
Old 10-31-2005, 04:24 AM   #2
berbae
Member
 
Registered: Jul 2005
Location: France
Distribution: Arch Linux
Posts: 540

Rep: Reputation: Disabled
Hi pvlogin
windows xp uses the RTC in local time mode and manages the DST adjustment by setting the RTC to the new time.
you say "time is kept in local time in RTC" on the linux server, but are you sure you have adjusted the RTC to the new time and not the system clock only ? Because you must use the command 'hwclock --set --date=' and not 'date' under root login to set the RTC.
Please give precisions on how you manually adjusted the time on the linux server.
 
Old 10-31-2005, 12:45 PM   #3
pvlogin
LQ Newbie
 
Registered: Oct 2005
Posts: 2

Original Poster
Rep: Reputation: 0
I modified the time via yast ->system ->date and time -> modify time. I am not sure which time this actually modifies (I'll check that later once I get to the machine again). But - I have looked around and it seems that my problem is in windows - depending on if the DST in windows is turned on or off windows reports different times -

http://www.codeproject.com/datetime/dstbugs.asp

--pv
 
Old 11-01-2005, 09:51 AM   #4
berbae
Member
 
Registered: Jul 2005
Location: France
Distribution: Arch Linux
Posts: 540

Rep: Reputation: Disabled
Apparently YaST modify time only changes the system clock like the date command.
To change the RTC you must do it manually in a console under root login with
hwclock --set --date=

see 'man hwclock' for the date format

You can check if
hwclock --show (RTC time)
gives the same time as
date (system clock time)

you can also run
hwclock --systohc
to set the Hardware Clock to the current System Time
(as said in 'man hwclock')

Last edited by berbae; 11-01-2005 at 10:01 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
am/pm verses 24 hour time CouchMaster SUSE / openSUSE 8 05-20-2015 10:13 AM
time adjustment SUSE 9.0 metallica1973 Linux - Software 2 10-25-2005 06:02 PM
linux time changes 1 hour -- after reboot mrconover Linux - Software 4 10-07-2004 05:13 PM
Why is the time always an hour behind? aaa LQ Suggestions & Feedback 6 07-23-2003 12:34 PM
modification time in the future adam_boz Linux - Software 2 07-28-2002 07:51 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:01 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration