Bug 592172 - RFE: Add parameter to set guest machine type
RFE: Add parameter to set guest machine type
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: python-virtinst (Show other bugs)
6.0
All Linux
low Severity medium
: rc
: ---
Assigned To: Cole Robinson
Virtualization Bugs
: FutureFeature
Depends On:
Blocks: 655920
  Show dependency treegraph
 
Reported: 2010-05-14 01:54 EDT by zhanghaiyan
Modified: 2011-05-19 09:45 EDT (History)
9 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
virt-install now includes the --machine option. This is useful for manually choosing the guest machine type to emulate.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-05-19 09:45:17 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:0636 normal SHIPPED_LIVE python-virtinst bug fix and enhancement update 2011-05-18 13:55:48 EDT

  None (edit)
Description zhanghaiyan 2010-05-14 01:54:35 EDT
Description of problem:
virt-install doesn't provide any parameter to set guest machine type, which causes all guest xml config file use default value 'machine='rhel6.0.0'' 

Version-Release number of selected component (if applicable):
- kernel-2.6.32-25.el6.x86_64
- python-virtinst-0.500.3-2.el6.noarch
- qemu-kvm-0.12.1.2-2.53.el6.x86_64
- qemu-img-0.12.1.2-2.53.el6.x86_64
- libvirt-0.8.1-3.el6.x86_64


How reproducible:
Always

Steps to Reproduce:
1. # virt-install -n rhel55-i386 -r 2048 -l http://download.englab.nay.redhat.com/pub/rhel/released/RHEL-5-Server/U5/i386/os/ -f /var/lib/libvirt/images/rhel55-i386.img
Starting install...
Retrieving file .treeinfo...                                                                                                          |  876 B     00:00 ... 
Retrieving file vmlinuz...                                                                                                            | 3.6 MB     00:00 ... 
Retrieving file initrd.img...                                                                                                         |  14 MB     00:00 ... 
Creating domain...  
2. # virsh dumpxml rhel55-i386
<domain type='kvm' id='2'>
  <name>rhel55-i386</name>
  <uuid>41fdcbb2-f6cf-cb03-e6c8-203e48cc0d9b</uuid>
  <memory>2097152</memory>
  <currentMemory>2097152</currentMemory>
  <vcpu>1</vcpu>
  <os>
    <type arch='x86_64' machine='rhel6.0.0'>hvm</type>
................
  
Actual results:
Because no parameter to set guest machine type, rhel55 guest is defined as machine='rhel6.0.0' defautly. 

Expected results:
Provide parameter to set guest machine types, and give some value example:
# /usr/libexec/qemu-kvm -M ?
Supported machines are:
pc-0.12    Standard PC
pc-0.11    Standard PC, qemu 0.11
pc-0.10    Standard PC, qemu 0.10
isapc      ISA-only PC
pc         RHEL 6.0.0 PC (alias of rhel6.0.0)
rhel6.0.0  RHEL 6.0.0 PC (default)
rhel5.5.0  RHEL 5.5.0 PC
rhel5.4.4  RHEL 5.4.4 PC
rhel5.4.0  RHEL 5.4.0 PC

Additional info:
The same problem also appears when using python-virtinst to import a image to generate a guest
Comment 2 RHEL Product and Program Management 2010-05-14 03:31:15 EDT
This feature request did not get resolved in time for Feature Freeze
for the current Red Hat Enterprise Linux release and has now been
denied. You may re-open your request by requesting your support
representative to propose it for the next release.
Comment 3 Daniel Berrange 2010-05-14 05:53:36 EDT
Exposing it in virt-install is reasonable, but I think we should be wary of exposing machine type in the UI for virt-manager since I think it will seriously confuse users. With machine types like 'rhel-5.4.0', people will very likely think they should be making this match the OS version of their guest, when in fact this is refering to the host ABI & nothing todo with guest OS.
Comment 5 Cole Robinson 2010-06-22 10:36:46 EDT
Not sure why this is marked as 6.0, it's not hugely important IMO. Moving to 6.1
Comment 7 Cole Robinson 2010-12-07 10:00:59 EST
--machine options added for virt-install:

http://hg.fedorahosted.org/hg/python-virtinst/rev/6d0e9e6adda1

Maybe for virt-manager we can only expose the machine type if using a non-intel arch.
Comment 8 Cole Robinson 2011-01-14 17:08:46 EST
Fix built in python-virtinst-0.500.5-1.el6
Comment 10 koka xiong 2011-01-18 22:35:49 EST
Verified with python-virtinst-0.500.5-1.el6
1.Run virt-install --help
 Virtualization Platform Options:
    --machine=MACHINE   The machine type to emulate
2.Run  virt-install -n rhel55-i386 -r 2048 -l http://download.englab.nay.redhat.com/pub/rhel/released/RHEL-5-Server/U5/i386/os/ --disk path=/var/lib/libvirt/images/rhel55-i386.img,size=6 --machine=rhel5.5.0
3.virsh dump-xml rhel55-i386
<os>
    <type arch='x86_64' machine='rhel5.5.0'>hvm</type>
    <boot dev='hd'/>
  </os>

Verification is passed
Comment 11 zhe peng 2011-04-15 05:58:33 EDT
verified this bug with:
Linux localhost.localdomain 2.6.32-130.el6.x86_64 #1 SMP Tue Apr 5 19:58:31 EDT
2011 x86_64 x86_64 x86_64 GNU/Linux

python-virtinst-0.500.5-3.el6.noarch
libvirt-0.8.7-17.el6.x86_64

passed.
Comment 13 Michael Hideo 2011-05-16 00:28:35 EDT
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
* virt-install now includes the --machine option. This is useful for manually choosing the guest machine type to emulate. (BZ#592172)
Comment 14 Michael Hideo 2011-05-16 17:45:48 EDT
    Technical note updated. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    Diffed Contents:
@@ -1 +1 @@
-* virt-install now includes the --machine option. This is useful for manually choosing the guest machine type to emulate. (BZ#592172)+virt-install now includes the --machine option. This is useful for manually choosing the guest machine type to emulate.
Comment 15 errata-xmlrpc 2011-05-19 09:45:17 EDT
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-0636.html

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