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

[Libguestfs] Notes on compiling libguestfs 1.19.59 on Debian 7 (Wheezy) beta



In no particular order.  Some of these need further investigation.

----------------------------------------------------------------------

I had to patch libguestfs not to use febootstrap-supermin-helper
--copy-kernel option.  See attachment #1.  This could be avoided by
providing a newer febootstrap in Wheezy.

I had to patch libguestfs to make it not use the (not working)
virtio-scsi in old kvm.  See attachment #2.

mdadm is missing as a dependency from the Debian package.

test_mke2fs_0 fails: this seems to be a bug in libguestfs block
device renaming code:

  libguestfs: trace: mke2fs "/dev/sda2" "blocksize:4096" "journaldevice:/dev/sda1" "fstype:ext2"
  libguestfs: send_to_daemon: 276 bytes: 00 00 01 10 | 20 00 f5 f5 | 00 00 00 04 | 00 00 01 70 | 00 00 00 00 | ...
  guestfsd: main_loop: proc 368 (mke2fs) took 4.52 seconds
  guestfsd: main_loop: new request, len 0x110
  /dev/sda2: No such file or directory
  mke2fs -b 4096 -J device=/dev/sda1 -t ext2 /dev/vda2
  mke2fs 1.42.5 (29-Jul-2012)

test_tune2fs* fail because the output (username) expected by the
test script is different from what the test expects.  This is not
important and this test should just be skipped.

For some reason, the behaviour of vfat with the utf8 option is
different from the same driver in the Fedora kernel.  The Debian
kernel prints this warning:

  [   65.576097] FAT-fs (vda1): utf8 is not a recommended IO charset for FAT filesystems, filesystem will be case sensitive!

and indeed the resulting filesystem is case sensitive, which is
definitely not expected or correct for vfat.  It's probably some
kernel config option.

The udev rule (appliance/99-guestfs-serial.rules) either isn't being
installed or doesn't work for some reason.  I didn't look into it, but
this breaks /dev/disk/guestfs/<label> disk names (see 7786d56db8c2241).

tests/regressions/rhbz690819.sh fails, because either the kernel or
qemu doesn't support the IDE interface.  This will break virt-v2v.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 80 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora
>From 5a2a450b0b54e3d004f558c353594a3452cf0403 Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones redhat com>
Date: Tue, 13 Nov 2012 18:33:33 +0000
Subject: [PATCH 1/2] DEBIAN 7: REVERT 3ed3e23ed (NO FEBOOTSTRAP COPY-KERNEL
 OPTION).

---
 src/appliance.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/appliance.c b/src/appliance.c
index 8a22064..aa2a5b5 100644
--- a/src/appliance.c
+++ b/src/appliance.c
@@ -102,7 +102,7 @@ gl_lock_define_initialized (static, building_lock);
  * $TMPDIR/.guestfs-$UID/ and consists of four files:
  *
  *   $TMPDIR/.guestfs-$UID/checksum       - the checksum
- *   $TMPDIR/.guestfs-$UID/kernel         - the kernel
+ *   $TMPDIR/.guestfs-$UID/kernel         - symlink to the kernel
  *   $TMPDIR/.guestfs-$UID/initrd         - the febootstrap initrd
  *   $TMPDIR/.guestfs-$UID/root           - the appliance
  *
@@ -645,7 +645,7 @@ hard_link_to_cached_appliance (guestfs_h *g,
     perrorf (g, "link: %s %s", filename, *kernel);
     goto error;
   }
-  (void) utimes (filename, NULL);
+  (void) lutimes (filename, NULL); /* lutimes because it's a symlink */
 
   snprintf (filename, len, "%s/initrd", cachedir);
   (void) unlink (*initrd);
@@ -697,7 +697,6 @@ run_supermin_helper (guestfs_h *g, const char *supermin_path,
     guestfs___cmd_add_arg (cmd, "-g");
     guestfs___cmd_add_arg_format (cmd, "%d", egid);
   }
-  guestfs___cmd_add_arg (cmd, "--copy-kernel");
   guestfs___cmd_add_arg (cmd, "-f");
   guestfs___cmd_add_arg (cmd, "ext2");
   guestfs___cmd_add_arg_format (cmd, "%s/supermin.d", supermin_path);
-- 
1.7.10.4

>From 1556cc9e8056a0e72c6ad945e45804c30e06da0b Mon Sep 17 00:00:00 2001
From: "Richard W.M. Jones" <rjones redhat com>
Date: Tue, 13 Nov 2012 18:45:59 +0000
Subject: [PATCH 2/2] DEBIAN 7: FORCE VIRTIO-BLK, DISABLE VIRTIO-SCSI.

Ancient KVM on Debian 7 means virtio-scsi isn't working.
---
 src/launch-appliance.c |    7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/src/launch-appliance.c b/src/launch-appliance.c
index 17e90d9..6cc9e97 100644
--- a/src/launch-appliance.c
+++ b/src/launch-appliance.c
@@ -39,7 +39,9 @@
 static int is_openable (guestfs_h *g, const char *path, int flags);
 static void print_qemu_command_line (guestfs_h *g, char **argv);
 static int qemu_supports (guestfs_h *g, const char *option);
+#if 0
 static int qemu_supports_device (guestfs_h *g, const char *device_name);
+#endif
 static int qemu_supports_virtio_scsi (guestfs_h *g);
 static char *qemu_drive_param (guestfs_h *g, const struct drive *drv, size_t index);
 
@@ -826,6 +828,7 @@ qemu_supports (guestfs_h *g, const char *option)
   return strstr (g->app.qemu_help, option) != NULL;
 }
 
+#if 0
 /* Test if device is supported by qemu (currently just greps the -device ?
  * output).
  */
@@ -839,6 +842,7 @@ qemu_supports_device (guestfs_h *g, const char *device_name)
 
   return strstr (g->app.qemu_devices, device_name) != NULL;
 }
+#endif
 
 /* Check if a file can be opened. */
 static int
@@ -857,6 +861,7 @@ is_openable (guestfs_h *g, const char *path, int flags)
 static int
 qemu_supports_virtio_scsi (guestfs_h *g)
 {
+#if 0
   int r;
 
   /* g->app.virtio_scsi has these values:
@@ -876,6 +881,8 @@ qemu_supports_virtio_scsi (guestfs_h *g)
   }
 
   return g->app.virtio_scsi == 1;
+#endif
+  return 0;
 }
 
 static char *
-- 
1.7.10.4


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