Looking at the postinst script, it calls update-initramfs -u and expects it to do somethin, i.e. create the initramfs.
However, it can choose to not do so, and deffer the update. And thus not create an initramfs. However, when we are upgrading to a new kernel image, we expect to generate an initramfs cause we will be fixing symlinks and so on right after. I have linux-image-4.3.0-6.17 installed, via linux-virtual metapackage on an old cloud image (see my private fileshare). And upgrading that to xenial/release 4.3.0-7.18 fails like so: ubuntu@ubuntu:~$ dpkg -l | grep linux ii console-setup-linux 1.108ubuntu10 all Linux specific part of console-setup ii libselinux1:s390x 2.4-3 s390x SELinux runtime shared libraries ii linux-headers-4.3.0-6 4.3.0-6.17 all Header files related to Linux kernel version 4.3.0 ii linux-headers-4.3.0-6-generic 4.3.0-6.17 s390x Linux kernel headers for version 4.3.0 on System 390x SMP ii linux-headers-generic 4.3.0.6.7 s390x Generic Linux kernel headers ii linux-headers-virtual 4.3.0.6.7 s390x Transitional package. ii linux-image-4.3.0-6-generic 4.3.0-6.17 s390x Linux kernel image for version 4.3.0 on System 390x SMP ii linux-image-virtual 4.3.0.6.7 s390x This package will always depend on the latest minimal generic kernel image. ii linux-virtual 4.3.0.6.7 s390x Minimal Generic Linux kernel and headers ii util-linux 2.27.1-1ubuntu3 s390x Miscellaneous system utilities ubuntu@ubuntu:~$ # upgrading to release (to 4.3.0-7.18) ... Setting up linux-image-4.3.0-7-generic (4.3.0-7.18) ... Progress: [ 76%] [#############################################.............] update-initramfs: deferring update (hook will be called later) cp: cannot stat ‘/boot/initrd.img-4.3.0-7-generic’: No such file or directory Failed to copy /boot/initrd.img-4.3.0-7-generic to /boot/initrd.img at /var/lib/dpkg/info/linux-imageProgress: [ 77%] [#############################################.............] dpkg: error processing package linux-image-4.3.0-7-generic (--configure): subprocess installed post-installation script returned error exit status 1 ... dpkg: dependency problems prevent configuration of linux-image-virtual: linux-image-virtual depends on linux-image-4.3.0-7-generic; however: Package linux-image-4.3.0-7-generic is not configured yet. dpkg: error processing package linux-image-virtual (--configure): dependency problems - leaving unconfigured Setting up linux-headers-generic (4.3.0.7.8) ...No apport report written because the error message indicates its a followup error from a previous failure. Setting up linux-headers-virtual (4.3.0.7.8) ... dpkg: dependency problems prevent configuration of linux-virtual: linux-virtual depends on linux-image-virtual (= 4.3.0.7.8); however: Package linux-image-virtual is not configured yet. dpkg: error processing package linux-virtual (--configure): dependency problems - leaving unconfigured Setting up lxcfs (0.17-0ubuntu2) ...No apport report written because the error message indicates its a followup error from a previous failure. ... My solution to the problem is to force update-initramfs to create an initrd when the linux-image upgrade scripts expect to have that to happen. See the attached patch. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1536810 Title: kernel install failed /bin/cp: cannot stat ‘/boot/initrd.img-4.3.0-7-generic’: No such file or directory To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1536810/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs