The clock on my laptop runs a bit fast (no matter what OS I'm running on it, but it's been straight debian-style knoppix for a while now). Can someone point out a simple enough way to correct the time from a remote time server or similar?
The clock on my laptop runs a bit fast (no matter what OS I'm running on it, but it's been straight debian-style knoppix for a while now). Can someone point out a simple enough way to correct the time from a remote time server or similar?
Disclaimer, this is generic advice, not tested on Knoppix as I am currently downloading it.
As a first step you should look at the manual page for hwclock. It has facilities to account for clock drift, and is probably already installed.
I like Dan Bernsteins 'clockspeed' package. Essentially have to download the source and compile it. You then give it an accurate time using NTP, wait a while, give it a second accurate time using NTP. It then uses this to work out how much it has to adjust your clock by, and then sits in the background doing so.
Available from http://cr.yp.to
Warnings. Dan's stuff is not "Open Source". You get the source code from him, and can do anything you like with it except redistribute it. I have no problem with this, but some people do.
It uses the high resolution clock cycle counter on your machine, so if your machine changes its clock rate, then 'clockspeed' will not work for you.
You can write a tiny shell script which calls adjtimex in an infinite loop, or failing that you can always write a small C (or whatever) program, which calls 'adjtime', then sleeps in an infinite loop.
Installing ntp and ntp-simple should do what you want you will have to set a time server in a config file and that should be it.Originally Posted by UselessPython
[edit]
The config file would be /etc/ntp.conf put the servers at the bottom.
[/edit]
I found this on Google:-
rdate -s ntp2b.mcc.ac.uk
- run it from the command line or from a script that runs at boot. Actually I think is was Stephen (from the last post) - didn't you suggest adding these sorts of things to the bootmisc.sh script? - It works great if you do add it there.
The network time server in the command above is (obviously) UK based, you need to find one nearby, another job for Google?
many thanks, Stu.....

Intel Core i5-12500T SRL5W 2GHz 18MB 6 Core Socket LGA1700 Desktop CPU Processor
$114.99
Intel Core i5-12400 CPU 2.50GHz 6-Core 12-thread SRL5Y LGA 1700
$121.99
INTEL CORE I9-10940X X-SERIES PROCESSOR | 3.30GHZ | SRGSH
$179.99
Intel Core i7-4770 3.40GHz Quad Core SR149 LGA 1150 CPU Processor tested
$35.00
Intel Core i7-9700 Octa-Core 3 GHz Desktop Processor LGA 1151
$79.99
Intel Core i7-3770K 3.5 GHz Processor
$39.00
Intel Core I7-7700 SR338 3.60 Ghz Processor
$39.99
Intel Core i7-7700K SR33A 4.20GHz 4-Core LGA1151 CPU Processor
$62.95
AMD - Ryzen 7 5800X3D 8-Core - 16-Thread 3.4 GHz (4.5 GHz Max Boost) w/ Ice Pad
$355.99
Intel 6th Gen Core i7-6700K 4.0GHz (Turbo 4.2GHz) 4-Core LGA1151 CPU SR2L0
$38.00