I modified 10_linux_zfs to comment out the set -e and add the variables
for pkgdatadir and the GRUB* variables from /etc/default/grub and ran it
to see the output.

Notice at the end the double brace, lack of initrd value and linux image
even though it was found at the beginning when it correctly identified
the root dataset.


jpb@explorer:~/test$ sudo ./10_linux_zfs 
Found linux image: vmlinuz-5.0.0-29-generic in rpool/ROOT/ubuntu
Found initrd image: initrd.img-5.0.0-29-generic in rpool/ROOT/ubuntu
Found linux image: vmlinuz-5.0.0-31-generic in rpool/ROOT/ubuntu
Found initrd image: initrd.img-5.0.0-31-generic in rpool/ROOT/ubuntu
Found linux image: vmlinuz-5.0.0-32-generic in rpool/ROOT/ubuntu
Found initrd image: initrd.img-5.0.0-32-generic in rpool/ROOT/ubuntu
Found linux image: vmlinuz-5.3.0-18-generic in rpool/ROOT/ubuntu
Found initrd image: initrd.img-5.3.0-18-generic in rpool/ROOT/ubuntu
Found linux image: vmlinuz-5.0.0-23-generic in 
rpool/ROOT/ubuntu@pyznap_2019-08-18_14:11:36_monthly
Found initrd image: initrd.img-5.0.0-23-generic in 
rpool/ROOT/ubuntu@pyznap_2019-08-18_14:11:36_monthly

********** removed a ton of snapshots that were listed which found the
linux image and initrd image. *****************

Found linux image: vmlinuz-5.3.0-18-generic in 
rpool/ROOT/ubuntu@apt2019-10-19_08.52.43--1w
Found initrd image: initrd.img-5.3.0-18-generic in 
rpool/ROOT/ubuntu@apt2019-10-19_08.52.43--1w


function gfxmode {
        set gfxpayload="${1}"
        if [ "${1}" = "keep" ]; then
                set vt_handoff=vt.handoff=1
        else
                set vt_handoff=
        fi
}
if [ "${recordfail}" != 1 ]; then
  if [ -e ${prefix}/gfxblacklist.txt ]; then
    if hwmatch ${prefix}/gfxblacklist.txt 3; then
      if [ ${match} = 0 ]; then
        set linux_gfx_mode=keep
      else
        set linux_gfx_mode=text
      fi
    else
      set linux_gfx_mode=text
    fi
  else
    set linux_gfx_mode=keep
  fi
else
  set linux_gfx_mode=text
fi
export linux_gfx_mode
menuentry 'Ubuntu 19.10' --class ubuntu --class gnu-linux --class gnu --class 
os ${menuentry_id_option} 'gnulinux-rpool/ROOT/ubuntu-' {
        recordfail
        load_video
        gfxmode ${linux_gfx_mode}
        insmod gzio
        if [ "${grub_platform}" = xen ]; then insmod xzio; insmod lzopio; fi
        insmod part_gpt
        insmod zfs
        set root='hd2,gpt1'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd2,gpt1 
--hint-efi=hd2,gpt1 --hint-baremetal=ahci2,gpt1  ba04856b80ac4244
        else
          search --no-floppy --fs-uuid --set=root ba04856b80ac4244
        fi
        linux    root=ZFS=rpool/ROOT/ubuntu ro intel_iommu=on iommu=pt quiet 
splash intel_iommu=on iommu=pt rootdelay=3 zswap.enabled=1 zswap.compressor=lz4 
zswap.zpool=z3fold ${vt_handoff} 
        initrd  
}
}

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

Title:
  Upgrade from 19.04 to 19.10 with zfs on root fails with grub syntax
  error

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

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

Reply via email to