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 1913205 - [machines] The CPU type should not keep on changing between running and shutdown status
Summary: [machines] The CPU type should not keep on changing between running and shutd...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: cockpit-appstream
Version: 8.4
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: rc
: 8.4
Assignee: Katerina Koukiou
QA Contact: Xianghua Chen
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-01-06 09:23 UTC by Xianghua Chen
Modified: 2021-05-18 15:53 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-05-18 15:53:30 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Xianghua Chen 2021-01-06 09:23:09 UTC
Description of problem: 
The CPU type should not keep on changing between running and shutdown status

Version-Release number of selected component (if applicable):
cockpit-machines-234-1.el8.noarch
libvirt-dbus-1.3.0-2.module+el8.3.0+6423+e4cb6418.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Prepare a bare metal machine (Not a Virtual env) 

2. Click Import VM, input the name/prepared vm image/os, then unclick "Immediately start VM", click Import

3. Enter the VM detail page, and,  the CPU type is host as default

4. Click Run,the CPU type will change according to the host cpu,e.g.: custom (Haswell-noTSX-IBRS) 

There is an icon showing "Changes will take effect after shutting down the VM"

Check the CPU mode in xml ,same to the value on the page, by :

# virsh dumpxml vm-name

5. Click shutdown , the CPU type changed back to host, it will change back to the value in step 4 if you run it again.



Actual results:
There is icon showing "Changes will take effect after shutting down the VM" and then it change to host after shutting down



Expected results:
The CPU type should not keep on changing between running and shutdown status

Additional info:

Comment 1 Katerina Koukiou 2021-01-06 10:21:36 UTC
Checking the XML configuration from the CLI the <cpu> entry is indeed different between active and inactive XML. For example:

Stopped domain:

  <cpu mode='host-model' check='partial'/>


Running domain:

  <cpu mode='custom' match='exact' check='full'>
    <model fallback='forbid'>Skylake-Client-IBRS</model>
    <vendor>Intel</vendor>
    <feature policy='require' name='ss'/>
    <feature policy='require' name='vmx'/>
    <feature policy='require' name='pdcm'/>
    <feature policy='require' name='hypervisor'/>
    <feature policy='require' name='tsc_adjust'/>
    <feature policy='require' name='clflushopt'/>
    <feature policy='require' name='umip'/>
    <feature policy='require' name='md-clear'/>
    <feature policy='require' name='stibp'/>
    <feature policy='require' name='arch-capabilities'/>
    <feature policy='require' name='ssbd'/>
    <feature policy='require' name='xsaves'/>
    <feature policy='require' name='pdpe1gb'/>
    <feature policy='require' name='ibpb'/>
    <feature policy='require' name='amd-stibp'/>
    <feature policy='require' name='amd-ssbd'/>
    <feature policy='require' name='skip-l1dfl-vmentry'/>
    <feature policy='require' name='pschange-mc-no'/>
    <feature policy='disable' name='mpx'/>
  </cpu>


I am guessing this is expected, so I will just remove the warning Icon and let the UI update the CPU field without notifying the user when the state is tweaked.

Comment 2 Xianghua Chen 2021-01-07 02:32:50 UTC
Thanks for the explanation, yes it make sense, let's just make it silent.

Comment 3 Martin Pitt 2021-01-07 05:54:39 UTC
Katerina sent a fix in https://github.com/cockpit-project/cockpit/pull/15105 , thank you!

Comment 6 Xianghua Chen 2021-01-13 07:07:21 UTC
Verified with package:
cockpit-machines-235-1.el8.noarch
libvirt-dbus-1.3.0-2.module+el8.3.0+6423+e4cb6418.x86_64

Verify steps:
1. Prepare a bare metal machine (Not a Virtual env) 
2. Click Import VM, input the name/prepared vm image/os, then unclick "Immediately start VM", click Import
3. Enter the VM detail page, and,  the CPU type is host as default
4. Click Run,the CPU type will change according to the host cpu,e.g.: custom (Haswell-noTSX-IBRS) 
There is no icon showing "Changes will take effect after shutting down the VM"
Check the CPU mode in xml ,same to the value on the page, by :
# virsh dumpxml vm-name
5. Click shutdown , the CPU type changed back to host, check the xml again.

No icons showing "Changes will take effect after shutting down the VM"
So verified.

Comment 8 errata-xmlrpc 2021-05-18 15:53:30 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-appstream 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-2021:1875


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