timedatectl output

238 views
Skip to first unread message

Matt Hughes

unread,
Aug 24, 2016, 2:45:03 PM8/24/16
to CoreOS User
Trying to understand two of the fields in timedatctl status.  Specifically, what is the difference between "Network time on" vs "NTP synchronized"?  Why would the latter be true but the former be false?

core@prometheus-k8s-worker-0 ~ $ timedatectl status
     
Local time: Wed 2016-08-24 18:42:46 UTC
 
Universal time: Wed 2016-08-24 18:42:46 UTC
        RTC time
: Wed 2016-08-24 18:42:46
       
Time zone: UTC (UTC, +0000)
 
Network time on: no
NTP
synchronized: yes
 RTC
in local TZ: no

core@prometheus-k8s-worker-0 ~ $ systemctl status systemd-timesyncd
systemd-timesyncd.service - Network Time Synchronization
   
Loaded: loaded (/usr/lib64/systemd/system/systemd-timesyncd.service; disabled; vendor preset: disabled)
   
Active: active (running) since Tue 2016-08-23 16:35:39 UTC; 1 day 2h ago
     
Docs: man:systemd-timesyncd.service(8)
 
Main PID: 598 (systemd-timesyn)
   
Status: "Synchronized to time server [2001:67c:440:824:91:236:251:24]:123 (2.coreos.pool.ntp.org)."
   
Memory: 668.0K
      CPU
: 690ms
   
CGroup: /system.slice/systemd-timesyncd.service
           
└─598 /usr/lib/systemd/systemd-timesyncd

Aug 23 16:35:46 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:46 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:46 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:47 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:47 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:47 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:47 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:47 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:35:47 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Network configuration changed, trying to establish connection.
Aug 23 16:36:18 prometheus-k8s-worker-0.novalocal systemd-timesyncd[598]: Synchronized to time server [2001:67c:440:824:91:236:251:24]:123 (2.coreos.pool.ntp.org).


Ivan

unread,
Aug 31, 2016, 3:18:28 PM8/31/16
to CoreOS User
"Network time on: no" indicates that systemd-timesyncd is active but disabled.
`systemctl enable systemd-timesyncd` will switch network time to "yes".

Matt Hughes

unread,
Oct 4, 2016, 9:46:45 AM10/4/16
to CoreOS User, Ivan

Sorry for the late response Ivan, but I don’t follow. What is the difference between it running and being “enabled”? Look at the logs, it clearly is doing some synching with a time server. And I guess this would be expected via the “NTP synchronized: yes” state; so what is the difference between being synchronized and “Network time on”?

Also, why would the vendor preset be disabled and not enabled?

--
You received this message because you are subscribed to a topic in the Google Groups "CoreOS User" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/coreos-user/RmOgihCjVgk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to coreos-user...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ivan Cherapau

unread,
Oct 4, 2016, 5:47:12 PM10/4/16
to Matt Hughes, CoreOS User
What is the difference between it running and being “enabled”?
"Enabled" means that a service is configured to start when the system boots. "Active" means that a service is currently running. Please refer to systemd documentation for more information.

Look at the logs, it clearly is doing some syncing with a time server.
Correct, because timesyncd is active.

And I guess this would be expected via the “NTP synchronized: yes” state; so what is the difference between being synchronized and “Network time on”?
There is not much of a difference. Whether network time synchronization is on simply reflects whether the systemd-timesyncd.service unit is enabled  Please refer to timedatectl man page for more information.


Also, why would the vendor preset be disabled and not enabled?
In general, each distribution has a policy on what services shall be enabled by default. CoreOS keeps the minimal number of enabled by default services.







To unsubscribe from this group and all its topics, send an email to coreos-user+unsubscribe@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages