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 907390 - Error occurs after change selinux from static to dynamic on virt-manager
Summary: Error occurs after change selinux from static to dynamic on virt-manager
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virt-manager
Version: 7.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Martin Kletzander
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-02-04 09:31 UTC by tingting zheng
Modified: 2014-06-17 23:58 UTC (History)
6 users (show)

Fixed In Version: virt-manager-0.10.0-1.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 907399 (view as bug list)
Environment:
Last Closed: 2014-06-13 09:27:34 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Dedug info from virt-manager (7.31 KB, text/plain)
2013-02-04 09:31 UTC, tingting zheng
no flags Details

Description tingting zheng 2013-02-04 09:31:30 UTC
Created attachment 692667 [details]
Dedug info from virt-manager

Description of problem:
Error occurs after change selinux from static to dynamic on virt-manager

Version-Release number of selected component (if applicable):
virt-manager-0.9.4-4.el7.noarch
libvirt-1.0.0-1.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Prepare an VM which is not running.
2. Issue "virt-manager" to open virt-manager.
3. Select the existing VM, then "open" -> "details" -> "Overview" -> "Security"
4. Select "static" option, then specify a label,and apply it.
such as: "system_u:system_r:svirt_t:s0:c100,c200"
5. Change selinux to dynamic,then apply,error occurs:Error changing VM configuration: unsupported configuration: dynamic label type must use resource relabeling

Actual results:
Error occurs after change selinux from static to dynamic from virt-manager as steps show.

Expected results:
No error shows and change selinux from static to dynamic successfully.

Additional info:
1.Attached the debug info from virt-manager.
2.Info from virt-manager --debug,I noticed that after change selinux from static to dynamic,the relabel attribute is always set as "no",if update to "yes",no such error shows.
--- Original XML
+++ New XML
@@ -87,7 +87,7 @@
       <address type="pci" domain="0x0000" bus="0x00" slot="0x06" function="0x0"/>
     </memballoon>
   </devices>
-  <seclabel type="static" model="dac" relabel="no">
+  <seclabel type="dynamic" model="dac" relabel="no">
     <label>system_u:system_r:svirt_t:s0:c100,c200</label>
   </seclabel>
 </domain>

Comment 2 Martin Kletzander 2013-02-05 13:08:38 UTC
Patch proposed upstream:

https://www.redhat.com/archives/virt-tools-list/2013-February/msg00028.html

Comment 3 Martin Kletzander 2013-02-07 09:07:41 UTC
Moving to POST:

commit b6f0ba364f6376793989450869db83e117586cec
Author: Martin Kletzander <mkletzan>
Date:   Tue Feb 5 12:28:06 2013 +0100

    Add support for security relabeling

Comment 5 tingting zheng 2013-08-15 08:44:13 UTC
Tested the bug with:
virt-manager-0.10.0-2.el7.noarch

New version of virt-manager can change selinux from static to dynamic successfully,so move the bug to VERIFIED.

Comment 6 Ludek Smid 2014-06-13 09:27:34 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.


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