chrony lan - OT -

Tim ignored_mailbox at yahoo.com.au
Mon Jan 5 13:01:02 UTC 2015


Allegedly, on or about 05 January 2015, Bob Goodwin sent:
> Crony/ntp appears to be giving the expected results this morning after 
> being left to do whatever it does overnight and rebooting the client 
> again. So I conclude that although I can do systemctl restart chrony 
> that doesn't initiate an update of the system time correction? Not 
> knowing how to do that makes it difficult to test ...

I'm not really familiar with chrony, but did get NTP sailing smoothly in
the past.  I would expect it to work in a similar way to how NTP was
configured, and there were three common ways systems were set up to use
NTP:

1.  Start up the NTP daemon, and if the clock wasn't too far off wrong,
correct it, and keep it running on time.  i.e. It's not a set once and
ignore it thing, it's monitored and nudged about periodically.  If the
clock was too far off (e.g. several hours, or the wrong date), it'd
refuse to tweak the clock, and you'd have to manually intervene.  Of
course, if you weren't watching bootup messages, you wouldn't see any
notification about failure, and you'd only know about it by looking at
your toolbar clock, for instance.

2.  At boot time use the NTP daemon to hard force the clock to the same
time as found from a remote server, then have the NTP client keeping it
running correctly on time.

3.  Use a NTP utility (e.g. ntpdate) to hard force the clock to the same
time as found from a remote server, then have a NTP daemon keep the
clock running on time.

NTP is one of those odd ones, where the daemon is also a client (it
handles your clock using an external time source) and a server (it can
supply other computers on the network with its time).


> [bobg at box10 ~]$ ssh -XC bobg at box48
> bobg at box48's password:
> Warning: No xauth data; using fake authentication data for X11 forwarding.
> Last login: Sun Jan  4 20:36:00 2015 from box10
> 
> "fake authentication" What's that about?

No idea, can't say I've seen that before.  Sounds like you need to read
up about SSH.


> [bobg at box48 ~]$ chronyc sources
> 210 Number of sources = 1
> MS Name/IP address         Stratum Poll Reach LastRx Last sample
> ===============================================================================
> ^* box10                         2   6   377    42   -151us[-1713us] 
> +/-  321ms
> 
> This is the result with only one server, I wanted to see one working 
> before I confused things with a second unknown. It's interesting to note 
> that although it is configured to use 192.168.1.10 it correctly 
> identifies the ntp server as box10 which I assume it gets from /etc/hosts?

That, or DNS, I would say.  Like the ntp query program, there's a "-n"
option to stop name lookups.  And there is some setting regarding DNS,
mentioned in the documentation.

> I found volumes written on ntp and chrony and the remarkable things it 
> can do but what I really need is some basic information, primarily how 
> to cause it to run a new time correction cycle so I can know if a 
> configuration change has done what I want it to do?

I'd expect looking at a status report, then restarting it might provide
a clue.  Such as looking at the time since it last received data, and
how far it is from correct.  And, I would have said look at the tail
of /var/log/messages (not sure if that will still work, these days).

Since chronyd is a daemon, I expect it to run in the background and
continually tinker with the clock, like NTP did.

On the other hand, chronyc is a command line program which can be used
to control chrony, and, I think be able to use as a one-shot time
setter.

Try man chrony, run chronyc and type in help, or info chrony.  The last
one seems more informative, though hideous to read.  There's a
"makestep" chronyc command to force an instant clock set, rather than
gradually slewing the clock into sync.




-- 
tim at localhost ~]$ uname -rsvp

Linux 3.17.7-200.fc20.i686 #1 SMP Wed Dec 17 04:08:31 UTC 2014 i686

All mail to my mailbox is automatically deleted, there is no point trying
to privately email me, I will only read messages posted to the public lists.

George Orwell's '1984' was supposed to be a warning against tyranny, not
a set of instructions for supposedly democratic governments.



More information about the users mailing list