Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1029493 - Provisioning of RHEL7 virt guest on RHEL7 host fails
Summary: Provisioning of RHEL7 virt guest on RHEL7 host fails
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Provisioning
Version: 560
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Stephen Herr
QA Contact: Red Hat Satellite QA List
Depends On: 1038821
Blocks: sat560-triage 1042363
TreeView+ depends on / blocked
Reported: 2013-11-12 13:32 UTC by Jiří Mikulka
Modified: 2014-10-06 13:46 UTC (History)
3 users (show)

Fixed In Version: koan-2.0.7-41 spacewalk-koan-2.0.1-3
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1042363 (view as bug list)
Last Closed: 2014-01-10 20:25:23 UTC
Target Upstream Version:

Attachments (Terms of Use)

Description Jiří Mikulka 2013-11-12 13:32:17 UTC
Description of problem:
Provisioning of RHEL7 virtual (KVM) guest on RHEL7 host fails with traceback because of missing python modules.

Version-Release number of selected component (if applicable):
Satellite: Satellite 5.6
host: RHEL-7.0-20131111.1 Server x86_64

How reproducible:

Steps to Reproduce:
1. sync RHEL7 channel to Satellite
2. register RHEL7 to the Satellite, add Virtualization entitlement
3. create RHEL7 virtual kickstart
4. schedule provisioning of RHEL7 virtual guest on registered RHEL7 host
5. on RHEL7 host run `rhn_check -vvv`
6. check the output

Actual results:
D: handle_action actionid = 41, version = 2
D: do_call kickstart_guest.initiate('<RHEL7 host>', '<satellite>:1:<virt-guest>', 'qemu', 10, '<virt-guest>', 512, 1, 3, 'virbr0', '/var/lib/libvirt/images/<virt-guest>', ' '){'cache_only': None}
- looking for Cobbler at http://<RHEL7 host>/cobbler_api
- reading URL: http://ib<RHEL7 host>/cblr/svc/op/ks/system/<satellite>:1:<virt-guest>
install_tree: http://<RHEL7 host>/ty/MbMww5qC
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/koan/", line 1185, in load_virt_modules
    import xencreate
  File "/usr/lib/python2.7/site-packages/koan/", line 35, in <module>
    import virtinst
ImportError: No module named virtinst
no virtualization support available, install python-virtinst?
D: Sending back response(1, 'Virtual kickstart failed. Koan error.', {'koan': 'no virtualization support available, install python-virtinst?'})
D: do_call packages.checkNeedUpdate('rhnsd=1',){}

Expected results:
RHEL7 KVM virtual guest is provisioned properly

Additional info:
looking into RHEL7 tree, there's no python-virtinst package (in RHEL7 base channel), while in RHEL5/6 the package is included in base channel

Comment 1 Stephen Herr 2013-11-21 14:45:46 UTC
In RHEL 7 the python-virtinst packages has been merged into the virt-install rpm (built by the virt-manager package). We will have to update koan to look in the right place for it.

Comment 2 Stephen Herr 2013-11-21 20:56:53 UTC
In RHEL 5 and 6 we depend on a package that has been in the base RHEL repo named python-virtinst. Python-virtinst is what koan calls out to to actually do the virtual machine creation if you are installing a virt guest on a host. It has to be updated to maintain compatibility with qemu and xen and whatever else. Python-virtinst provides both a python module (that koan calls) and a command-line tool that uses it.

In RHEL 7 they are no longer going to be providing python-virtinst, but have moved to the virt-install rpm. More importantly than the name change, they are no longer providing access to the python module. Upstream koan has tried to adapt by shelling out and issuing command-line commands, but at the expense of basicly rewriting about half of how koan works. They have also done so really badly; there's no way that upstream koan will function on RHEL 7 as it currently stands. It's still littered with references to the now-unavailable virtinst module.

In order to get koan fully working on RHEL 7 we will have to fix a bunch of stuff upstream, and then update our koan to work the same way. This will not be just a small bug fix though, closer to a 50% rewrite of koan, so we will need to test it thoroughly.

Comment 3 Stephen Herr 2013-11-22 23:43:38 UTC
I have updated koan so that it can work on RHEL 7. It was still not working on my RHEL 7 host, but I think that was because libvirtd was broken, not our packages (error message about not finding a qemu://system driver).

Please see if you can make it work, and once libvirtd is fixed test koan a lot, especially in the area of having koan install vitual guests. That entire section of koan has been re-written. The updated koan packages should function on RHEL 5 and 6 too, not just RHEL 7, so be sure to test them there as well.

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