Cobra Forum

Linux => General Help => Topic started by: Raja Cobra on Oct 10, 2023, 01:57 AM

Title: Ubuntu ZFS install won't boot (Grub Command Line)
Post by: Raja Cobra on Oct 10, 2023, 01:57 AM
Hello friends,

all of a sudden my ubuntu 22.04 LTS ZFS install doesn't boot anymore. It goes straight into Grub command line mode. I tried following tutorials but I think because I have an encrypted ZFS they don't work. Here is a boot info from Boot-Repair. Could you please help me out?

     Code:
boot-repair-4ppa2056                                              [20231008_1132]

============================== Boot Info Summary ===============================

 => No boot loader is installed in the MBR of /dev/nvme0n1.

nvme0n1p1: _____________________________________________________________________

    File system:       vfat
    Boot sector type:  FAT32
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System: 
    Boot files:        /grub/grub.cfg /efi/BOOT/fbx64.efi /efi/BOOT/mmx64.efi
                       /efi/ubuntu/grubx64.efi /efi/ubuntu/mmx64.efi
                       /efi/ubuntu/shimx64.efi /efi/ubuntu/grub.cfg

nvme0n1p2: _____________________________________________________________________

    File system:       
    Boot sector type:  Unknown
    Boot sector info:

nvme0n1p3: _____________________________________________________________________

    File system:       zfs_member
    Boot sector type:  -
    Boot sector info:
    Operating System: 
    Boot files:       

nvme0n1p4: _____________________________________________________________________

    File system:       zfs_member
    Boot sector type:  -
    Boot sector info:
    Operating System: 
    Boot files:       

sda: ___________________________________________________________________________

    File system:       iso9660
    Boot sector type:  Grub2 (v1.99-2.00)
    Boot sector info:  Grub2 (v1.99-2.00) is installed in the boot sector of
                       sda and looks at sector 0 of the same hard drive for
                       core.img, but core.img can not be found at this
                       location.
    Mounting failed:   mount: /mnt/BootInfo/FD/sda: /dev/sda already mounted or mount point busy.


================================ 0 OS detected =================================


================================ Host/Hardware =================================

CPU architecture: 64-bit
Video: Renoir from Advanced Micro Devices, Inc. [AMD/ATI]
Live-session OS is Ubuntu 64-bit (Ubuntu 22.04.3 LTS, jammy, x86_64)

===================================== UEFI =====================================

BIOS/UEFI firmware: S77 Ver. 01.02.02(2.2) from HP
The firmware is EFI-compatible, and is set in EFI-mode for this live-session.
SecureBoot disabled (confirmed by mokutil).
BootCurrent: 0002
Timeout: 0 seconds
BootOrder: 0005,0002,0004,0000
Boot0000  Network Boot:IPV4      PciRoot(0x0)/Pci(0x1,0x3)/Pci(0x0,0x0)/IPv4(0.0.0.00.0.0.0,0,0)N.....YM....R,Y..(..ISPH
Boot0002* JetFlash Mass Storage Device 1282477908    PciRoot(0x0)/Pci(0x8,0x1)/Pci(0x0,0x4)/USB(5,0)N.....YM....R,Y.....ISPH
Boot0003  Network Boot:IPV4      PciRoot(0x0)/Pci(0x8,0x1)/Pci(0x0,0x3)/USB(4,0)/MAC(3c18a07e7aaa,0)/IPv4(0.0.0.00.0.0.0,0,0)N.....YM....R,Y.....ISPH
Boot0004  Network Boot:IPV6      PciRoot(0x0)/Pci(0x8,0x1)/Pci(0x0,0x3)/USB(4,0)/MAC(3c18a07e7aaa,0)/IPv6([::]:<->[::]:,0,0)N.....YM....R,Y..0..ISPH
Boot0005* ubuntu    HD(1,GPT,02e5d4f5-b84e-477a-ad62-951397b93066,0x800,0x100000)/File(\EFI\ubuntu\shimx64.efi)....ISPH

a9c517741ac31962d7feb152948ad1ee   nvme0n1p1/BOOT/fbx64.efi
a660182adef313615746a665966d2ccc   nvme0n1p1/BOOT/mmx64.efi
5ddf997e8b025bfbc2009e85b32f60dc   nvme0n1p1/ubuntu/grubx64.efi
a660182adef313615746a665966d2ccc   nvme0n1p1/ubuntu/mmx64.efi
64349b3622c65f495a99dbf6102496e3   nvme0n1p1/ubuntu/shimx64.efi
64349b3622c65f495a99dbf6102496e3   nvme0n1p1/BOOT/BOOTX64.efi

============================= Drive/Partition Info =============================

Disks info: ____________________________________________________________________

nvme0n1    : is-GPT,    no-BIOSboot,    has---ESP,     not-usb,    not-mmc, no-os,    no-wind,    2048 sectors * 512 bytes

Partitions info (1/3): _________________________________________________________

nvme0n1p1    : no-os,    64, nopakmgr,    no-docgrub,    nogrub,    nogrubinstall,    grubenv-ok,    noupdategrub,    not-far
nvme0n1p3    : no-os,    64, nopakmgr,    no-docgrub,    nogrub,    nogrubinstall,    no-grubenv,    noupdategrub,    not-far
nvme0n1p4    : no-os,    64, nopakmgr,    no-docgrub,    nogrub,    nogrubinstall,    no-grubenv,    noupdategrub,    farbios
nvme0n1p2    : no-os,    64, nopakmgr,    no-docgrub,    nogrub,    nogrubinstall,    no-grubenv,    noupdategrub,    not-far

Partitions info (2/3): _________________________________________________________

nvme0n1p1    : is---ESP,    part-has-no-fstab,    no-nt,    no-winload,    no-recov-nor-hid,    no-bmgr,    notwinboot
nvme0n1p3    : isnotESP,    part-has-no-fstab,    no-nt,    no-winload,    no-recov-nor-hid,    no-bmgr,    notwinboot
nvme0n1p4    : isnotESP,    part-has-no-fstab,    no-nt,    no-winload,    no-recov-nor-hid,    no-bmgr,    notwinboot
nvme0n1p2    : isnotESP,    part-has-no-fstab,    no-nt,    no-winload,    no-recov-nor-hid,    no-bmgr,    notwinboot

Partitions info (3/3): _________________________________________________________

nvme0n1p1    : not--sepboot,    no---boot,    part-has-no-fstab,    not-sep-usr,    no---usr,    part-has-no-fstab,    no--grub.d,    nvme0n1
nvme0n1p3    : is--zfs-boot,    no---boot,    part-has-no-fstab,    not-sep-usr,    no---usr,    part-has-no-fstab,    no--grub.d,    nvme0n1
nvme0n1p4    : maybesepboot,    with-boot,    part-has-no-fstab,    not-sep-usr,    no---usr,    part-has-no-fstab,    no--grub.d,    nvme0n1
nvme0n1p2    : maybesepboot,    no---boot,    part-has-no-fstab,    not-sep-usr,    no---usr,    part-has-no-fstab,    no--grub.d,    nvme0n1

fdisk -l (filtered): ___________________________________________________________

Disk nvme0n1: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk identifier: DC84D234-028F-4AE0-9C1A-4EA281BFC6F0
            Start        End    Sectors  Size Type
nvme0n1p1    2048    1050623    1048576  512M EFI System
nvme0n1p2 1050624    5244927    4194304    2G Linux swap
nvme0n1p3 5244928    9439231    4194304    2G Solaris boot
nvme0n1p4 9439232 1953525134 1944085903  927G Solaris root
Disk sda: 29.44 GiB, 31608274944 bytes, 61734912 sectors
Disk identifier: F45E2FA1-C5A6-4D79-876F-C8245AF921E0
        Start      End  Sectors  Size Type
sda1       64  9828451  9828388  4.7G Microsoft basic data
sda2  9828452  9838519    10068  4.9M EFI System
sda3  9838520  9839119      600  300K Microsoft basic data
sda4  9842688 61734848 51892161 24.7G Linux filesystem
Disk zd0: 500 MiB, 524288000 bytes, 1024000 sectors

parted -lm (filtered): _________________________________________________________

sda:31.6GB:scsi:512:512:gpt:JetFlash Transcend 32GB:;
1:32.8kB:5032MB:5032MB::ISO9660:hidden, msftdata;
2:5032MB:5037MB:5155kB::Appended2:boot, esp;
3:5037MB:5038MB:307kB::Gap1:hidden, msftdata;
4:5039MB:31.6GB:26.6GB:ext4::;
nvme0n1:1000GB:nvme:512:512:gpt:KINGSTON SA2000M81000G:;
1:1049kB:538MB:537MB:fat32:EFI System Partition:boot, esp;
2:538MB:2685MB:2147MB:::swap;
3:2685MB:4833MB:2147MB:zfs::;
4:4833MB:1000GB:995GB:zfs::;
zd0:524MB:unknown:512:8192:unknown:Unknown:;

blkid (filtered): ______________________________________________________________

NAME        FSTYPE      UUID                                 PARTUUID                             LABEL                    PARTLABEL
sda         iso9660     2023-08-08-01-19-05-00                                                    Ubuntu 22.04.3 LTS amd64
├─sda1      iso9660     2023-08-08-01-19-05-00               f45e2fa1-c5a6-4d79-876e-c8245af921e0 Ubuntu 22.04.3 LTS amd64 ISO9660
├─sda2      vfat        F7DB-4D56                            f45e2fa1-c5a6-4d79-876d-c8245af921e0 ESP                      Appended2
├─sda3                                                       f45e2fa1-c5a6-4d79-876c-c8245af921e0                          Gap1
└─sda4      ext4        67c19720-23bb-40ba-9e8c-5515b1ce3a57 0eeffd4a-98dc-5240-b397-d9f35643b53d writable                 
zd0         crypto_LUKS c8d945b2-bf18-402e-baf7-2d5082db3f41                                                               
nvme0n1                                                                                                                   
├─nvme0n1p1 vfat        800D-4749                            02e5d4f5-b84e-477a-ad62-951397b93066                          EFI System Partition
├─nvme0n1p2                                                  ee061f36-8884-c648-b69d-de9e629fedf8                         
├─nvme0n1p3 zfs_member  10055664188803140528                 b478cca9-c427-b94f-a046-b9ec23251ea1 bpool                   
└─nvme0n1p4 zfs_member  5792523734577493029                  24d8727b-f1b9-774f-b926-cb44f9823e49 rpool                   

Mount points (filtered): _______________________________________________________

                                                               Avail Use% Mounted on
bpool/BOOT/ubuntu_1x5gh3                                       25.4M  92% /mnt/boot-sav/zfs/boot
/dev/disk/by-label/writable[/install-logs-2077-07-10.0/crash]  22.9G   0% /var/crash
/dev/disk/by-label/writable[/install-logs-2077-07-10.0/log]    22.9G   0% /var/log
/dev/nvme0n1p1                                                496.7M   3% /mnt/boot-sav/nvme0n1p1
/dev/sda1                                                          0 100% /cdrom

Mount options (filtered): ______________________________________________________


====================== nvme0n1p1/grub/grub.cfg (filtered) ======================

Revert system only   gnulinux-${root_dataset}-${kversion}
Revert system and user data   gnulinux-${root_dataset}-${kversion}
Ubuntu 22.04.3 LTS   gnulinux-rpool/ROOT/ubuntu_1x5gh3-6.2.0-33-generic
* Ubuntu 22.04.3 LTS, with Linux 6.2.0-33-generic   gnulinux-rpool/ROOT/ubuntu_1x5gh3-6.2.0-33-generic
Ubuntu 22.04.3 LTS, with Linux 6.2.0-32-generic   gnulinux-rpool/ROOT/ubuntu_1x5gh3-6.2.0-32-generic
### END /etc/grub.d/30_os-prober ###
UEFI Firmware Settings   uefi-firmware
### END /etc/grub.d/30_uefi-firmware ###

=================== nvme0n1p1/efi/ubuntu/grub.cfg (filtered) ===================

search.fs_uuid 800D-4749 root
set prefix=($root)'/grub'
configfile $prefix/grub.cfg

================= nvme0n1p1: Location of files loaded by Grub ==================

           GiB - GB             File                                 Fragment(s)
            ?? = ??             grub/grub.cfg                                  1

================= nvme0n1p3: Location of files loaded by Grub ==================

           GiB - GB             File                                 Fragment(s)
            ?? = ??             vmlinuz
            ?? = ??             vmlinuz-6.2.0-32-generic
            ?? = ??             vmlinuz-6.2.0-33-generic
            ?? = ??             vmlinuz.old
            ?? = ??             initrd.img
            ?? = ??             initrd.img-6.2.0-32-generic
            ?? = ??             initrd.img-6.2.0-33-generic
            ?? = ??             initrd.img.old

================= nvme0n1p4: Location of files loaded by Grub ==================

           GiB - GB             File                                 Fragment(s)
            ?? = ??             boot/vmlinuz
            ?? = ??             boot/vmlinuz-6.2.0-32-generic
            ?? = ??             boot/vmlinuz-6.2.0-33-generic
            ?? = ??             boot/vmlinuz.old
            ?? = ??             boot/initrd.img
            ?? = ??             boot/initrd.img-6.2.0-32-generic
            ?? = ??             boot/initrd.img-6.2.0-33-generic
            ?? = ??             boot/initrd.img.old

======================== Unknown MBRs/Boot Sectors/etc =========================

Unknown BootLoader on nvme0n1p2




================================ ZFS activation ================================

dpkg-query -W -f=${Version} zfsutils-linux : 2.1.5-1ubuntu6~22.04.1
zpool export -f -a

zpool import -N -f -R /mnt/boot-sav/zfs rpool
zpool import -N -f -R /mnt/boot-sav/zfs bpool
If needed, type 'sudo zfs load-key -a' in another terminal.
zfs mount rpool/ROOT/ubuntu_1x5gh3
zfs mount -a
Error: could not activate ZFS. Please report this message to boot.repair@gmail.com
zpool list after activation
NAME    SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT
bpool  1.88G  1.73G   153M        -         -    60%    92%  1.00x    ONLINE  /mnt/boot-sav/zfs
rpool   920G   652G   268G        -         -    26%    70%  1.00x    ONLINE  /mnt/boot-sav/zfs

zfs list
NAME                                               USED  AVAIL     REFER  MOUNTPOINT
bpool                                             1.72G  25.4M       96K  /mnt/boot-sav/zfs/boot
bpool/BOOT                                        1.72G  25.4M       96K  none
bpool/BOOT/ubuntu_1x5gh3                          1.72G  25.4M      304M  /mnt/boot-sav/zfs/boot
rpool                                              652G   239G      192K  /mnt/boot-sav/zfs
rpool/ROOT                                        57.3G   239G      192K  none
rpool/ROOT/ubuntu_1x5gh3                          57.3G   239G     9.83G  /mnt/boot-sav/zfs
rpool/ROOT/ubuntu_1x5gh3/srv                       432K   239G      192K  /mnt/boot-sav/zfs/srv
rpool/ROOT/ubuntu_1x5gh3/usr                       591M   239G      192K  /mnt/boot-sav/zfs/usr
rpool/ROOT/ubuntu_1x5gh3/usr/local                 591M   239G      570M  /mnt/boot-sav/zfs/usr/local
rpool/ROOT/ubuntu_1x5gh3/var                      27.3G   239G      192K  /mnt/boot-sav/zfs/var
rpool/ROOT/ubuntu_1x5gh3/var/games                 272K   239G      192K  /mnt/boot-sav/zfs/var/games
rpool/ROOT/ubuntu_1x5gh3/var/lib                  26.4G   239G     9.44G  /mnt/boot-sav/zfs/var/lib
rpool/ROOT/ubuntu_1x5gh3/var/lib/AccountsService  1.41M   239G      216K  /mnt/boot-sav/zfs/var/lib/AccountsService
rpool/ROOT/ubuntu_1x5gh3/var/lib/NetworkManager   12.7M   239G      948K  /mnt/boot-sav/zfs/var/lib/NetworkManager
rpool/ROOT/ubuntu_1x5gh3/var/lib/apt               337M   239G      111M  /mnt/boot-sav/zfs/var/lib/apt
rpool/ROOT/ubuntu_1x5gh3/var/lib/dpkg              957M   239G      137M  /mnt/boot-sav/zfs/var/lib/dpkg
rpool/ROOT/ubuntu_1x5gh3/var/log                   830M   239G      236M  /mnt/boot-sav/zfs/var/log
rpool/ROOT/ubuntu_1x5gh3/var/mail                  272K   239G      192K  /mnt/boot-sav/zfs/var/mail
rpool/ROOT/ubuntu_1x5gh3/var/snap                 47.8M   239G     9.11M  /mnt/boot-sav/zfs/var/snap
rpool/ROOT/ubuntu_1x5gh3/var/spool                2.84M   239G      352K  /mnt/boot-sav/zfs/var/spool
rpool/ROOT/ubuntu_1x5gh3/var/www                   272K   239G      192K  /mnt/boot-sav/zfs/var/www
rpool/USERDATA                                     594G   239G      192K  /mnt/boot-sav/zfs
rpool/USERDATA/mrtickle_j15ygf                     594G   239G      486G  /mnt/boot-sav/zfs/home/mrtickle
rpool/USERDATA/root_j15ygf                        73.8M   239G     69.8M  /mnt/boot-sav/zfs/root
rpool/keystore                                     518M   240G     48.1M  -

=================== findmnt (filtered) after ZFS activation ====================

SOURCE                                                        FSTYPE        SIZE   USED AVAIL USE% TARGET
/dev/sda1                                                     iso9660       4.7G   4.7G     0 100% /cdrom
/dev/disk/by-label/writable[/install-logs-2077-07-10.0/log]   ext4         24.2G     5M 22.9G   0% /var/log
/dev/disk/by-label/writable[/install-logs-2077-07-10.0/crash] ext4         24.2G     5M 22.9G   0% /var/crash
bpool/BOOT/ubuntu_1x5gh3                                      zfs         329.6M 304.4M 25.3M  92% /mnt/boot-sav/zfs/boot




Suggested repair: ______________________________________________________________

The default repair of the Boot-Repair utility would not act on the boot.

Confirmation request before suggested repair: __________________________________

Warning: ZFS not activated correctly. Repair will fail unless you mount the pools on /mnt/boot-sav/zfs before continuing. Please report this message to boot.repair@gmail.com
Are you sure you want to continue anyway?