root@router:~ # zpool upgrade zrootThis system supports ZFS pool feature flags.Enabled the following features on 'zroot': userobj_accounting encryption project_quota allocation_classes resilver_defer bookmark_v2 redaction_bookmarks redacted_datasets bookmark_written log_spacemap livelist device_rebuild zstd_compress draidPool 'zroot' has the bootfs property set, you might need to updatethe boot code. See gptzfsboot and loader.efi for details.
I am running the latest Opnsense and decided to run zpool upgrade. Here was the result:Quoteroot@router:~ # zpool upgrade zrootThis system supports ZFS pool feature flags.Enabled the following features on 'zroot': userobj_accounting encryption project_quota allocation_classes resilver_defer bookmark_v2 redaction_bookmarks redacted_datasets bookmark_written log_spacemap livelist device_rebuild zstd_compress draidPool 'zroot' has the bootfs property set, you might need to updatethe boot code. See gptzfsboot and loader.efi for details.Is there anything I need to do, or can I reboot? I am worried that I'm going to brick my opnsense install by not updating "the boot code".
# zpool upgrade zrootThis system supports ZFS pool feature flags.Enabled the following features on 'zroot': edonr zilsaxattr head_errlog blake3 block_cloning vdev_zaps_v2Pool 'zroot' has the bootfs property set, you might need to updatethe boot code. See gptzfsboot(8) and loader.efi(8) for details.
cp /boot/loader.efi /boot/efi/efi/boot/bootx64.eficp /boot/loader.efi /boot/efi/efi/freebsd/loader.efi
gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 2 da0
If the worst has happened and your system does not boot any more, you can either reinstall OpnSense from scratch or create a FAT32/VFAT USB stick with a correct loader.efi and copy that to the EFI partition into the correct locations (this is tedious, however). IDK how to fix it with BIOS boot.
mount -t msdosfs /dev/da0p1 /mntcp /boot/loader.efi /mnt/efi/boot/bootx64.eficp /boot/loader.efi /mnt/efi/freebsd/loader.efiumount /mnt
Quote from: meyergru on August 05, 2024, 07:19:18 pmIf the worst has happened and your system does not boot any more, you can either reinstall OpnSense from scratch or create a FAT32/VFAT USB stick with a correct loader.efi and copy that to the EFI partition into the correct locations (this is tedious, however). IDK how to fix it with BIOS boot.Boot a FreeBSD 14.1 CD/DVD image, escape to shell, use the same gpart command you gave above to install the boot loader.Similar for EFI:Code: [Select]mount -t msdosfs /dev/da0p1 /mntcp /boot/loader.efi /mnt/efi/boot/bootx64.eficp /boot/loader.efi /mnt/efi/freebsd/loader.efiumount /mnt
I opened a feature request, although I know it was my own fault...
I for one like that the images provided by OPN have both EFI and legacy BIOS so a single download/image can be used on either type of system. That said, I agree a documentation could be enhanced to better inform, because it is very true that once installed, it's hard to know in an emergency and needs to update both. I suppose the alternative to provide each image X 2, one for BIOS and one for EFI could deal with it in another way.
But just for good measure, I would always update both types.