[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Utility to set PC clock



	Subject: Re: Utility to set PC clock
	Date: Thu, Dec 17, 1998 at 05:31:53PM +1030

In reply to:debian-user-request@lists.debian.org

Quoting debian-user-request@lists.debian.org(debian-user-request@lists.debian.org):
> 
> > Does anyone know a program that will get a time from some source on
> > the net and set the system clock based on EST?  I could add it to my
> > ip-up script and the computer would never fall far behind.
> 
> Firstly, I would recommend that you use universal coordinated time
> (Greenwich Meantime or however you spell it) on your system clock.
> Then you can set the timezone in software so that time shows up
> properly.
> 
> Secondly, I think there is some way of getting your machine to automatically
> adjust for time drift, but I don't know what it is.

I use adjtimex for that. Keeps the clock within miliseconds.
 
> 
> Thirdly, here is how you can set your time from the net:
> 
> netdate is the command I used to get the time on the net.  Eg you could
> do:
> 
> 	netdate -v tick.usno.navy.mil
> 
> Sometimes a particular time server may be down, in which case you should
> try another one.

Or 

#Now set the system clock from some Internet Time servers
#       Penn St.      Univ NC        Deleware     MIT
netdate 128.118.46.3 192.101.21.1 128.175.60.175 18.72.0.3
#       

> 
> To write the time to your hardware clock, you use the command hwclock.
> For example, with your hardware clock on universal time:
> 
>         hwclock --systohc --utc

Yes thats what the manual says but I can get it to work!  I have TZ=EST-5
in /etc/profile and the hwclock gets set 5 hours off?  Thats been bugging me for 2
weeks now.  date and clock are the same but hwclock --show is 5 hours
off.  I am still working on that.  I am trying to set the date to EST
and the CMOS to GMT.

> 
> I think will do the trick.
> 
> Feel free to correct me anyone if I've made a mistake.
> 
> Cheers,
> 
> Mark.
> 
> 
> 
> _/~~~~~~~~\___/~~~~~~\____________________________________________________
> ____/~~\_____/~~\__/~~\__________________________Mark_Phillips____________
> ____/~~\_____/~~\________________________________mark@ist.flinders.edu.au_
> ____/~~\HE___/~~\__/~~\APTAIN_____________________________________________
> ____/~~\______/~~~~~~\____________________________________________________
> __________________________________________________________________________
>         "They told me I was gullible ... and I believed them!" 
> 
> 
> 
> 
> -- 
> Unsubscribe?  mail -s unsubscribe debian-user-request@lists.debian.org < /dev/null
> 
> 

-- 
Whom computers would destroy, they must first drive mad.
_______________________________________________________
Wayne T. Topa <wtopa@ix.netcom.com>


Reply to: