Bug 611229

Summary: -rtc cmdline changes
Product: Red Hat Enterprise Linux 6 Reporter: Dor Laor <dlaor>
Component: qemu-kvmAssignee: Gleb Natapov <gleb>
Status: CLOSED CURRENTRELEASE QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: low    
Version: 6.0CC: bcao, knoel, llim, mkenneth, snagar, tburke, virt-maint
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: qemu-kvm-0.12.1.2-2.91.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-11-10 21:26:04 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:

Description Dor Laor 2010-07-04 11:46:38 UTC
Description of problem:

There are two issues here:
1. The old '-rtc-td-hack' should not be used and instead we expect only the new 
   -rtc base=XXX,clock=YY,driftfix=slew to work for rtc time drifts.
   According to Gleb it does not work properly and should be fixed.

2. We need to use -rtc clock=host as default and not use clock=vm.
   If clock=vm is used we won't compensate for drifts when the VM is paused.

Comment 2 Lawrence Lim 2010-07-06 01:35:58 UTC
Do we need a bug for libvirt to update the option flag?

Comment 3 Dor Laor 2010-07-06 06:16:05 UTC
(In reply to comment #2)
> Do we need a bug for libvirt to update the option flag?    

I did that but they said correctly that they just abstract this options and top level mgmt stack really sets it up. I opened BZs for virt-manager and rhev-m already.

Comment 6 Mike Cao 2010-08-10 08:08:15 UTC
Verified on qemu-kvm-0.12.1.2-2.108.el6 

For the first issue:
steps:
1.start VM with -rtc base=2006-06-17T16:01:21,clock=host,driftfix=slew.
2.start VM with -rtc base=utc,clock=vm,driftfix=slew
3.start VM with -rtc base=localtime,clock=host,driftfix=none

Actual Results:
After every step,VM can start successfully.

For the second issue.
steps:
1.start VM with -rtc base=localtime,clock=host,driftfix=slew
2.check the rtc time by in the guest using #hwclock --show
3.stop guest 3mins
4.resume guest and re-check the rtc-time.
5.Start VM with -trc base=localtiem,clock=vm,driftfix=slew 
6.Repeat steps 2-4.

Actual Results:
After step4, Guest was compensated for drifts when the VM is paused
After step6. Guest was NOT compensated for drifts when the VM is paused.

Based on above ,the issue has already been fixed.Change status to VERIFIED.

Comment 7 releng-rhel@redhat.com 2010-11-10 21:26:04 UTC
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.