[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [fedora-virt] [RFC/PATCH] libguestfs: build Debian based appliance



Hi Rich,
On Tue, Jun 30, 2009 at 10:01:59AM +0100, Richard W.M. Jones wrote:
> On Tue, Jun 30, 2009 at 12:18:30AM +0200, Guido Günther wrote:
> > The first once sets DIST=DEBIAN or DIST=REDHAT if using debootstrap or
> > febootstrap respectively. This allows us to set distro specific package
> > lists as discussed at Fudcon.
> 
> OK, I pushed this one as is:
> 
> http://git.et.redhat.com/?p=libguestfs.git;a=commitdiff;h=b4fade6392ccb2961f0d7e2bf45dfc2e20333aed
Thanks.

> > The second one checks for udev and uses that instead of doing everything
> > by hand. This significantly speeds up booting of the appliance since
> > each MAKEDEV call tages ages here and simplifies the code since we don't
> > need any device probing.
> 
> I modified your patch slightly to add Fedora udev support.  As you
> say, it works better than doing explicit MAKEDEVs:
> 
> http://git.et.redhat.com/?p=libguestfs.git;a=commitdiff;h=284797c1561e5e089986027d469bd16ee1a983df
Even better. Thanks.

> > The third one explicitly sets the device type of attached disk to SCSI,
> > otherwise the tests end up as hda with my version of qemu. Since future
> > versions might pick virtio by default this is probaly safer anyway.
> 
> This one is a bit of trouble.  It broke Fedora support, but I think
> was just because the sym53c8xx.ko module was missing from my
> appliance.  I'm going to try with that.
Attached patch has what I came up with to support most of QEMUs hardware
as used by the appliance.

> 
> I'm slightly doubtful about what is going on here, because the tests
> are *supposed* to deal with the case where devices are named /dev/hda
> etc.  See:
> 
> http://libguestfs.org/guestfs.3.html#block_device_naming
> 
> However your patch could be an improvement if it means that devices
> are always named /dev/sd*, even on our older versions of RHEL.
The problem here is that the "blockdev /dev/sda" call fails since sda is
missing completely with udev. Without having looked at this further I
assume that libguestfs internally expects the blockdev call to succeed
since it assumes /dev/sda is there due to static device node creation.
However if we switch to if=scsi this will work anyways.
Cheers,
 -- Guido
>From d3da7ab4fefc3b3c056c2ce591fd64bbdfc48698 Mon Sep 17 00:00:00 2001
From: =?utf-8?q?Guido=20G=C3=BCnther?= <agx sigxcpu org>
Date: Tue, 30 Jun 2009 12:17:40 +0200
Subject: [PATCH] whitelist kernel modules for hardware emulated by QEMU

---
 appliance/kmod.whitelist.in |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/appliance/kmod.whitelist.in b/appliance/kmod.whitelist.in
index 4bf4cf8..04ed7d0 100644
--- a/appliance/kmod.whitelist.in
+++ b/appliance/kmod.whitelist.in
@@ -9,6 +9,19 @@ virtio.ko
 virtio_net.ko
 virtio_pci.ko
 virtio_ring.ko
+virtio_balloon.ko
+
+# drivers for QEMUs IDE/SCSI device emulation
+cdrom.ko
+i2c-piix4.ko
+i2c-core.ko
+ide-*.ko
+libata.ko
+piix.ko
+scsi_transport_spi.ko
+scsi_mod.ko
+sd_mod.ko
+sym53c8xx.ko
 
 ext2.ko
 ext3.ko
-- 
1.6.3.1


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]