From 6cb50c10e87045e019b4b604444e52f7b86ec413 Mon Sep 17 00:00:00 2001 From: Ossi Salmi Date: Tue, 28 Dec 2010 10:24:56 +0200 Subject: [PATCH] Tuned ntp.conf for virtual machines --- ntpd/templates/ntp.conf.erb | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ntpd/templates/ntp.conf.erb b/ntpd/templates/ntp.conf.erb index 1126a66..51b2a9f 100644 --- a/ntpd/templates/ntp.conf.erb +++ b/ntpd/templates/ntp.conf.erb @@ -1,3 +1,8 @@ +<% if is_virtual == "true" -%> +# Don't mind if the virtualized clock appears to be behaving erratically. +tinker panic 0 + +<% end -%> # By default, exchange time with everybody, but don't allow configuration. restrict -4 default kod notrap nomodify nopeer noquery restrict -6 default kod notrap nomodify nopeer noquery @@ -13,8 +18,10 @@ driftfile /var/lib/ntp/ntp.drift <% ntp_server.each do |server| -%> server <%= server %> <% end -%> +<% if is_virtual == "false" -%> # Undisciplined Local Clock. This is a fake driver intended for backup # and when no outside source of synchronized time is available. server 127.127.1.0 fudge 127.127.1.0 stratum 10 +<% end -%>