How can I force boot from alternate drive with boot.config?

Peter Steele psteele at maxiscale.com
Mon Feb 8 16:25:57 UTC 2010


I've asked this on the -questions list but haven't had any feedback. I have a system configured with multiple identical drives each loaded with FreeBSD. When I was using MBR partitioning, I could create a boot.config to force the system to boot from a specific drive. For example, if I wanted to boot from the second drive, I'd create a boot.config with:



1:ad(1,a)/boot/loader



We've switched to GPT partitioning and I can't seem to find a way to do this same trick. The boot loader only seems to recognize MBR partitions when it comes to this feature. I looked at the boot.c source code and there doesn't seem to be anything specifically related to GPT partitioning. I cannot for example say something like:



1:ad(1,p3)/boot/loader



where p3 is the root partition in my GPT partitioned drives. So I'm puzzled: If I have a two drive system with BSD loaded on both drives and the drives are configured with GPT partitions, how can I force the system to boot from the second drive using boot.config?



More information about the freebsd-hackers mailing list