← Back to team overview

touch-packages team mailing list archive

[Bug 1516705] Re: update-initramfs fails during debian-installer if running kernel doesn't match installed kernel

 

** Changed in: initramfs-tools (Ubuntu)
     Assignee: (unassigned) => Adam Conrad (adconrad)

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to initramfs-tools in Ubuntu.
https://bugs.launchpad.net/bugs/1516705

Title:
  update-initramfs fails during debian-installer if running kernel
  doesn't match installed kernel

Status in initramfs-tools package in Ubuntu:
  New

Bug description:
  I'm doing a preseeded installation that installs some additional
  package, among them the nvidia driver package that triggers dkms
  compilation and after that a call to update-initramfs.

  If the installer is running a different kernel than the kernel that
  gets installed in the destination chroot, this call fails, because
  update-initramfs tries to generate the initrd for both kernels.  This
  has happened this week because 3.13.0-68 is out but there was no new
  version of the installer.  But it has also happened in the past, it's
  not a new issue.

  From my logs, first the kernel gets installed:

  ========================================
  Generating grub configuration file ...
  Found linux image: /boot/vmlinuz-3.13.0-68-generic
  Found initrd image: /boot/initrd.img-3.13.0-68-generic
  Found memtest86+ images: /memtest86+.elf /memtest86+.bin
  done
  Setting up linux-image-extra-3.13.0-68-generic (3.13.0-68.111) ...
  run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 3.13.0-68-generic /boot/vmlinuz-3.13.0-68-generic
  run-parts: executing /etc/kernel/postinst.d/goobuntu-kernel-pruner 3.13.0-68-generic /boot/vmlinuz-3.13.0-68-generic
  run-parts: executing /etc/kernel/postinst.d/initramfs-tools 3.13.0-68-generic /boot/vmlinuz-3.13.0-68-generic
  update-initramfs: Generating /boot/initrd.img-3.13.0-68-generic
  Adding IMA policy.
  run-parts: executing /etc/kernel/postinst.d/pm-utils 3.13.0-68-generic /boot/vmlinuz-3.13.0-68-generic
  run-parts: executing /etc/kernel/postinst.d/update-notifier 3.13.0-68-generic /boot/vmlinuz-3.13.0-68-generic
  run-parts: executing /etc/kernel/postinst.d/zz-update-grub 3.13.0-68-generic /boot/vmlinuz-3.13.0-68-generic
  Generating grub configuration file ...
  Found linux image: /boot/vmlinuz-3.13.0-68-generic
  Found initrd image: /boot/initrd.img-3.13.0-68-generic
  ========================================

  This runs correctly with no issues, it doesn't try to do anything with
  -67.  Then comes when the dkms package get installed and the module
  built:

  ========================================
  Setting up dkms (2.2.0.3-1.1ubuntu5.14.04.5) ...
  Setting up nvidia-340 (340.93-0ubuntu0.0.1) ...
  update-alternatives: using /usr/lib/nvidia-340/ld.so.conf to provide /etc/ld.so.conf.d/x86_64-linux-gnu_GL.conf (x86_64-linux-gnu_gl_conf) in auto mode
  update-alternatives: using /usr/lib/nvidia-340/alt_ld.so.conf to provide /etc/ld.so.conf.d/i386-linux-gnu_GL.conf (i386-linux-gnu_gl_conf) in auto mode
  update-alternatives: using /usr/share/nvidia-340/glamor.conf to provide /usr/share/X11/xorg.conf.d/glamoregl.conf (glamor_conf) in auto mode
  update-initramfs: deferring update (trigger activated)
  update-initramfs: Generating /boot/initrd.img-3.13.0-67-generic
  grep: /boot/config-3.13.0-67-generic: No such file or directory
  WARNING: missing /lib/modules/3.13.0-67-generic
  Device driver support needs thus be built-in linux image!
  depmod: ERROR: could not open directory /lib/modules/3.13.0-67-generic: No such file or directory
  depmod: FATAL: could not search modules: No such file or directory
  dropbear: NOTICE: Skipping dropbear installation because /etc/crypttab has no entries.
  modprobe: ERROR: ../libkmod/libkmod.c:556 kmod_search_moddep() could not open moddep file '/lib/modules/3.13.0-67-generic/modules.dep.bin'
  W: intel-microcode: cpuid kernel driver missing
  W: intel-microcode: disabling IUCODE_TOOL_SCANCPUS option
  Adding IMA policy.
  depmod: WARNING: could not open /tmp/mkinitramfs_W4WLtO/lib/modules/3.13.0-67-generic/modules.order: No such file or directory
  depmod: WARNING: could not open /tmp/mkinitramfs_W4WLtO/lib/modules/3.13.0-67-generic/modules.builtin: No such file or directory
  INFO:Enable nvidia-340
  DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/put_your_quirks_here
  DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/lenovo_thinkpad
  DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/dell_latitude
  Adding system user `nvidia-persistenced' (UID 121) ...
  Adding new group `nvidia-persistenced' (GID 127) ...
  Adding new user `nvidia-persistenced' (UID 121) with group `nvidia-persistenced' ...
  Not creating home directory `/'.
  Loading new nvidia-340-340.93 DKMS files...
  First Installation: checking all kernels...
  It is likely that 3.13.0-67-generic belongs to a chroot's host
  Building for architecture x86_64
  Building initial module for 3.13.0-68-generic
  Done.

  nvidia_340:
  Running module version sanity check.
   - Original module
     - No original module exists within this kernel
   - Installation
     - Installing to /lib/modules/3.13.0-68-generic/updates/dkms/

  nvidia_340_uvm.ko:
  Running module version sanity check.
   - Original module
     - No original module exists within this kernel
   - Installation
     - Installing to /lib/modules/3.13.0-68-generic/updates/dkms/

  depmod....

  DKMS: install completed.
  ========================================

  Notice how dkms realizes that it's an installation chroot and
  succeeds, but update-initramfs doesn't and fails (I'm not sure why
  it's running when just before it said that it's deferring updates, I
  guess one package is triggering while some other package is failing to
  correctly use triggers and it's calling it directly) .  And then it
  fails again when it gets triggered:

  ========================================
  Processing triggers for initramfs-tools (0.103ubuntu4.2) ...
  update-initramfs: Generating /boot/initrd.img-3.13.0-68-generic
  dropbear: NOTICE: Skipping dropbear installation because /etc/crypttab has no entries.
  modprobe: ERROR: ../libkmod/libkmod.c:556 kmod_search_moddep() could not open moddep file '/lib/modules/3.13.0-67-generic/modules.dep.bin'
  W: intel-microcode: cpuid kernel driver missing
  W: intel-microcode: disabling IUCODE_TOOL_SCANCPUS option
  Adding IMA policy.
  update-initramfs: Generating /boot/initrd.img-3.13.0-67-generic
  grep: /boot/config-3.13.0-67-generic: No such file or directory
  WARNING: missing /lib/modules/3.13.0-67-generic
  Device driver support needs thus be built-in linux image!
  depmod: ERROR: could not open directory /lib/modules/3.13.0-67-generic: No such file or directory
  depmod: FATAL: could not search modules: No such file or directory
  dropbear: NOTICE: Skipping dropbear installation because /etc/crypttab has no entries.
  modprobe: ERROR: ../libkmod/libkmod.c:556 kmod_search_moddep() could not open moddep file '/lib/modules/3.13.0-67-generic/modules.dep.bin'
  W: intel-microcode: cpuid kernel driver missing
  W: intel-microcode: disabling IUCODE_TOOL_SCANCPUS option
  Adding IMA policy.
  depmod: WARNING: could not open /tmp/mkinitramfs_n7YY5Z/lib/modules/3.13.0-67-generic/modules.order: No such file or directory
  depmod: WARNING: could not open /tmp/mkinitramfs_n7YY5Z/lib/modules/3.13.0-67-generic/modules.builtin: No such file or directory
  ========================================

  update-initramfs should realize that the running kernel is not the
  installed kernel and not fail.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/initramfs-tools/+bug/1516705/+subscriptions


References