LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 11-23-2013, 04:24 PM   #16
tronayne
Senior Member
 
Registered: Oct 2003
Location: Northeastern Michigan, where Carhartt is a Designer Label
Distribution: Slackware 32- & 64-bit Stable
Posts: 3,541

Rep: Reputation: 1065Reputation: 1065Reputation: 1065Reputation: 1065Reputation: 1065Reputation: 1065Reputation: 1065Reputation: 1065

Something you may want to try in /etc/ntp.conf; where the servers are specified, make it look like this (note that you need to be root to do these things):
Code:
#
# NTP server (list one or more) to synchronize with:
#server pool.ntp.org iburst
server	0.us.pool.ntp.org
server	1.us.pool.ntp.org
server	2.us.pool.ntp.org
Note that three external servers are all you need.

Stop and restart NTPD; i.e.,
Code:
/etc/rc.d/rc.ntpd stop
<wait about 30 seconds>
/etc/rc.d/rc.ntpd start
If you run ntpq -pn, you'll see something similar to this (note: if you don't see web addresses in the remote and refid columns you've got a network problem):
Code:
ntpq -pn
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
*127.127.1.0     .LOCL.          10 l    7   64    1    0.000    0.000   0.001
 72.14.188.52    129.7.1.66       2 u    4   64    1  580.715  -16.742   0.001
 66.175.209.17   64.90.182.55     2 u    6   64    1  606.655    0.502   0.001
 138.236.128.112 127.67.113.92    2 u    8   64    0    0.000    0.000   0.001
That indicates that you're synced with the local clock only, which is normal when NTPD is first started or restarted. Wait about five minutes, maybe a little less, and run ntpq -pn again and you should see something similar to this:
Code:
ntpq -pn
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
 127.127.1.0     .LOCL.          10 l  110   64   76    0.000    0.000   0.001
*72.14.188.52    129.7.1.66       2 u   24  128   77  569.475  -12.331   6.628
+66.175.209.17   209.51.161.238   2 u   27   64   77  606.655    0.502  14.329
+138.236.128.112 127.67.113.92    2 u   37   64   37  617.451   -4.439  11.502
The asterisk in column 1 indicate that you're synced with that pool server (you will not have the same internet addresses as shown here, they'll be different). The plus signs indicate that those pool servers are candidates for synchronization if or when the asterisk-marked server goes away or becomes noisy or unstable.

Keep in mind that the NTP daemon needs to have 24/7 internet access to keep your system clock on time; if your network connection goes away, the daemon will simply synchronize to the "LOCL" clock (which is your system clock) until the internet connection comes back. At that time, NTPD will once again synchronize with an external time server.

Finally, if your system clock drifts too much, NTP will not be able to synchronize it (more than about five minutes drift and you won't get synchronization). In that case, you'll want to check the battery on your system motherboard -- it may be fully discharged and you'll need a new one -- or there may be some software adjustments needed to "step adjust" your system clock (that's for another day, though, try the above stuff first).

Hope this helps some.
 
Old 11-24-2013, 08:26 AM   #17
interndan
Member
 
Registered: Aug 2004
Location: near Marion, Ill
Distribution: Slackware 15 64bit on Desktop Slackwarearm on Raspberry PI v1b
Posts: 381

Rep: Reputation: 38
I create a file called settime in cron.daily with the following
Code:

/usr/sbin/ntpdate north-america.pool.ntp.org && /sbin/hwclock -w

make it executable (chmod +x) this checks time and updates hardware clock every day. Of course you need to change time server for your locale.
 
  


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
LXer: Ubuntu syncs up with OpenStack LXer Syndicated Linux News 0 10-14-2013 03:20 PM
rsync re-syncs same files tripialos Linux - Newbie 3 03-04-2013 04:50 AM
rsync problem - syncs all files MarcusWebb1966 Linux - General 22 09-19-2012 05:58 AM
[SOLVED] display/montor (re)syncs on every screen switch cheesus Linux - Hardware 3 11-26-2007 04:13 PM
Palm PDA no longer syncs oneandoneis2 Linux - Hardware 2 03-28-2005 04:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 10:28 AM.

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