On 27/02/16 11:23, Richard W.M. Jones wrote:> [...] >>>> md_create: feature 'mdadm' is not available in this >>>> build of libguestfs. Read 'AVAILABILITY' in the guestfs(3) man page for >>>> how to check for the availability of features. at /home/noxdafox/development/libguestfs/test-data/phony-guests/make-fedora-img.pl >>>> line 103. >> All the other packages were already installed. Most of these >> packages seem to be available to other Debian branches but not on >> Stretch. > The Debian package 'mdadm' is installed on the machine or not?$ dpkg -l | grep mdadm ii mdadm 3.4-1 amd64 tool to administer Linux MD arrays (software RAID)> > Assuming it is installed, what is the output of: > > rm -rf tmp/.guestfs-* > ./run guestfish run : supported > > ?That precise command fails with the following message: libguestfs: error: you must call guestfs_add_drive before guestfs_launch If I feed a disk image I get it to work and returns: acl yes augeas yes blkdiscard yes blkdiscardzeroes yes btrfs no extlinux no fstrim yes gdisk yes grub no hivex yes inotify yes journal yes ldm no linuxcaps yes linuxfsuuid yes linuxmodules yes linuxxattrs yes luks no lvm2 yes mdadm no mknod yes ntfs3g yes ntfsprogs yes realpath yes rsync yes scrub no selinux yes syslinux no wipefs yes xfs no xz yes zerofree no> > Rich. >
On Sat, Feb 27, 2016 at 09:55:32PM +0200, noxdafox wrote:> On 27/02/16 11:23, Richard W.M. Jones wrote: > >[...] > >>>>md_create: feature 'mdadm' is not available in this > >>>>build of libguestfs. Read 'AVAILABILITY' in the guestfs(3) man page for > >>>>how to check for the availability of features. at /home/noxdafox/development/libguestfs/test-data/phony-guests/make-fedora-img.pl > >>>>line 103. > >>All the other packages were already installed. Most of these > >>packages seem to be available to other Debian branches but not on > >>Stretch. > >The Debian package 'mdadm' is installed on the machine or not? > $ dpkg -l | grep mdadm > ii mdadm 3.4-1 amd64 tool to > administer Linux MD arrays (software RAID) > > > >Assuming it is installed, what is the output of: > > > > rm -rf tmp/.guestfs-* > > ./run guestfish run : supported > > > >? > That precise command fails with the following message: > > libguestfs: error: you must call guestfs_add_drive before guestfs_launchAh right, that's because the default backend is 'direct', but on my machine I have it set to 'libvirt', which supports hotplugging and thus doesn't require you to specify any drives.> mdadm noOK this is strange, and wrong. Can you try: ./run virt-rescue --scratch In the virt-rescue shell: ls -l {/bin,/sbin,/usr/bin,/usr/sbin}/mdadm That should show the mdadm binary copied into the appliance, but likely it does not, because the test here is failing: https://github.com/libguestfs/libguestfs/blob/master/daemon/md.c#L45 https://github.com/libguestfs/libguestfs/blob/master/daemon/guestfsd.c#L1076 It could be that mdadm is something odd, like a dead symlink? Anyway, I'll fire up a Debian box in my cloud and see if I can reproduce this also. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com libguestfs lets you edit virtual machines. Supports shell scripting, bindings from many languages. http://libguestfs.org
On 27/02/16 22:09, Richard W.M. Jones wrote:> On Sat, Feb 27, 2016 at 09:55:32PM +0200, noxdafox wrote: >> On 27/02/16 11:23, Richard W.M. Jones wrote: >>> [...] >>>>>> md_create: feature 'mdadm' is not available in this >>>>>> build of libguestfs. Read 'AVAILABILITY' in the guestfs(3) man page for >>>>>> how to check for the availability of features. at /home/noxdafox/development/libguestfs/test-data/phony-guests/make-fedora-img.pl >>>>>> line 103. >>>> All the other packages were already installed. Most of these >>>> packages seem to be available to other Debian branches but not on >>>> Stretch. >>> The Debian package 'mdadm' is installed on the machine or not? >> $ dpkg -l | grep mdadm >> ii mdadm 3.4-1 amd64 tool to >> administer Linux MD arrays (software RAID) >>> Assuming it is installed, what is the output of: >>> >>> rm -rf tmp/.guestfs-* >>> ./run guestfish run : supported >>> >>> ? >> That precise command fails with the following message: >> >> libguestfs: error: you must call guestfs_add_drive before guestfs_launch > Ah right, that's because the default backend is 'direct', but on my > machine I have it set to 'libvirt', which supports hotplugging and > thus doesn't require you to specify any drives. > >> mdadm no > OK this is strange, and wrong. > > Can you try: > > ./run virt-rescue --scratch > > In the virt-rescue shell: > > ls -l {/bin,/sbin,/usr/bin,/usr/sbin}/mdadm><rescue> ls -l {/bin,/sbin,/usr/bin,/usr/sbin}/mdadm ls: cannot access '/bin/mdadm': No such file or directory ls: cannot access '/sbin/mdadm': No such file or directory ls: cannot access '/usr/bin/mdadm': No such file or directory ls: cannot access '/usr/sbin/mdadm': No such file or directory> > That should show the mdadm binary copied into the appliance, but > likely it does not, because the test here is failing: > > https://github.com/libguestfs/libguestfs/blob/master/daemon/md.c#L45 > https://github.com/libguestfs/libguestfs/blob/master/daemon/guestfsd.c#L1076 > > It could be that mdadm is something odd, like a dead symlink?$ ls -l /sbin/mdadm -rwxr-xr-x 1 root root 542376 Feb 19 19:03 /sbin/mdadm> > Anyway, I'll fire up a Debian box in my cloud and see if I can > reproduce this also.Thanks for the time you're spending in this.> > Rich. >
> Anyway, I'll fire up a Debian box in my cloud and see if I can > reproduce this also.I was able to install stretch, starting from jessie [from `virt-builder debian-8'], changing s/jessie/stretch/ in sources.list, and upgrading in the usual way. To install gfs2-utils I had to add jessie as another apt source [see my final sources.list attached]. That package is not in stretch, I suppose because it has not been built since jessie. I completed `apt-get build-dep libguestfs' with no errors. I built libguestfs from git (ac76081f). I had to additionally install: `db-util' and `uuid-runtime'. I think both are missing dependencies from the Debian package. The test suite basically worked after that. There were a few failures (eg. grub missing, xfs-admin lacks some patches that we added upstream), but nothing significant. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com Fedora Windows cross-compiler. Compile Windows programs, test, and build Windows installers. Over 100 libraries supported. http://fedoraproject.org/wiki/MinGW