Note: I now also implemented it trying to follow the usual chrony
generic/OSType split as I hope this will make it more acceptable.
WIP Test PKG is available in PPA:
https://launchpad.net/~ci-train-ppa-service/+archive/ubuntu/3188
Tests:
1. starts in container if -x is set in /etc/defaults/chrony - yes
2. implies -x if not able to control clock - yes
3. in an environment where it can control the time it does so (without
fallback)- yes
4. -x in an environment where it can control the time works - TBD
#1
● chrony.service - chrony, an NTP client/server
Loaded: loaded (/lib/systemd/system/chrony.service; enabled; vendor preset:
enabled)
Active: active (running) since Wed 2018-03-07 11:15:23 UTC; 2s ago
Docs: man:chronyd(8)
man:chronyc(1)
man:chrony.conf(5)
Process: 30709 ExecStartPost=/usr/lib/chrony/chrony-helper update-daemon
(code=exited, status=0/SUCCESS)
Process: 30705 ExecStart=/usr/sbin/chronyd $DAEMON_OPTS (code=exited,
status=0/SUCCESS)
Main PID: 30707 (chronyd)
Tasks: 1 (limit: 4915)
CGroup: /system.slice/chrony.service
└─30707 /usr/sbin/chronyd -x
Mar 07 11:15:23 b systemd[1]: Starting chrony, an NTP client/server...
Mar 07 11:15:23 b chronyd[30707]: chronyd version 3.2 starting (+CMDMON +NTP
+REFCLOCK +RTC +PRIVDROP +SCFILTER +SECHASH +SIGND +ASYN
Mar 07 11:15:23 b chronyd[30707]: Disabled control of system clock
Mar 07 11:15:23 b chronyd[30707]: Frequency 0.000 +/- 1000000.000 ppm read from
/var/lib/chrony/chrony.drift
Mar 07 11:15:23 b systemd[1]: Started chrony, an NTP client/server.
#2
Mar 07 11:16:45 b systemd[1]: Starting chrony, an NTP client/server...
Mar 07 11:16:45 b chronyd[30727]: 2018-03-07T11:16:45Z Time not adjustable,
implying -x (do not set system clock)
Mar 07 11:16:45 b chronyd[30729]: chronyd version 3.2 starting (+CMDMON +NTP
+REFCLOCK +RTC +PRIVDROP +SCFILTER +SECHASH +SIGND +ASYN
Mar 07 11:16:45 b chronyd[30729]: Disabled control of system clock
Mar 07 11:16:45 b chronyd[30729]: Frequency -5.126 +/- 50.533 ppm read from
/var/lib/chrony/chrony.drift
Mar 07 11:16:45 b systemd[1]: Started chrony, an NTP client/server.
#3
● chrony.service - chrony, an NTP client/server
Loaded: loaded (/lib/systemd/system/chrony.service; enabled; vendor preset:
enabled)
Active: active (running) since Wed 2018-03-07 11:25:40 UTC; 12s ago
Docs: man:chronyd(8)
man:chronyc(1)
man:chrony.conf(5)
Main PID: 26894 (chronyd)
Tasks: 1 (limit: 551)
CGroup: /system.slice/chrony.service
└─26894 /usr/sbin/chronyd
Mär 07 11:25:40 b-test systemd[1]: Starting chrony, an NTP client/server...
Mär 07 11:25:40 b-test chronyd[26894]: chronyd version 3.2 starting (+CMDMON
+NTP +REFCLOCK +RTC +PRIVDROP +SCFILTER +SECHASH +SIGND
Mär 07 11:25:40 b-test chronyd[26894]: Initial frequency -3.327 ppm
Mär 07 11:25:40 b-test systemd[1]: Started chrony, an NTP client/server.
Mär 07 11:25:53 b-test chronyd[26894]: Selected source 84.2.44.19
#4
● chrony.service - chrony, an NTP client/server
Loaded: loaded (/lib/systemd/system/chrony.service; enabled; vendor preset:
enabled)
Active: active (running) since Wed 2018-03-07 11:27:00 UTC; 1s ago
Docs: man:chronyd(8)
man:chronyc(1)
man:chrony.conf(5)
Process: 27065 ExecStartPost=/usr/lib/chrony/chrony-helper update-daemon
(code=exited, status=0/SUCCESS)
Process: 27060 ExecStart=/usr/sbin/chronyd $DAEMON_OPTS (code=exited,
status=0/SUCCESS)
Main PID: 27062 (chronyd)
Tasks: 1 (limit: 551)
CGroup: /system.slice/chrony.service
└─27062 /usr/sbin/chronyd -x
Mär 07 11:27:00 b-test systemd[1]: Starting chrony, an NTP client/server...
Mär 07 11:27:00 b-test chronyd[27062]: chronyd version 3.2 starting (+CMDMON
+NTP +REFCLOCK +RTC +PRIVDROP +SCFILTER +SECHASH +SIGND
Mär 07 11:27:00 b-test chronyd[27062]: Disabled control of system clock
Mär 07 11:27:00 b-test chronyd[27062]: Frequency -3.327 +/- 1000000.000 ppm
read from /var/lib/chrony/chrony.drift
Mär 07 11:27:00 b-test systemd[1]: Started chrony, an NTP client/server.
All that makes me feel good for a first patch submission to upstream.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1589780
Title:
chrony.service doesn't start on LXD container
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/chrony/+bug/1589780/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs