Joel Sing <j...@sing.id.au> writes:

> On Friday 06 January 2017 12:24:02 Timo Myyrä wrote:
>> And found it. Seems the efi partitions boot loader isn't updated.
>
> It should be - `installboot -r /mnt ${disk}` is run at the end of the
upgrade.
>
>> Manually copying the efi bootloader fixed the boot:
>> https://blog.jasper.la/openbsd-uefi-bootloader-howto/
>>
>> Why isn't the installer handling this?
>
> I cannot immediately see any reason why it should not be, but I do not have
a
> GPT machine available to test/verify - I presume there are no failures
> reported towards the end of the upgrade?
>
> Can you try running `installboot -v` against the softraid volume?
>
> If that works, can you boot bsd.rd, drop into a shell, mount the root volume
> on /mnt, then run `installboot -v -r /mnt` against the root disk?

Upgrades have seem to been successful when I've done them. I've used the
normal,
boot bsd.rd, do upgrade cycle for a while and haven't noticed any errors.

Here's the output of installboot on running system:
$ doas installboot -v sd1
Using / as root
installing bootstrap on /dev/rsd1c
using first-stage /usr/mdec/biosboot, second-stage /usr/mdec/boot
sd1: softraid volume with 1 disk(s)
sd1: installing boot loader on softraid volume
/usr/mdec/boot is 6 blocks x 16384 bytes
sd0a: installing boot blocks on /dev/rsd0c, part offset 1104
master boot record (MBR) at sector 0
        partition 0: type 0xEF offset 64 size 960
        partition 3: type 0xA6 offset 1024 size 1000205876
/usr/mdec/biosboot will be written at sector 1024

and heres from bsd.rd shell:
Using /mnt as root
installing bootstrap on /dev/rsd1c
using first-stage /mnt/usr/mdec/biosboot, second-stage /mnt/usr/mdec/boot
sd1: softraid volume with 1 disk(s)
sd1: installing boot loader on softraid volume
/mnt/usr/mdec/boot is 6 blocks x 16384 bytes
sd0a: installing boot blocks on /dev/rsd0c, part offset 1104
master boot record (MBR) at sector 0
        partition 0: type 0xEF offset 64 size 960
        partition 3: type 0xA6 offset 1024 size 1000205876
/mnt/usr/mdec/biosboot will be written at sector 1024

Looking at the output it seems to just copy the regular boot files and skips
processing EFI stuff. And as the system boots with EFI it uses the old
bootloader and hence the problems with opening the crypto volume.

Should there be check to see if the booted device has i partition with efi
folder and copy the EFI bootloader in that case?

In any case, I have following options on BIOS if they have any relation to
this:
UEFI/Legacy boot: UEFI only
  CMS Support: yes

Timo

Reply via email to