I installed the QEMU Guest Agent on my VM, but time synchronization only happens during snapshots and reboots. Is there a way to have more frequent synchronization with the host to avoid time drift?
To enable the PHC device, do the following on the guest OS:
[LIST=1]
[*]Set the ptp_kvm module to load after reboot.
# echo ptp_kvm > /etc/modules-load.d/ptp_kvm.conf
[*]Add the /dev/ptp0 clock as a reference to the chrony configuration:
# echo "refclock PHC /dev/ptp0 poll 2" >> /etc/chrony.conf
[*]Restart the chrony daemon:
# systemctl restart chronyd