With 1.9.37 the following script worked fine, with 1.9.39 it fails. Any idea what the issue is? Olaf ... mount -o /dev/vda1 /sysroot/ [ 1.396411] EXT4-fs (vda1): mounting ext2 file system using the ext4 subsystem [ 1.533090] EXT4-fs (vda1): mounted filesystem without journal. Opts: (null) guestfsd: main_loop: proc 1 (mount) took 0.45 seconds libguestfs: recv_from_daemon: 40 bytes: 20 00 f5 f5 | 00 00 00 04 | 00 00 00 01 | 00 00 00 01 | 00 12 34 08 | ... Fill free space in /dev/vda1 with zero ... libguestfs: send_to_daemon: 52 bytes: 00 00 00 30 | 20 00 f5 f5 | 00 00 00 04 | 00 00 01 37 | 00 00 00 00 | ... guestfsd: main_loop: new request, len 0x30 random filename: /sysroot//ubhvwzh2.xu8 fsync /dev/vda guestfsd: main_loop: proc 311 (zero_free_space) took 1.46 seconds libguestfs: recv_from_daemon: 40 bytes: 20 00 f5 f5 | 00 00 00 04 | 00 00 01 37 | 00 00 00 01 | 00 12 34 09 | ... libguestfs: send_to_daemon: 44 bytes: 00 00 00 28 | 20 00 f5 f5 | 00 00 00 04 | 00 00 00 2f | 00 00 00 00 | ... guestfsd: main_loop: new request, len 0x28 umount /sysroot guestfsd: main_loop: proc 47 (umount_all) took 0.01 seconds libguestfs: recv_from_daemon: 40 bytes: 20 00 f5 f5 | 00 00 00 04 | 00 00 00 2f | 00 00 00 01 | 00 12 34 0a | ... libguestfs: send_to_daemon: 44 bytes: 00 00 00 28 | 20 00 f5 f5 | 00 00 00 04 | 00 00 00 0a | 00 00 00 00 | ... guestfsd: main_loop: new request, len 0x28 lvm vgs -o vg_name --noheadings No volume groups found guestfsd: main_loop: proc 10 (vgs) took 0.01 seconds libguestfs: recv_from_daemon: 44 bytes: 20 00 f5 f5 | 00 00 00 04 | 00 00 00 0a | 00 00 00 01 | 00 12 34 0b | ... libguestfs: send_to_daemon: 44 bytes: 00 00 00 28 | 20 00 f5 f5 | 00 00 00 04 | 00 00 01 1a | 00 00 00 00 | ... guestfsd: main_loop: new request, len 0x28 fsync /dev/vda guestfsd: main_loop: proc 282 (internal_autosync) took 0.02 seconds libguestfs: recv_from_daemon: 40 bytes: 20 00 f5 f5 | 00 00 00 04 | 00 00 01 1a | 00 00 00 01 | 00 12 34 0c | ... libguestfs: sending SIGTERM to process 26256 libguestfs: closing guestfs handle 0x1e66470 (state 0) Fatal error: exception Guestfs.Handle_closed("disk_format") ... #!/bin/bash set -x img=disk.img sprs=disk.sparse.img kname=vda test -f ${img} && exit 1 test -f ${sprs} && exit 1 find /usr/share/ -type f -print0 | xargs -0 cat | dd bs=$(( 1024 * 1024 )) count=$(( 42 )) iflag=fullblock of=${img} ls -lhsS ${img} time guestfish -v <<_EOF_ add ${img} run part-disk /dev/${kname} mbr blockdev-rereadpt /dev/${kname} mkfs ext2 /dev/${kname}1 blockdev-rereadpt /dev/${kname} mount /dev/${kname}1 / mkdir /y ls / ls /y umount / sync _EOF_ time virt-sparsify -v ${img} ${sprs} ls -lhsS ${img} ${sprs}