would like to have generic method to install bootblock with bootadm tool to manage bootblocks in generic way without having to deal with details like bootblock locations and device names. So the idea is extend the option list as:
bootadm install-bootloader [-Mfv] [-R altroot] [-P pool]
-M is to install stage1 in MBR (applies on x86 and not on sparc)
-f is to force bootblock install to ignore bootblock versioning
-v for verbose mode
-R altroot to specify alternate root BE to read bootblocks from, if not specified, the current next boot BE is used (from pool bootfs property).
-P pool to specify target zfs pool to install to. If pool is not specified, the default boot pool is used.
Since normal procedure is to install bootblocks on all devices in pool, we let bootadm to manage individual disk devices in pool in order to make sure all devices have same version of bootloader and therefore this command would not need disk device list as optional arguments. If for some reason there is need to install bootblock on specific device only, the installgrub/installboot command can be used instead of bootadm. Also note, as beadm activate does also install/update bootblocks, this command can be redundant or conflicting with beadm - if the intention is to "downgrade" bootblocks, beadm activate should be run first (if needed), followed by bootadm install-bootloader, to make sure the intended version of bootblocks are installed.
Updated by Electric Monk over 5 years ago
- Status changed from In Progress to Closed
commit c7c0ceafd167e558cd8cb8195b8bd63cbc817b27 Author: Toomas Soome <email@example.com> Date: 2015-09-16T17:40:48.000Z 6085 export libbe installboot function 6086 add install bootblock option for bootadm Reviewed by: Igor Kozhukhov <firstname.lastname@example.org> Reviewed by: Adam Števko <email@example.com> Reviewed by: Josef Sipek <firstname.lastname@example.org> Approved by: Robert Mustacchi <email@example.com>