Bug 1379942 - supermin: unable to build appliance on Debian/Ubuntu with merged/moved /usr
Summary: supermin: unable to build appliance on Debian/Ubuntu with merged/moved /usr
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libguestfs
Version: unspecified
Hardware: Unspecified
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Richard W.M. Jones
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-09-28 08:09 UTC by Vincent Bernat
Modified: 2016-10-04 16:13 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-10-04 16:13:02 UTC
Embargoed:


Attachments (Terms of Use)

Description Vincent Bernat 2016-09-28 08:09:34 UTC
Description of problem:

On my system, /bin and /sbin are symlinks to /usr/bin and /usr/sbin. This is done by installing the usrmerge package. I suppose this is the same mechanism in Fedora after UsrMove.

So, I have:

lrwxrwxrwx 1 root root 7 sept. 27 15:07 /bin -> usr/bin
lrwxrwxrwx 1 root root 8 sept. 27 15:07 /sbin -> usr/sbin

It seems that supermin isn't able to work with such a layout.

Version-Release number of selected component (if applicable):

supermin 5.1.16-1 (from Debian Unstable)

How reproducible:

Always

Steps to Reproduce:
1. Install usrmerge package and guestfish package.
2. Run libguestfs-test-tool

Actual results:

     ************************************************************
     *                    IMPORTANT NOTICE
     *
     * When reporting bugs, include the COMPLETE, UNEDITED
     * output below in your bug report.
     *
     ************************************************************
PATH=/usr/lib/ccache:/home/bernat/bin:/sbin:/usr/local/sbin:/usr/sbin:/bin:/usr/local/bin:/usr/bin:/usr/local/games:/usr/games
SELinux: sh: 1: getenforce: not found
guestfs_get_append: (null)
guestfs_get_autosync: 1
guestfs_get_backend: direct
guestfs_get_backend_settings: []
guestfs_get_cachedir: /var/tmp
guestfs_get_direct: 0
guestfs_get_hv: /usr/bin/qemu-system-x86_64
guestfs_get_memsize: 500
guestfs_get_network: 0
guestfs_get_path: /usr/lib/x86_64-linux-gnu/guestfs
guestfs_get_pgroup: 0
guestfs_get_program: libguestfs-test-tool
guestfs_get_recovery_proc: 1
guestfs_get_selinux: 0
guestfs_get_smp: 1
guestfs_get_tmpdir: /tmp
guestfs_get_trace: 0
guestfs_get_verbose: 1
host_cpu: x86_64
Launching appliance, timeout set to 600 seconds.
libguestfs: launch: program=libguestfs-test-tool
libguestfs: launch: version=1.32.7
libguestfs: launch: backend registered: unix
libguestfs: launch: backend registered: uml
libguestfs: launch: backend registered: libvirt
libguestfs: launch: backend registered: direct
libguestfs: launch: backend=direct
libguestfs: launch: tmpdir=/tmp/libguestfs5x97fR
libguestfs: launch: umask=0022
libguestfs: launch: euid=1000
libguestfs: [00001ms] begin building supermin appliance
libguestfs: [00001ms] run supermin
libguestfs: command: run: /usr/bin/supermin
libguestfs: command: run: \ --build
libguestfs: command: run: \ --verbose
libguestfs: command: run: \ --if-newer
libguestfs: command: run: \ --lock /var/tmp/.guestfs-1000/lock
libguestfs: command: run: \ --copy-kernel
libguestfs: command: run: \ -f ext2
libguestfs: command: run: \ --host-cpu x86_64
libguestfs: command: run: \ /usr/lib/x86_64-linux-gnu/guestfs/supermin.d
libguestfs: command: run: \ -o /var/tmp/.guestfs-1000/appliance.d
supermin: version: 5.1.16
supermin: package handler: debian/dpkg
supermin: acquiring lock on /var/tmp/.guestfs-1000/lock
supermin: build: /usr/lib/x86_64-linux-gnu/guestfs/supermin.d
supermin: reading the supermin appliance
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/base.tar.gz type gzip base image (tar)
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/daemon.tar.gz type gzip base image (tar)
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/excludefiles type uncompressed excludefiles
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/hostfiles type uncompressed hostfiles
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/init.tar.gz type gzip base image (tar)
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/packages type uncompressed packages
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/packages-hfsplus type uncompressed packages
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/packages-reiserfs type uncompressed packages
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/packages-xfs type uncompressed packages
supermin: build: visiting /usr/lib/x86_64-linux-gnu/guestfs/supermin.d/udev-rules.tar.gz type gzip base image (tar)
supermin: mapping package names to installed packages
supermin: resolving full list of package dependencies
supermin: build: 170 packages, including dependencies
supermin: build: 7507 files
supermin: build: 3657 files, after matching excludefiles
supermin: build: 3667 files, after adding hostfiles
supermin: build: 3667 files, after removing unreadable files
supermin: build: 3673 files, after munging
supermin: kernel: picked kernel vmlinuz-4.7.0-1-amd64
supermin: kernel: picked modules path /lib/modules/4.7.0-1-amd64
supermin: kernel: kernel_version 4.7.0-1-amd64
supermin: kernel: modules /lib/modules/4.7.0-1-amd64
supermin: ext2: creating empty ext2 filesystem '/var/tmp/.guestfs-1000/appliance.d.eap18xmn/root'
supermin: ext2: populating from base image
supermin: *** parent directory not found ***
supermin: When reporting this error:
supermin: please include ALL the debugging information below
supermin: AND tell us what system you are running this on.
     src=/tmp/superminb4dc82.tmpdir/base.d/sbin/guestfsd
    dest=/sbin/guestfsd
 dirname=/usr/sbin
basename=guestfsd
supermin: ext2fs_namei: parent directory not found: /usr/sbin: File not found by ext2_lookup
supermin: failure: ext2fs_namei: parent directory not found
libguestfs: error: /usr/bin/supermin exited with error status 1, see debug messages above
libguestfs-test-tool: failed to launch appliance
libguestfs: closing guestfs handle 0xec69f0 (state 0)
libguestfs: command: run: rm
libguestfs: command: run: \ -rf /tmp/libguestfs5x97fR


Expected results:

Supermin appliance should be built.

Comment 1 Vincent Bernat 2016-09-28 13:24:19 UTC
This is fixed with this patch: https://www.redhat.com/archives/libguestfs/2016-September/msg00189.html

Comment 2 Pino Toscano 2016-10-04 16:13:02 UTC
This was fixed with
https://github.com/libguestfs/libguestfs/commit/a31f657db02bb570a645eb33938c09196ff93553
which is in libguestfs >= 1.35.7.


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