large time offset after kvm live migration

lklm

New Member
Nov 7, 2014
5
0
1
In use version is Proxmox 5.2. After a kvm VM is migrated online (a.k.a. live) between proxmox nodes, a larget time offset is visible inside guest. Sometimes even up to 5 minutes. The VM is CentOS 6 or 7.

# cat /sys/devices/system/clocksource/clocksource0/current_clocksource
kvm-clock

ntpd is running on host and the vm but the difference is too big and it gets correct in long time. Does proxmox provide anything to synchronize time after the VM starts running on the target node ?

I see kvm provides 'guest-set-time' command when qemu-guest-agent is running inside the guest but proxmox doesn't issue this command and the 'qm agent' doesn't support it.

Maybe some other method exists to sync the time just after live migration ?
 
ntpd is running on host and the vm but the difference is too big and it gets correct in long time. Does proxmox provide anything to synchronize time after the VM starts running on the target node ?
Was the time in sync before? To make sure, use one time server in the local network to sync from, as ntpd aggregates the time from three (default setup) time servers to calculate the time and drift.
 
The VMs use 3 ntp servers located on 3 Proxmox machines from the cluster it is running on. All proxmox machines and the VMs are monitored by Zabbix. Time difference is very small between them. Typical output from a VM:

$ ntpq -pn
remote refid st t when poll reach delay offset jitter
==============================================================================
+ip1 ip4 2 u 946 1024 377 0.599 -0.281 0.189
*ip2 ip5 2 u 811 1024 377 0.478 -0.241 0.064
+ip3 ip5 2 u 454 1024 377 0.623 -0.031 0.311
127.127.1.0 .LOCL. 10 l 44d 64 0 0.000 0.000 0.000


After the live migration is complete the offset, as I mentioned before, sometimes goes to minutes but always goes to at least a couple of seconds which is unacceptable by the apps running inside the VMs. We have a trigger set to 500 miliseconds in Zabbix. It always fires after live migration is performed. The ntpq command after live migration shows big offset to all configured ntp servers.
 
What is the output of the live migration task? How are the VMs configured (vmid.conf)?
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!