Replace chronyc "waitsync" with "makestep"
Prior to this patch we had the "chrony waitsync" command with a
hardcoded timeout of "20". Sometimes that wasn't enough when deploying
on some slower machines in my experience [0].
This patch is changing the "waitsync" command to "makestep", that way
we tell chronyd to make the system clock correct immediately (instead
of gradually correcting the time). It should be fine for our usecase
because these are ran during the deployment.
[0] http://paste.openstack.org/show/783888/
Closes-bug: #1867362
Change-Id: I07057eb089585f43346c44a03ae50aa2ac837fd7
Signed-off-by: Lucas Alvares Gomes <lucasagomes@gmail.com>
(cherry picked from commit 373a27163e
)
This commit is contained in:
parent
d7b1bfe79d
commit
31c6b199b8
|
@ -122,7 +122,7 @@ outputs:
|
|||
- name: Ensure chrony has been restarted
|
||||
meta: flush_handlers
|
||||
- name: Ensure system is NTP time synced
|
||||
command: chronyc waitsync 20
|
||||
command: chronyc makestep
|
||||
ansible_group_vars:
|
||||
chrony_role_action: all
|
||||
chrony_ntp_servers: {get_param: NtpServer}
|
||||
|
|
|
@ -74,7 +74,7 @@ resources:
|
|||
set -x
|
||||
if [ "$service" = "chrony" ]; then
|
||||
if command -v chronyc >/dev/null; then
|
||||
chronyc waitsync 20
|
||||
chronyc makestep
|
||||
else
|
||||
echo "No chronyc available, skipping sync"
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue