[Bug 2025294] Re: /etc/grub/10_linux_zfs has bad zpool command

Julian Andres Klode 2025294 at bugs.launchpad.net
Thu Jun 29 10:44:51 UTC 2023


The -H command does exist in zfsutils-linux version of zpool

$ zpool get -H
missing property argument
usage:
        get [-Hp] [-o "all" | field[,...]] <"all" | property[,...]> <pool> ...


It seems you have accidentally installed zfs-fuse from universe instead, which probably should be removed from the archive.

** Package changed: grub2 (Ubuntu) => zfs-fuse (Ubuntu)

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

Title:
  /etc/grub/10_linux_zfs has bad zpool command

Status in zfs-fuse package in Ubuntu:
  New

Bug description:
  $ lsb_release -rd
  No LSB modules are available.
  Description:	Ubuntu 23.04
  Release:	23.04

  $ apt-cache policy grub-common
  grub-common:
    Installed: 2.06-2ubuntu16
    Candidate: 2.06-2ubuntu16
    Version table:
   *** 2.06-2ubuntu16 500
          500 http://us.archive.ubuntu.com/ubuntu lunar/main amd64 Packages
          100 /var/lib/dpkg/status

  
  The zpool command does not have a -H flag (at least in Ubuntu 23.04).
  This results in an error from the /etc/grub.d/10_linux_zfs script during update-grub.

  The fix is to remove the -H flag and adjust the awk script to ignore
  the headline line (see diff).

  $ sudo update-grub
  Sourcing file `/etc/default/grub'
  Sourcing file `/etc/default/grub.d/init-select.cfg'
  Generating grub configuration file ...
  Found linux image: /boot/vmlinuz-6.2.0-24-generic
  Found initrd image: /boot/initrd.img-6.2.0-24-generic
  bad property list: invalid property '-H'
  usage:
  	get <"all" | property[,...]> <pool> ...

  the following properties are supported:

          PROPERTY         EDIT   VALUES

  	allocated          NO   <size>
  	capacity           NO   <size>
  	dedupratio         NO   <1.00x or higher if deduped>
  	free               NO   <size>
  	guid               NO   <guid>
  	health             NO   <state>
  	size               NO   <size>
  	altroot           YES   <path>
  	ashift            YES   <ashift, 9-13, or 0=default>
  	autoexpand        YES   on | off
  	autoreplace       YES   on | off
  	bootfs            YES   <filesystem>
  	cachefile         YES   <file> | none
  	dedupditto        YES   <threshold (min 100)>
  	delegation        YES   on | off
  	failmode          YES   wait | continue | panic
  	listsnapshots     YES   on | off
  	version           YES   <version>
  Found memtest86+ 64bit EFI image: /memtest86+x64.efi
  Warning: os-prober will not be executed to detect other bootable partitions.
  Systems on them will not be added to the GRUB boot configuration.
  Check GRUB_DISABLE_OS_PROBER documentation entry.
  Adding boot menu entry for UEFI Firmware Settings ...
  done

  
  Diffing the original against a patched (working) version:

  $ diff 10_linux_zfs /etc/grub.d/10_linux_zfs 
  102c102,103
  <         local rel_pool_root=$(zpool get -H altroot ${p} | awk '{print $3}')
  ---
  >         # local rel_pool_root=$(zpool get -H altroot ${p} | awk '{print $3}')
  >         local rel_pool_root=$(zpool get altroot ${p} | awk 'NR > 1 {print $3}')

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/zfs-fuse/+bug/2025294/+subscriptions




More information about the foundations-bugs mailing list