[SOLVED] Can't boot after power outage

biotim

Active Member
Aug 13, 2018
22
0
41
The boot area becomes corrupted and at system startup a message appears on a black display: grub rescue unknown filesystem.
I choosed ZFS as root filesystem.
If I do "ls" I get the list below which I think are my three partitions

Code:
grub rescue> ls
(hd0)  (hd0,gpt9)  (hd0,gpt2)   (hd0,gpt1)

Code:
grub rescue> set
cmdpath=(hd0)
prefix=(hd0.gpt2)/ROOT/pve-1@/boot/grub
root=hd0.2

Code:
$ lsblk -o +FSTYPE
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINTS
                                        FSTYPE
sdb      8:16   0 931,5G  0 disk      
├─sdb1   8:17   0  1007K  0 part      
├─sdb2   8:18   0 931,5G  0 part        zfs_member
└─sdb9   8:25   0     8M  0 part

Any tips? I will appreciate any help.
 
Last edited:
1.) import the pool
2.) bind-mount /dev, /proc, /run and /sys
3.) chroot into pools root filesystem
4.) install the new grub or use the proxmox-boot-tool in case PVE was installed with ISO >7.3+

So something like:
Code:
zpool import -f -R /mnt rpool
mount -o bind /dev /mnt/rpool/ROOT/pve-1/dev
mount -o bind /sys /mnt/rpool/ROOT/pve-1/sys
mount -o bind /proc /mnt/rpool/ROOT/pve-1/proc
mount -o bind /run /mnt/rpool/ROOT/pve-1/run
chroot /mnt/rpool/ROOT/pve-1

grub-install /dev/yourBootDisk
or
proxmox-boot-tool init /dev/yourESPpartition

You also might need to mount your boot/EFI partition.
 
Last edited:
  • Like
Reactions: biotim
Looks like there are no EFI system paritions and the last time I saw that message it was because a zpool feature was enabled that GRUB cannot handle. I hope it's not that (and got activated by the unexpected reboot).
 
Looks like there are no EFI system paritions and the last time I saw that message it was because a zpool feature was enabled that GRUB cannot handle. I hope it's not that (and got activated by the unexpected reboot).
Jup, could be that. What PVE version were you running? Creating a ESP partition and switching from legacy-boot to proxmox-boot-tool might be required in case you upgraded your PVE to >6.3: https://pve.proxmox.com/wiki/ZFS:_Switch_Legacy-Boot_to_Proxmox_Boot_Tool

Did you ever run a zpool upgrade rpool? Because this then could brick your PVE.
 
Last edited:
mount -o bind /dev /mnt/rpool/ROOT/pve-1/dev
mount: /mnt/rpool/ROOT/pve-1/dev: mount point does not exist.
need another mount point.
 
Last edited:
Whats is zfs get mountpoint or lsblk returning to check where the rpool/ROOT/pve-1 dataset is mounted?
 
Last edited:
Code:
zpool import -f -R /mnt rpool
mount -o rbind /proc /mnt/proc
mount -o rbind /sys /mnt/sys
mount -o rbind /dev /mnt/dev
mount -o rbind /run /mnt/run
chroot /mnt /bin/bash
this is how it works

Then update grub and install it.
  • grub-install /dev/sdb
  • update-grub2
  • update-initramfs -u
 
Last edited:
grub updates successfully but system still starts in grub rescue unknown filesystem =\
 
You didn't answer to:
Did you ever run a zpool upgrade rpool? Because this then could brick your PVE.
This should show up when watching the pools history with zpool history rpool.

As upgraded rpool can not boot with legacy grub without booting from grub via the proxmox-boot-tool.
 
Last edited:
no, did not zpool upgrade rpool. We'll continue tomorrow now it's too late.
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!