Re: KVM-Clock

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Feb 24, 2016 at 03:27:45PM +0000, Avi Cohen wrote:
> 
> 
> >Subtracting tsc_offset later is easier.
> 
> >> In guest : rx_time = tsc_to_ns * rdtsc()
> >>                   Delay = rx_time - tx_time 
> >> 
> >> How to  enable kvm_write_tsc_offset ?
> 
> ># echo kvm_write_tsc_offset > /sys/kernel/debug/tracing/set_event
> 
> >Then boot guest
> 
> >Then cat /sys/kernel/debug/tracing/trace
> 
> OK - I did it and it is indeed accurate. But this will not solve my problem, because I need the host realtime clock in my guest and not the host-TSC

Configure NTP to synchronize from host NTPd server. How close the host
and guest clocks can be synchronized depends on how reliable is the
transmission of data between guest and host.

Then use the guest/host TSCs to measure how accurate the clocks are.

> In my application VMa in  HOSTa is sending a 1-way delay measurement packet to VMb in HOSTb.
> I'm perfectly synching the 2 hosts with PTP.
> I need that the  2 guests's clocks will be synched  to their hosts  i.e. VMa/VMb  is sync to HOSTa/HOSTb accordingly   

Chronyd in the guest should work, syncing from NTPd server in the host 
(haven't configured that setup myself, about to do so soon).


--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux