Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
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.
Description of problem:
Change vnc password on the fly via "virsh update-device", then shutdown the guest, re-start the guest, when connect the guest windows, the new password still take effect.
As my understand, after the guest is shutdown, the vnc password should be restored to original password for next connection.
Version-Release number of selected component (if applicable):
libvirt-0.8.1-6.el6.x86_64
qemu-kvm-0.12.1.2-2.54.el6.x86_64
kernel-2.6.32-27.el6.x86_64
How reproducible:
Always
Steps to Reproduce:
1. Define a domain with a vnc password in xml config file
...
<graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' keymap='en-us' passwd='123456'/>
...
2. Start the guest, and use virt-viewer to connect the guest windows with "aaabbb" password
3. Change password on the fly.
# cat vnc_passwd.xml
<graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' keymap='en-us' passwd='222222'/>
# virsh update-device winxp vnc_passwd.xml
Device updated successfully
4. Connect the guest windows successfully with new password "222222"
5. Shutdown the guest.
6. Start the guest again.
7. Try to Connect the guest windows with old password "123456".
Actual results:
With old password "123456", connect failed. With new password "222222", connect is successful.
# virsh dumpxml <guestname>
...
<graphics type='vnc' port='5900' autoport='yes' listen='127.0.0.1' keymap='en-us'/>
...
# cat /etc/libvirt/qemu/<guestname>.xml
...
<graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' keymap='en-us' passwd='123456'/>
...
# virsh edit <guestname>
...
<graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' keymap='en-us' passwd='222222'/>
...
Expected results:
With old password "123456", connect should be successful.
Additional info:
After I restart libvirtd, the original password take effect.
When I try to run this command with "--persistent", but it failed with the following error, I am not sure it is expected.
# virsh update-device winxp vnc_passwd.xml --persistent
error: Failed to update device from vnc_passwd.xml
error: Requested operation is not valid: cannot modify the persistent configuration of a domain
Comment 2RHEL Program Management
2010-06-07 15:59:09 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release. Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release. This request is not yet committed for
inclusion.
This is definitely not intended behavior. AFAICT with current upstream, any hotplug changes are persisted in memory until the domain is redefined or libvirtd is restarted. Pretty sure things didn't work this way in the past (verifying now), but at the very least that behavior is non-obvious.
Verified.
Packages:
# rpm -qa |grep libvirt
libvirt-client-0.8.7-1.el6.x86_64
libvirt-0.8.7-1.el6.x86_64
libvirt-python-0.8.7-1.el6.x86_64
Steps to Reproduce:
Steps are the same as in the bug description.
Rechecked it on the following test environment according to description. It is passed.
Test environment:
libvirt-0.8.7-5.el6
qemu-kvm-0.12.1.2-2.144.el6
kernel-2.6.32-94.el6
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.
http://rhn.redhat.com/errata/RHBA-2011-0596.html