Public bug reported:

# Kernel 7.0.0-42 installed without initramfs after NVIDIA DKMS failure,
causing VFS kernel panic on two systems

### Summary

After upgrading to kernel `7.0.0-42-generic` on Ubuntu 26.04, two
independent systems became unable to boot the new kernel, both failing
with:

```
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
```

Investigation revealed that `/boot/vmlinuz-7.0.0-42-generic` was present
on both systems, but the corresponding
`/boot/initrd.img-7.0.0-42-generic` was missing.

Both machines encountered an NVIDIA DKMS compilation failure during the
kernel update. This appears to have interrupted the kernel post-
installation process before initramfs generation could complete.

Both systems remain bootable using their previous kernels.

### Affected systems

**System 1 — Desktop**
- Ubuntu 26.04
- CPU: Intel Core i7-13700F
- GPU: NVIDIA GeForce RTX 4070
- NVIDIA driver: 615.71.10
- Failing kernel: 7.0.0-42-generic
- Working fallback: 7.0.0-34-generic

**System 2 — Laptop**
- Ubuntu 26.04
- Model: Lenovo Yoga Pro 7 14IMH9
- GPU: NVIDIA GeForce RTX 4050
- NVIDIA driver: 615.71.10
- Failing kernel: 7.0.0-42-generic
- Working fallback: 7.0.0-38-generic

Both systems use NVIDIA's official CUDA APT repository.

### Steps to reproduce

1. Start with a working Ubuntu 26.04 installation using NVIDIA 615.71.10 
(`nvidia-driver-open` and `nvidia-dkms-open`).
2. Upgrade to kernel `7.0.0-42-generic` through APT.
3. NVIDIA DKMS fails to compile against the updated kernel.
4. The kernel package's post-installation script exits unsuccessfully.
5. Reboot into the newly installed kernel.
6. The system encounters a VFS kernel panic.

This sequence occurred independently on both systems.

### Relevant installation errors

During the kernel update:

```
Autoinstall of module nvidia/615.71.10 for kernel 7.0.0-42-generic (x86_64)
Building module(s).........(bad exit status: 2)

Error! Bad return status for module build on kernel: 7.0.0-42-generic
(x86_64)

Autoinstall on 7.0.0-42-generic succeeded for module(s) kvmfr.
Autoinstall on 7.0.0-42-generic failed for module(s) nvidia(10).

Error! One or more modules failed to install during autoinstall.

run-parts: /etc/kernel/postinst.d/dkms exited with return code 1

dpkg: error processing package linux-image-7.0.0-42-generic (--configure):
 old linux-image-7.0.0-42-generic package postinst maintainer script subprocess 
failed with exit status 1
```

The underlying NVIDIA compilation error, reproduced on both systems, is:

```
././common/inc/nv-linux.h:1270:34: error: field ‘cxlds’ has incomplete type
 1270 |     struct cxl_dev_state         cxlds;
      |                                  ^~~~~
```

The NVIDIA compatibility issue has been reported separately:
https://github.com/NVIDIA/open-gpu-kernel-modules/issues/1433

### Missing initramfs

On the desktop:

```
/boot/initrd.img-7.0.0-34-generic   present
/boot/vmlinuz-7.0.0-34-generic      present
/boot/vmlinuz-7.0.0-42-generic      present
/boot/initrd.img-7.0.0-42-generic   missing
```

On the laptop:

```
/boot/initrd.img-7.0.0-38-generic   present
/boot/vmlinuz-7.0.0-38-generic      present
/boot/vmlinuz-7.0.0-42-generic      present
/boot/initrd.img-7.0.0-42-generic   missing
```

On the laptop, `dpkg --audit` also reports:

```
Packages unpacked but not configured:
 nvidia-driver-open

Packages half-configured:
 linux-image-7.0.0-42-generic
 nvidia-dkms-open
```

### Expected behaviour

A third-party DKMS compilation failure should not leave the system
attempting to boot a kernel without the initramfs required to mount its
root filesystem.

Ideally, the kernel installation process should either:

- Generate the initramfs despite the third-party DKMS failure, allowing the 
kernel to boot without the affected module; or
- Prevent the incomplete kernel installation from becoming the default boot 
option, retaining the previously working kernel.

### Actual behaviour

The NVIDIA DKMS failure causes `/etc/kernel/postinst.d/dkms` to exit
with status 1, interrupting the kernel package configuration.

The new kernel image remains present, but its initramfs is missing. On
reboot, both machines attempt to boot the new kernel and panic because
the root filesystem cannot be mounted.

Recovery requires manually selecting a previous kernel through GRUB.

### Additional observations

The issue has been independently reproduced on two systems with
different NVIDIA GPUs and different working fallback kernels.

This suggests the problem is not hardware-specific.

Although the initial failure originates in NVIDIA's out-of-tree module,
the resulting unbootable kernel appears to expose an error-handling or
ordering problem in Ubuntu's kernel installation hooks.

The main concern of this report is not the NVIDIA compilation
incompatibility itself, but the fact that this failure can leave Ubuntu
unable to boot normally after an otherwise routine kernel update.


### Possibly related bug

This may be related to Launchpad bug #2141741, which describes a similar
failure where a DKMS error interrupts kernel installation, leaving the
initramfs missing.

Although the symptoms appear similar, this report concerns Ubuntu 26.04,
kernel 7.0.0-42-generic, and NVIDIA 615.71.10. I have reproduced the
issue on two independent machines.

https://bugs.launchpad.net/bugs/2141741

** Affects: linux (Ubuntu)
     Importance: Undecided
         Status: New

** Summary changed:

- Kernel 7.0.0-42 installed without initramfs after NVIDIA DKMS failure, 
causing VFS kernel panic on two systems
+ Ubuntu 26.04: NVIDIA DKMS failure leaves kernel 7.0.0-42 without initramfs, 
causing VFS panic on reboot

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2172736

Title:
  Ubuntu 26.04: NVIDIA DKMS failure leaves kernel 7.0.0-42 without
  initramfs, causing VFS panic on reboot

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2172736/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to