Missing /bin/sh (dash) in supermin appliance

Bug #1777058 reported by Ciro Santilli 六四事件 法轮功 on 2018-06-15
This bug affects 3 people
Affects Status Importance Assigned to Milestone
libguestfs (Ubuntu)

Bug Description

Bionic beaver 18.04 libguetfs-tools 1:1.36.13-1ubuntu3:

    sudo apt-get install libguestfs-tools
    mkdir sysroot
    # Just a test file.
    dd if=/dev/urandom of=sysroot/myfile bs=1024 count=1024
    sudo virt-make-fs --format=qcow2 --type=ext2 sysroot sysroot.ext2.qcow2

fails with:

    libguestfs: error: tar_in: write error on directory: /:

Without sudo:

    virt-make-fs --format=qcow2 --type=ext2 sysroot sysroot.ext2.qcow2

fails with:

    libguestfs: error: /usr/bin/supermin exited with error status 1.
    To see full error messages you may need to enable debugging.
    and run the command again. For further information, read:
    You can also run 'libguestfs-test-tool' and post the *complete* output
    into a bug report or message to the libguestfs mailing list.

but I think it is an unrelated problem.

Original command with debug vars:

    sudo LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1 virt-make-fs --format=qcow2 --size=+200M sysroot/ output.img

attached as a file.

Matteo Panella (mpanella) wrote :

As stated in the upstream report, the bug is really caused by /bin/sh missing in the supermin appliance. This was fixed upstream in https://github.com/libguestfs/libguestfs/commit/0cca7f9061455d29a7f893e715028cd3e75c19fd and downstream in Debian in https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=889861

The patch applies with minimal fuzz to the version shipped in 18.04, without the aforementioned fix any libguestfs command which require interaction with a binary inside the supermin appliance fails (find, tar-*, even debug commands).

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in libguestfs (Ubuntu):
status: New → Confirmed
summary: - virt-make-fs fails with: "libguestfs: error: tar_in: write error on
- directory: /:"
+ Missing /bin/sh (dash) in supermin appliance
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.