how to make grub redundant with ZFS mirror ?

JOduMonT

Renowned Member
Jan 20, 2016
73
6
73
Bangkok
jdumont.consulting
Hi everyone;

I'm about reinstalling my proxmox which will have 2 raid
one for the data (2x SATA 5TB) and one for the vm and container (2x SSD 1TB)

My concern is; in the past I had issue to not make the grub my single point of failure.

I want the GRUB2 bootloader to be configured in such a way that the system will still be able to boot if one of the hard drives fails (no matter which one).

How should I proceed ?

Simply by selecting 2drives for my ZFS via the standard install from proxmox-ve.iso or I need to reconfigure the grub with something similar of this ?

# dpkg-reconfigure grub-pc
# grub-pc grub-pc/install_devices multiselect /dev/sda, /dev/sdb
 
Simply by selecting 2drives for my ZFS via the standard install from proxmox-ve.iso

Yes. This is sufficient. If you have a stripped mirrored vdevs, on the first vdev, there will be an additional partition for grub. This is only true for legacy-boot and does not work for UEFI.
 
Hum;

Thanks @LnxBil

But after few try my SSD raid zfs is not stable, my NVMe drive randomly disappear. (which happens only debian not with CentOS)

So i would like to install proxmox on my sata raid which is the 5TB, which means from what I understood, EFI required.

The question is now how to make proof fail safe a ZFS mirror with EFI ?

It is just easier with mdadm and LVM ?

How people manage this ?
I means as soft raid or soft raid is just not professional enough ?

Any output and direction would be considered ;)
 
So i would like to install proxmox on my sata raid which is the 5TB, which means from what I understood, EFI required.

You mean GPT, not UEFI, right?

The question is now how to make proof fail safe a ZFS mirror with EFI ?

You can't. EFI is not designed for that so that you need to sync the stuff by yourself. That means you need to dd the partition of the first disk to the second after each change and configure your UEFI in such a way that both devices are in direct boot order.

How people manage this ?
I means as soft raid or soft raid is just not professional enough ?

There is no solution for this, because UEFI does not work with software RAID. Often people have a boot stick for UEFI that'll work with software raid. Yet, the most majority of people just use hardware RAID and have no problem with UEFI.

You can use this as a workaround with another drive.
https://pve.proxmox.com/wiki/Booting_a_ZFS_root_file_system_via_UEFI
 
Hi again;

I understand UEFI is more an micro program related to the motherboard and GTP is more related to the partitions table but even I force Legacy Boot into the BIOS
IMG_20190526_212502~2.jpg

The UEFI seams to be deeply implemented
IMG_20190526_212605~2.jpg

How i could enforce Proxmox to boot on non UEFI mode ?

PS I just install proxmox to be sure it will end with UEFI and the EF partition has been created by the installation

IMG_20190526_212605~2.jpg
 

Attachments

  • IMG_20190526_215502.jpg
    IMG_20190526_215502.jpg
    332.5 KB · Views: 12
Last edited:
How i could enforce Proxmox to boot on non UEFI mode ?

You cannot, this is the job of the BIOS.

If you choose UEFI on a legacy install, it won't work. Same is true for UEFI install on legacy bios. It has to match, so if you've installed in UEFI mode, you won't be able to force it into legacy. At least not without a tremendous amount of work if you're not familiar with the internals how booting in Linux works. Best and for almost all people fastest method would be to reinstall using legacy mode.
 
@LnxBil thank for your thought and support

Sadly I don't really know how I result with this
but when I dpkg-reconfigure grub-pc
the line command is : root=ZFS=rpool/ROOT/pve-1 boot=zfs
and Grub is marked as installed on my 2 SATA drives.

while when I gdisk /dev/sdb and sdc which are the SATA
I still have
  • EF02 which I believe being the EFI partition
  • EF00 which I believe being the boot partition
  • BF01
So at the end the result is there ;)
 

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!