Bug 728425 - customize vm: kernel boot should take precedence over install method
Summary: customize vm: kernel boot should take precedence over install method
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Virtualization Tools
Classification: Community
Component: virt-manager
Version: unspecified
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Cole Robinson
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-08-05 05:31 UTC by Min Zhan
Modified: 2014-07-06 19:31 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-02 11:42:05 UTC


Attachments (Terms of Use)

Description Min Zhan 2011-08-05 05:31:54 UTC
Description of problem:
Now in virt-manager, create a new guest, select a method such as http. Then i want to customize with direct kernel boot. Found it does not take effect. 

Version-Release number of selected component (if applicable):
# uname -r
2.6.32-165.el6.x86_64
qemu-kvm-0.12.1.2-2.175.el6.x86_64
libvirt-0.9.4-1.el6.x86_64
virt-manager-0.9.0-5.el6.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Create a new guest using http method, fill with RHEL5.7 url
2. Tick Customize before install, divert to guest details page, click boot options->direct kernel boot, fill with correct kernel path,initrd path and kernel argument(using RHEL6.1 url), click apply
such as:
kernel path:/var/lib/libvirt/boot/vmlinuz
initrd path:/var/lib/libvirt/boot/initrd.img
kernel argument: method=http://download.englab.nay.redhat.com/pub/rhel/rel-eng/RHEL6.1-20110510.1/6.1/Server/x86_64/os/
3. Click Begin installation
  
Actual results:
Found guest are actually using selected http method, and install RHEL5.7 for the guest.

# virsh dumpxml guest
...
  <os>
    <type arch='x86_64' machine='rhel6.2.0'>hvm</type>
    <kernel>/var/lib/libvirt/boot/virtinst-vmlinuz.DFfiSO</kernel>
    <initrd>/var/lib/libvirt/boot/virtinst-initrd.img.Wo7rNV</initrd>
    <cmdline>method=http://download.englab.nay.redhat.com/pub/rhel/rel-eng/RHEL5.7-Server-20110629.0/5/x86_64/os/</cmdline>
    <boot dev='hd'/>
  </os>
...

# virsh edit guest
...
  <os>
    <type arch='x86_64' machine='rhel6.2.0'>hvm</type>
    <kernel>/var/lib/libvirt/boot/vmlinuz</kernel>
    <initrd>/var/lib/libvirt/boot/initrd.img</initrd>
    <cmdline>method=http://download.englab.nay.redhat.com/pub/rhel/rel-eng/RHEL6.1-20110510.1/6.1/Server/x86_64/os/</cmdline>
    <boot dev='hd'/>
  </os>
...

# cat /etc/libvirt/qemu/guest.xml
...
  <os>
    <type arch='x86_64' machine='rhel6.2.0'>hvm</type>
    <kernel>/var/lib/libvirt/boot/vmlinuz</kernel>
    <initrd>/var/lib/libvirt/boot/initrd.img</initrd>
    <cmdline>method=http://download.englab.nay.redhat.com/pub/rhel/rel-eng/RHEL6.1-20110510.1/6.1/Server/x86_64/os/</cmdline>
    <boot dev='hd'/>
  </os>


Expected results:
Although i select http method to install a new guest in the beginning, then i customize with direct kernel boot, I think customizing should have precedence over the original installation method, Which should be same as customizing disk bus as ide during installation.

Additional info:

Comment 2 Cole Robinson 2011-12-09 23:07:34 UTC
Not urgent, and given reduced capacity for virt-manager/virtinst, just moving
this to the upstream tracker.

Comment 3 Cole Robinson 2013-10-02 11:42:05 UTC
This more or less already works, you just need to do 'import install' or something. All those customizations don't invalidate the 'install' method you chose. So for example, you do a URL install. We launch the disk image install from URL, but your kernel/initrd only gets applied as the post install boot method. I think this is fine and facilitates alternate use cases as well.


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