#946385 live-build: "lb build" fails to install linux-image-4.19.0-6-amd64

#946385#5
Date:
2019-12-08 11:11:49 UTC
From:
To:
Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?
I am trying to create a live usb stick. This is the first time I am using live-build.
I am running in a Debian 10 amd64 virtual machine on an x86-64 OpenSUSE Leap 15.1 host.
   * What exactly did you do (or not do) that was effective (or
     ineffective)?
I created a config with 'sudo lb config --distribution buster', then added a list of the packages I wanted.
A tarball of my config directory is here http://tjcw.freeshell.org/live-build-bug/config.tar.z .
Then I ran 'sudo lb build 2>&1|tee build.log' . The build log is here
http://tjcw.freeshell.org/live-build-bug/build.log
   * What was the outcome of this action?
I got a failure during package installation. Here is a section from the build log.
/etc/kernel/postinst.d/initramfs-tools:
update-initramfs: Generating /boot/initrd.img-4.19.0-6-amd64
live-boot: core filesystems devices utils udev blockdev dns.
/etc/kernel/postinst.d/zz-update-grub:
Searching for GRUB installation directory ...
No GRUB directory found.
 To create a template run 'mkdir /boot/grub' first.
 To install grub, install it manually or try the 'grub-install' command.
 ### Warning, grub-install is used to change your MBR. ###

run-parts: /etc/kernel/postinst.d/zz-update-grub exited with return code 1
dpkg: error processing package linux-image-4.19.0-6-amd64 (--configure):
 installed linux-image-4.19.0-6-amd64 package post-installation script subprocess returned error exit status 1

After the failure, I confirmed that there was no chroot/boot/grub directory.
I think the problem is with the sequence in which live-build installs the packages; maybe dependencies are
set incorrectly between grub and linux-image.
   * What outcome did you expect instead?
I expected an 'iso' file to be built.

*** End of the template - remove these template lines ***

#946385#10
Date:
2019-12-08 14:44:04 UTC
From:
To:
On the theory that I don't need 'lilo', and the 2 'grub' packages aren't
in the 'tutorial1' example, I removed these from desktop.list.chroot and
tried again. 'lb build' got further, but still didn't result in an iso;
the build log from this run is here
http://tjcw.freeshell.org/live-build-bug/build.2.log . It looks like 'lb
build' stopped part way through, but I cannot see the reason. Is the message
umount: /home/tjcw/lb/freeduc/chroot/dev/pts: target is busy.
significant ?
I unmounted this and reissued the 'lb build' command. Again it got
further; build log here
http://tjcw.freeshell.org/live-build-bug/build.3.log ; but no iso. And
indeed there was nothing in chroot/boot . Is one or more of the packages
in desktop.list.chroot preventing the 'lb build' from working ?
For the next attempt I have removed
linux-base
linux-image-4.19.0-6-amd64
linux-image-amd64
from the desktop.list.chroot and issued 'lb clean;lb build'. This is
currently running.

#946385#15
Date:
2019-12-08 16:22:40 UTC
From:
To:
That 'lb build' again finished early with no iso, but unmounting the pts
and reissuing the 'lb build' resulted in an iso. So now I have my live
system, but there is still some problem with live-build which prevents a
clean run first time for me.