RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1046192 - Can't set the timer base as localtime once localtime is used in the variable attribute.
Summary: Can't set the timer base as localtime once localtime is used in the variable ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libvirt
Version: 7.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Michal Privoznik
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks: 1046193
TreeView+ depends on / blocked
 
Reported: 2013-12-24 02:57 UTC by hyao@redhat.com
Modified: 2015-03-05 07:29 UTC (History)
9 users (show)

Fixed In Version: libvirt-1.2.7-1.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1046193 (view as bug list)
Environment:
Last Closed: 2015-03-05 07:29:18 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:0323 0 normal SHIPPED_LIVE Low: libvirt security, bug fix, and enhancement update 2015-03-05 12:10:54 UTC

Description hyao@redhat.com 2013-12-24 02:57:59 UTC
Description of problem:
Can't set the timer base as localtime once localtime is used in the variable attribute.


Version-Release number of selected component (if applicable):
# rpm -qa libvirt qemu-kvm
qemu-kvm-1.5.3-30.el7.x86_64
libvirt-1.1.1-16.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1.Add the following element in the healthy domian
<clock offset='variable' adjustment='3600' basis='localtime'/>

2.# virsh start rhel
error: Failed to start domain rhel
error: unsupported configuration: unsupported clock basis 'localtime'

3.
 3.1In libvirt.org, here's the description "Since 0.9.11 the basis attribute can be either 'utc' (default) or 'localtime'. "
 3.2# man qemu-kvm | grep localtime
       -rtc [base=utc|localtime|date][,clock=host|vm][,driftfix=none|slew]
           Specify base as "utc" or "localtime" to let the RTC start at the current UTC or local time, respectively.
 3.3 change the clock setting as <clock offset='localtime'/>, start the guest. The base is set as localtime in the qemu cml.
   # ps -aux | grep win| grep rtc
       ...-rtc base=localtime
Actual results:
Can't set the timer base as localtime once localtime is used in the variable attribute.

Expected results:
From step 3, localtime base should be supported.

Additional info:

Comment 2 Michal Privoznik 2014-02-05 14:33:58 UTC
Patch proposed upstream:

https://www.redhat.com/archives/libvir-list/2014-February/msg00250.html

Comment 3 Michal Privoznik 2014-02-06 07:31:25 UTC
I've just pushed patches upstream:

commit e505db0f6c26196287524eef214dd90f9c016cbb
Author:     Michal Privoznik <mprivozn>
AuthorDate: Wed Feb 5 15:18:46 2014 +0100
Commit:     Michal Privoznik <mprivozn>
CommitDate: Thu Feb 6 08:22:22 2014 +0100

    qemuxml2argvtest: Test localtime clock basis
    
    When trying to introduce a test for previous patch, I've
    noticed that the command line is constructed using current
    time. This won't work in our test suite (unless you guys
    wants to set a specific time prior to each test run :) ).
    Therefore we need to mock calls to time(2) to return the
    same value every time it's called.
    
    Signed-off-by: Michal Privoznik <mprivozn>

commit 51bea5df5d21093bb30e4883aff19f935e811725
Author:     Michal Privoznik <mprivozn>
AuthorDate: Wed Feb 5 15:30:11 2014 +0100
Commit:     Michal Privoznik <mprivozn>
CommitDate: Thu Feb 6 07:51:07 2014 +0100

    qemuBuildClockArgStr: Allow localtime clock basis
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1046192
    
    Commit b8bf79a, which adds clock='variable', forgets to check
    localtime basis in qemuBuildClockArgStr(). So that localtime
    basis could not be used.
    
    Reported-by: Jincheng Miao <jmiao>
    Signed-off-by: Michal Privoznik <mprivozn>

v1.2.1-121-ge505db0

Comment 7 Jincheng Miao 2014-08-18 09:58:54 UTC
According to https://bugzilla.redhat.com/show_bug.cgi?id=964177#c44 ,
The basis='localtime' works well in latest libvirt-1.2.7-1.el7.

So I change the status to VERIFIED.

Comment 9 errata-xmlrpc 2015-03-05 07:29:18 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHSA-2015-0323.html


Note You need to log in before you can comment on or make changes to this bug.