grub zfs integration fails when fstab has been modified without reloading systemd

Bug #2004133 reported by ullash
34
This bug affects 7 people
Affects Status Importance Assigned to Milestone
grub2 (Ubuntu)
Triaged
Medium
Unassigned
util-linux (Ubuntu)
New
Undecided
Unassigned

Bug Description

dont know

ProblemType: Package
DistroRelease: Ubuntu 22.10
Package: grub-pc 2.06-2ubuntu12.1
ProcVersionSignature: Ubuntu 5.19.0-29.30-generic 5.19.17
Uname: Linux 5.19.0-29-generic x86_64
NonfreeKernelModules: zfs zunicode zavl icp zcommon znvpair
ApportVersion: 2.23.1-0ubuntu3
Architecture: amd64
CasperMD5CheckResult: unknown
Date: Mon Jan 23 21:25:33 2023
ErrorMessage: installed grub-pc package post-installation script subprocess returned error exit status 1
ProcCmdLine: BOOT_IMAGE=/BOOT/ubuntu_7ydweu@/vmlinuz-5.19.0-29-generic root=ZFS=rpool/ROOT/ubuntu_7ydweu ro quiet splash vt.handoff=1
Python3Details: /usr/bin/python3.10, Python 3.10.7, python3-minimal, 3.10.6-1
PythonDetails: N/A
RelatedPackageVersions:
 dpkg 1.21.9ubuntu1
 apt 2.5.3
SourcePackage: grub2
Title: package grub-pc 2.06-2ubuntu12.1 failed to install/upgrade: installed grub-pc package post-installation script subprocess returned error exit status 1
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
ullash (moharaja) wrote :
affects: ubuntu → grub2 (Ubuntu)
tags: removed: need-duplicate-check
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in grub2 (Ubuntu):
status: New → Confirmed
Revision history for this message
Sean Thomas Goul (seangoul) wrote :

happens when i first install the latest version of Ubuntu on oem install, when i get done installing, then it boots i enroll the key, after i reboot and load into the first system to do the preparation of the oem configuration, when i connect it to WiFi that is when it happens and gives me several errors including this one.

Changed in grub2 (Ubuntu):
status: Confirmed → Triaged
Revision history for this message
Julian Andres Klode (juliank) wrote :

This bug only affects zfs systems that have modified fstab without reloading systemd.

Essentially we run find on $boot_dir which is set as

    # read available kernels from /boot
    boot_dir="$(try_default_layout_bpool "${dataset}" "${mntdir}")"
    if [ -z "${boot_dir}" ]; then
        boot_dir=$(get_system_directory "${dataset}" "boot" "false" "${mntdir}" "${etc_dir}")
    fi

which somehow ends up being

'mount: (hint) your fstab has been modified, but systemd still uses\n the old version; use 'systemctl daemon-reload' to reload.\n/tmp/zfsmnt.liPzsI/boot'

It's not clear to me why the hint is on stdout in the first place.

This then causes the script to exit, which causes the trap to run which is broken due to bug 2031042.

Changed in grub2 (Ubuntu):
importance: Undecided → Medium
summary: - package grub-pc 2.06-2ubuntu12.1 failed to install/upgrade: installed
- grub-pc package post-installation script subprocess returned error exit
- status 1
+ grub zfs integration fails when fstab has been modified without
+ reloading systemd
Revision history for this message
Julian Andres Klode (juliank) wrote :

Also adding util-linux because it's util-linux outputing warnings to stdout instead of stderr, hence breaking stuff trying to parse the output.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.