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 2030948 - [Machines] The transient vm is changed to Persistent after deleting a Network Interface
Summary: [Machines] The transient vm is changed to Persistent after deleting a Network...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: cockpit-machines
Version: 9.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 9.2
Assignee: Katerina Koukiou
QA Contact: Xianghua Chen
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-12-10 03:50 UTC by Xianghua Chen
Modified: 2023-05-09 08:27 UTC (History)
5 users (show)

Fixed In Version: cockpit-machines-283-1.el9
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-05-09 07:34:03 UTC
Type: Bug
Target Upstream Version:
Embargoed:
pm-rhel: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-105320 0 None None None 2021-12-10 03:51:49 UTC
Red Hat Product Errata RHBA-2023:2211 0 None None None 2023-05-09 07:34:14 UTC

Description Xianghua Chen 2021-12-10 03:50:54 UTC
Description of problem:[Machines] The transient vm is changed to Persistent after deleting a Network Interface

Version-Release number of selected component (if applicable):cockpit-machines-256-1.el9.noarchcockpit-258-1.el9.x86_64libvirt-dbus-1.4.1-5.el9.x86_64

How reproducible:
100%
Steps to Reproduce:1. Create a transient VM by:# virsh create CirrOS.xml --validate
# cat CirrOS.xml
<domain type='kvm'>
  <name>CirrOS</name>
  <memory unit='KiB'>1048576</memory>
  <currentMemory unit='KiB'>1048576</currentMemory>
  <vcpu placement='static'>2</vcpu>
  <os>
    <type arch='x86_64'>hvm</type>
    <boot dev='hd'/>
  </os>
  <features>
    <acpi/>
    <apic/>
    <vmport state='off'/>
  </features>
  <devices>
    <emulator>/usr/libexec/qemu-kvm</emulator>
    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2'/>
      <source file='/var/lib/libvirt/images/cirros.qcow2' index='1'/>
      <target dev='vda' bus='virtio'/>
    </disk>
    <interface type='network'>
      <source network='default' bridge='virbr0'/>
    </interface>
    <graphics type='vnc' port='5901' autoport='yes' listen='127.0.0.1'>
      <listen type='address' address='127.0.0.1'/>
    </graphics>
  </devices>
</domain>
tips: make sure there is a cirros.qcow in /var/lib/libvirt/images/ 
2. It's transient and the Persistent is no:# virsh dominfo CirrOS
Id:             7
Name:           CirrOS
UUID:           bb21f155-5449-4438-8df2-a0c5d6fed987
OS Type:        hvm
State:          running
CPU(s):         2
CPU time:       2.7s
Max memory:     1048576 KiB
Used memory:    1048576 KiB
Persistent:     no
Autostart:      disable
Managed save:   no
Security model: selinux
Security DOI:   0
Security label: system_u:system_r:svirt_t:s0:c28,c597 (enforcing)

3. Enter the VM page, add a Network interface and then delete it.4. The vm is persistent now:# virsh dominfo CirrOS
Id:             8
Name:           CirrOS
UUID:           f9e77097-0c39-4908-8162-b6913e47a97c
OS Type:        hvm
State:          running
CPU(s):         2
CPU time:       2.8s
Max memory:     1048576 KiB
Used memory:    1048576 KiB
Persistent:     yes
Autostart:      disable
Managed save:   no
Security model: selinux
Security DOI:   0
Security label: system_u:system_r:svirt_t:s0:c279,c987 (enforcing)


Actual results:As shown in step 4.

Expected results:The vm should not be changed to persistent in step 4. 
Additional info:I tried virsh with following steps , can not reproduce it:1. Create a transient vm same as above2. Add network interface:# virsh attach-interface CirrOS --type bridge --source virbr0
Interface attached successfully
3. Delete the network interface:# virsh detach-interface CirrOS  --type bridge --mac 52:54:00:eb:71:f2
Interface detached successfully
4. The Persistent is always no in 'virsh dominfo CirrOS' before or after step2&3

Comment 7 Xianghua Chen 2023-02-16 03:28:12 UTC
Verified with packages:
cockpit-machines-283-1.el9.noarch
cockpit-285-1.el9.x86_64
libvirt-dbus-1.4.1-5.el9.x86_64
libvirt-daemon-9.0.0-3.el9.x86_64

Steps:
1. Create a transient VM by:
# virsh create CirrOS.xml --validate
# cat CirrOS.xml
<domain type='kvm'>
  <name>CirrOS</name>
  <memory unit='KiB'>1048576</memory>
  <currentMemory unit='KiB'>1048576</currentMemory>
  <vcpu placement='static'>2</vcpu>
  <os>
    <type arch='x86_64'>hvm</type>
    <boot dev='hd'/>
  </os>
  <features>
    <acpi/>
    <apic/>
    <vmport state='off'/>
  </features>
  <devices>
    <emulator>/usr/libexec/qemu-kvm</emulator>
    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2'/>
      <source file='/var/lib/libvirt/images/cirros.qcow2' index='1'/>
      <target dev='vda' bus='virtio'/>
    </disk>
    <interface type='network'>
      <source network='default' bridge='virbr0'/>
    </interface>
    <graphics type='vnc' port='5901' autoport='yes' listen='127.0.0.1'>
      <listen type='address' address='127.0.0.1'/>
    </graphics>
  </devices>
</domain>
tips: make sure there is a cirros.qcow in /var/lib/libvirt/images/ 
2. It's transient and the Persistent is no:
# virsh dominfo CirrOS
Id:             1
Name:           CirrOS
UUID:           c8785042-9786-42a2-bc9a-7bbe576d9b4d
OS Type:        hvm
State:          running
CPU(s):         2
CPU time:       5.3s
Max memory:     1048576 KiB
Used memory:    1048576 KiB
Persistent:     no
Autostart:      disable
Managed save:   no
Security model: selinux
Security DOI:   0
Security label: system_u:system_r:svirt_t:s0:c223,c435 (enforcing)
Messages:       tainted: use of deprecated configuration settings
                deprecated configuration: machine type 'pc-i440fx-rhel7.6.0'
                deprecated configuration: CPU model 'qemu64'

3. Enter the VM page, add a Network interface and then delete it.
4.  It's still transient and the Persistent is no
# virsh dominfo CirrOS
Id:             1
Name:           CirrOS
UUID:           c8785042-9786-42a2-bc9a-7bbe576d9b4d
OS Type:        hvm
State:          running
CPU(s):         2
CPU time:       5.7s
Max memory:     1048576 KiB
Used memory:    1048576 KiB
Persistent:     no
Autostart:      disable
Managed save:   no
Security model: selinux
Security DOI:   0
Security label: system_u:system_r:svirt_t:s0:c223,c435 (enforcing)
Messages:       tainted: use of deprecated configuration settings
                deprecated configuration: machine type 'pc-i440fx-rhel7.6.0'
                deprecated configuration: CPU model 'qemu64'

So verified.

Comment 9 errata-xmlrpc 2023-05-09 07:34:03 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 (cockpit-machines bug fix and enhancement update), 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://access.redhat.com/errata/RHBA-2023:2211


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