Bug 632541
Summary: | KVM guest will time drift 8 second after booting | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 5 | Reporter: | XinSun <xinsun> |
Component: | kvm | Assignee: | Rik van Riel <riel> |
Status: | CLOSED WONTFIX | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 5.6 | CC: | byu, dawu, ehabkost, gleb, mkenneth, mshao, rhod, virt-maint, ykaul |
Target Milestone: | rc | Keywords: | Triaged |
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2011-08-08 14:52:21 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | |||
Bug Blocks: | 580948 |
Description
XinSun
2010-09-10 10:13:28 UTC
Maybe a duplicate of bug #523478. What happens if you rename or delete /sbin/hwclock in the guest, so it is not run on boot? Tested this bug on latest build,there is 1-2 seconds time drift after booting,following is the details: Host: rhel5.6 server Kernel: 2.6.18-241.el5 Kvm: kvm-83-224.el5 Guest: RHel 5.6 x86_64 kernel: 2.6.18-231.el5 Steps: 1.Start guest with CLI: /usr/libexec/qemu-kvm -m 2G -smp 2 -cpu qemu64,+sse2 -drive file=RHEL-Server-5.6-64-virtio.raw,media=disk,if=virtio,boot=on,cache=none,werror=stop -net nic,model=virtio,vlan=0,macaddr=00:10:16:10:62:10 -net tap,vlan=0,script=/etc/qemu-ifup -uuid 14371d1a-d2b5-4fe9-a61c-ad25207673c6 -monitor stdio -vnc :1 -boot c -usbdevice tablet -no-hpet -rtc-td-hack -no-kvm-pit-reinjection -startdate now 2.Before shut down kvm guest, do time synchronization with ntp server for host and guest: [host]# ntpdate 10.5.26.10 31 Jan 03:12:03 ntpdate[6771]: adjust time server 10.5.26.10 offset 0.000907 sec [guest]# ntpdate 10.5.26.10 31 Jan 03:11:50 ntpdate[2304]: adjust time server 10.5.26.10 offset 0.000782 sec 2.Shut down kvm guest 3.Then boot it again 4.After booting, check time synchronization [guest]# ntpdate -q 10.5.26.10 server 10.5.26.10, stratum 1, offset 1.845853, delay 0.36089 31 Jan 03:15:40 ntpdate[2270]: step time server 10.5.26.10 offset 1.845853 sec resut: after booting, guest will have 1-2 seconds time drift. The time sync with NTP server is only effective as long as the VM is up, and it is not saved anywhere for the next boot. On real hardware it would have been saved in the RTC (hardware clock that keeps counting when you turn off the machine) that is not emulated. Gleb, please confirm. Anyhow, closing since it is not high priority for RHEL5.8 (In reply to comment #6) > The time sync with NTP server is only effective as long as the VM is up, and it > is not saved anywhere for the next boot. On real hardware it would have been > saved in the RTC (hardware clock that keeps counting when you turn off the > machine) that is not emulated. > Gleb, please confirm. RTC part is irrelevant. Since the host is ntp synched the guest will get perfectly up-to-date time in RTC during boot. > Anyhow, closing since it is not high priority for RHEL5.8 |