Michael, Thanks for your prompt reply, you were spot on. I set the selinux policy to "permissive" in "system-config-security" and now all proceeds as expected. No reboot required. I can now install xen guests using koan. One problem I have now is that the install fails if I include the "xconfig" in the kickstart file as the xen instance doesn't have a graphical display. Does koan call virt-install to do the actual install? If it does then it is just a matter of including the "--vnc" switch in the command line. What do you suggest? TIA and FYI I am really excited about the potential of using cobbler to provision our real and virtual servers. I am also trying to work in puppet for centralised configuration. This could be the answer to all my (and my employers) prayers. Exciting times indeed thanks to you and all the other OSS workers out there Cheers Dan -----Original Message----- From: et-mgmt-tools-bounces@xxxxxxxxxx [mailto:et-mgmt-tools-bounces@xxxxxxxxxx] On Behalf Of Michael DeHaan Sent: 31 May 2007 3:47 PM To: Fedora/Linux Management Tools Subject: Re: [et-mgmt-tools] koan --virt error hennesd wrote: > Hey guys, > > I am trying to use "koan" to provision a xen guest instance but it is > failing and I can't work out why. > > I have imported my distros, created my profiles and that side of > things all seems to be fine. > > I have cobbler installed on a RHEL4 system and I am trying to create > the guest instance on a CentOS5.0 system. I can create a guest > instance using "virt-install" using the same config that koan uses and > it all works fine. > > The output from koan follows: > > [root@gbw607su1041 ~]# koan -s 221.206.29.50 -x -p CentOS5.0-xen-i386 > -V testy2 > - {'kickstart': > 'http://221.206.29.50/cblr/kickstarts/CentOS5.0-xen-i386/ks.cfg', > 'name': 'CentOS5.0-xen-i386', 'virt_ram': 256, 'repos': [], > 'kernel_options': 'ksdevice=eth0 lang=uk syslog=221.206.29.50:25150 > text ', 'ks_meta': '', 'virt_file_size': 1, 'virt_paravirt': 'True', > 'distro': 'CentOS5.0-xen-i386'} > - fetching configuration for distro: CentOS5.0-xen-i386 > - {'kernel': > '/var/www/cobbler/ks_mirror/CentOS5.0/images/xen/vmlinuz', > 'ks_meta': 'tree=http://221.206.29.50/cblr/links/CentOS5.0-xen-i386 ', > 'breed': 'redhat', 'source_repos': > [['http://221.206.29.50/cobbler/ks_mirror/config/CentOS5.0-xen-i386-0.re po', 'http://221.206.29.50/cobbler/ks_mirror/CentOS5.0'], ['http://221.206.29.50/cobbler/ks_mirror/config/CentOS5.0-xen-i386-1.rep o', 'http://221.206.29.50/cobbler/ks_mirror/CentOS5.0']], 'kernel_options': 'ksdevice=eth0 lang=uk syslog=221.206.29.50:25150 text ', 'initrd': '/var/www/cobbler/ks_mirror/CentOS5.0/images/xen/initrd.img', 'arch': 'x86', 'name': 'CentOS5.0-xen-i386'} > - downloading initrd initrd.img to /tmp/initrd.img > - url=http://221.206.29.50/cobbler/images/CentOS5.0-xen-i386/initrd.img > - downloading kernel vmlinuz to /tmp/vmlinuz > - url=http://221.206.29.50/cobbler/images/CentOS5.0-xen-i386/vmlinuz > - kernel saved = /tmp/vmlinuz > - initrd saved = /tmp/initrd.img > libvir: Xen Daemon error : POST operation failed: (xend.err 'Error > creating domain: Kernel image does not exist: /tmp/vmlinuz') > Failed to create domain testy2 > Traceback (most recent call last): > File "/usr/lib/python2.4/site-packages/koan/app.py", line 108, in main > k.run() > File "/usr/lib/python2.4/site-packages/koan/app.py", line 174, in run > self.do_virt() > File "/usr/lib/python2.4/site-packages/koan/app.py", line 306, in > do_virt > return self.do_net_install("/tmp",after_download) > File "/usr/lib/python2.4/site-packages/koan/app.py", line 275, in > do_net_install > after_download(self, distro_data, profile_data) > File "/usr/lib/python2.4/site-packages/koan/app.py", line 305, in > after_download > self.do_virt_net_install(profile_data, distro_data) > File "/usr/lib/python2.4/site-packages/koan/app.py", line 629, in > do_virt_net_install > nameoverride=self.virtname > File "/usr/lib/python2.4/site-packages/koan/virtcreate.py", line 106, > in start_paravirt_install > guest.start_install() > File "/usr/lib/python2.4/site-packages/virtinst/ParaVirtGuest.py", > line 220, in start_install > return XenGuest.XenGuest.start_install(self, consolecb) > File "/usr/lib/python2.4/site-packages/virtinst/XenGuest.py", line > 367, in start_install > self.domain = self.conn.createLinux(cxml, 0) > File "/usr/lib/python2.4/site-packages/libvirt.py", line 251, in > createLinux > if ret is None:raise libvirtError('virDomainCreateLinux() failed') > libvirtError: virDomainCreateLinux() failed > > > As you may see, it says that "/tmp/vmlinuz" doesn't exist but I can > confirm that it does by inserting an "os.listdir( '/tmp' )" into the > code. > > Any clues? > > TIA > > Dan > If SELinux is enabled, that's likely it. You can temporarily disable it if you like, though I'm working on fixing that now -- was going to hit that yesterday but I got sidetracked by some other cobbler features. If that's not it, let me know. --Michael _______________________________________________ et-mgmt-tools mailing list et-mgmt-tools@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/et-mgmt-tools ************************************************************************ DISCLAIMER The information contained in this e-mail is confidential and is intended for the recipient only. If you have received it in error, please notify us immediately by reply e-mail and then delete it from your system. Please do not copy it or use it for any other purposes, or disclose the content of the e-mail to any other person or store or copy the information in any medium. The views contained in this e-mail are those of the author and not necessarily those of Admenta UK Group. Admenta UK plc is a company incorporated in England and Wales under company number 3011757 and whose registered office is at Sapphire Court, Walsgrave Triangle, Coventry CV2 2TX ************************************************************************