Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Slackware This Forum is for the discussion of Slackware Linux.


  Search this Thread
Old 05-16-2008, 09:17 AM   #1
Registered: Apr 2006
Distribution: Fedora
Posts: 478

Rep: Reputation: 30
Date/Time in Slackware 12.0


Still running 12.0 and I have a question on the date/time function. I also use NetBSD and I noticed that the time was three hours behind (i.e., shows 8:00a, but really 11:00a). So I used the date string command to reset the clock to the correct time. Now, the time in Slackware is three hours ahead (i.e., shows 11:00a, but really 8:00a). As far as I know, both are set to the same timezone (Eastern Time - America/New_York).

Does anyone know how to resolve this difference?

Last edited by JMJ_coder; 05-16-2008 at 09:19 AM.
Old 05-16-2008, 09:23 AM   #2
Senior Member
Registered: Jul 2005
Distribution: Slackware
Posts: 1,178

Rep: Reputation: 47
I solved a similar issue earlier this year by using the --localtime parameter with the date command. Something like this:

date --localtime --set 08:00
I always follow a date command with hwclock --systohc

I'm writing this from memory so my syntax may be slightly incorrect
Old 05-16-2008, 01:46 PM   #3
Senior Member
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,366

Rep: Reputation: 835Reputation: 835Reputation: 835Reputation: 835Reputation: 835Reputation: 835Reputation: 835
You should make sure the permissions are correct on /etc/localtime (readable by others). Also, when setting the date/time you can either store the local time in the hardware clock or you can store it in UTC. Be sure to run `hwclock --systohc` as dracolich said above to sync the software time with the hardware clock.
Old 05-17-2008, 06:10 PM   #4
Registered: Apr 2006
Distribution: Fedora
Posts: 478

Original Poster
Rep: Reputation: 30

I was able to resolve this by adding rtclocaltime=YES to the /etc/rc.conf file on NetBSD. Now both systems are set to the same correct time.

Thanks for the suggestions.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
how to convert windows date and time to unix date and time jitupatil_2007 General 8 03-31-2008 05:58 AM
Setting system date and time affecting the clock and date on BIOS satimis Ubuntu 7 09-21-2007 08:02 AM
Start Date + Time Duration = End Date/Time calculator? ToBe Linux - General 3 09-26-2005 10:17 AM
how to change date and time in slackware 8.1 erikm103 Linux - Newbie 4 02-25-2003 06:26 PM > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:07 PM.

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