[clue] [tech] Asterisk in a virtual machine, timer, timing, & real time clock questions

chris fedde chris at fedde.us
Thu Aug 4 10:37:52 MDT 2011


Running ntp in a vm is frequently a problem.  The issues have to do
with conflicts between NTP hardware assumptions and the synthetic
nature of hardware interrupts inside the VM.   Most VM hypervisors
have a set of daemons to run on the guest to ensure that system
services like wall clock time are kept in synch.

On Thu, Aug 4, 2011 at 9:33 AM, Jim Ockers <ockers at ockers.net> wrote:
> Hi Collins,
>
> Collins Richey wrote:
>
> On Mon, Jul 25, 2011 at 4:59 PM, Jim Ockers <ockers at ockers.net> wrote:
>
>
>
> Unfortunately I forgot to stabilize the system clock, and by the end of the
> day the phones were unusuable because the VM system clock/time was wandering
> around and even ntpd in the VM refused to work, insisting that it did not
> know what time it was.
>
>
> When the clock is too far out of sync, ntp will refuese to do
> anything. Run ntpdate <clockreferencehost> to force setting the clock,
> then you can start ntp successfully.
>
>
> Yes, this system (based on CentOS 4.3) was already set to run ntpdate
> against a reliable clock source at boot-up (from rc.local), and ntpd was
> started right after that.  Even so, the clock in the VM was so unstable that
> ntpd could never stabilize the system time.  I think it wandered around too
> much.  In this case ntpd would never reach stratum 3 and always insisted
> that it didn't know for sure what the time was.  After I added "clock=pit"
> to the kernel boot command line then ntpd was able to stabilize the system
> clock.
>
> Jim
>
>
> _______________________________________________
> clue mailing list: clue at cluedenver.org
> For information, account preferences, or to unsubscribe see:
> http://cluedenver.org/mailman/listinfo/clue
>


More information about the clue mailing list