Project

General

Profile

Actions

Bug #7854

closed

installboot should set MBR to load partition boot block if it was installed

Added by Toomas Soome over 5 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
cmd - userland programs
Start date:
2017-02-12
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

installboot does install the MBR and partition boot block - 512B simple boot program, designed to load and start the actual boot2 program (gptzfsboot). installboot does record the starting LBA and the size in sectors of the boot2 into MBR block.

The problem is that if in case the MBR block (absolute sector 0) was not updated and the boot2 size is increased compared to previously installed boot2, the MBR code will not load whole boot2, resulting boot loader code to fail.

The system can still be booted via chainload from alternate media, but we need better insurance against such cases. The solution is to record in MBR the partition block location and size instead. As partition boot block is always updated, we will have MBR loading PBR and PBR will load boot2 using correct size.

Actions

Also available in: Atom PDF