Discussion:
Re[2]: Re[2]: Re[2]: Copy bootcode to mirror disk?
(too old to reply)
Warren Block
2016-06-25 02:06:06 UTC
Permalink
https://www.freebsd.org/doc/handbook/geom-mirror.html
# gpart bootcode -b /boot/mbr mirror/gm0
# gpart set -a active -i 1 mirror/gm0
# gpart bootcode -b /boot/boot mirror/gm0s1
That is only valid for a GPT disk. The problem is that the boot
partition is mirrored. The bootcode can probably be written to
mirror/boot.

However, as I said on the forums to this very same thread, the real
error here is having mirrored GPT partitions.
perikillo
2016-06-27 05:56:54 UTC
Permalink
One issue here is that right I cannot sit and change this, will be good to
do that but my time is on other projects now.
Them in my case there is no way to fix this?
https://www.freebsd.org/doc/handbook/geom-mirror.html
Make the mirror bootable by installing bootcode in the MBR and bsdlabel
# gpart bootcode -b /boot/mbr mirror/gm0
# gpart set -a active -i 1 mirror/gm0
# gpart bootcode -b /boot/boot mirror/gm0s1
That is only valid for a GPT disk. The problem is that the boot partition
is mirrored. The bootcode can probably be written to mirror/boot.
However, as I said on the forums to this very same thread, the real error
here is having mirrored GPT partitions.
Warren Block
2016-06-27 14:28:59 UTC
Permalink
Post by perikillo
https://www.freebsd.org/doc/handbook/geom-mirror.html
Make the mirror bootable by installing bootcode in the MBR and bsdlabel
# gpart bootcode -b /boot/mbr mirror/gm0
# gpart set -a active -i 1 mirror/gm0
# gpart bootcode -b /boot/boot mirror/gm0s1
That is only valid for a GPT disk. The problem is that the boot partition
is mirrored. The bootcode can probably be written to mirror/boot.
However, as I said on the forums to this very same thread, the real error
here is having mirrored GPT partitions.
One issue here is that right I cannot sit and change this, will be good to
do that but my time is on other projects now.
Them in my case there is no way to fix this?
(Please don't top-post, it makes replying more difficult.)

First, make a full backup. Seriously.

The temporary way to fix it is to write the bootcode to the boot
partition mirror. gpart might refuse to do that. If it refuses, the
boot partition mirror can be destroyed. The only purpose to have it is
to make sure that bootcode is mirrored, and if it is preventing that, it
is not useful.

After destroying that boot partition mirror, write the bootcode
individually to both drives. Since bootcode rarely changes, this should
be adequate. Of course, the computer must still be able to boot from
either drive, or having bootcode on both does not help much.

Loading...