Date: Sat, 28 Jul 2007 01:26:44 -0300 From: "Fernan Aguero" <fernan.aguero@gmail.com> To: freebsd-geom@freebsd.org Subject: boot from second disk (gmirror device) ... problems Message-ID: <520894aa0707272126g42b88d41q95477f2d1dd3689b@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hi I'm using geom mirror on several FreeBSD boxes. It's been some time since I've set these up, but I remember being bitten by this problem several times: the problem? booting from the second disk after setting it as the first member of a geom mirror pair. I've always followed more or less Ralf's guide http://people.freebsd.org/~rse/mirror/ (I say more or less because I usually mirror the second slice of my disks) But I always end up getting trouble booting from the second disk. (need to have to have physical access to the box). In the previous incantation of Ralf's guide, he suggested booting from the second disk like this: echo "1:ad(1,a)/boot/loader" >/boot.config Now, he replaced this in the new version of the guide by this: echo $d2 | sed -e 's;^\([^0-9]*\)\([0-9][0-9]*\)$;1:\1(\2,a)/boot/loader;' \ >/boot.config where $d2 is the second disk (ad2 in my case), and this is the resulting /boot.config: 1:ad(2,a)/boot/loader After setting up /etc/fstab and /boot/loader.conf in my /dev/mirror/gm0a partition rebooting brings me to the boot loader prompt because: 1:ad(2,a)/boot/loader is not a valid label or /boot/loader does not exist I've tried several combinations, blindly trying to spot the correct one: 1:ad(1,a)/boot/loader 1:ad(0,a)/boot/loader To no avail. However, 0:ad(0,a) or 0:ad(1,a) allowed me to boot from my ad0 (first) disk (i.e. not the gmirror device) What's the right incantation to boot from the second disk? I've already read boot(8) many times, and can't seem to figure out why 1:ad(1,a) doesn't work bios_drive: 1 (second drive) interface: ad unit: 1 (second drive) slice: a Thanks in advance for any tip or suggestion, Fernan PS: my disks are ad0 (at ata0-master) and ad2 (at ata1-master). ad2s1 (single slice) is the first member of the gm0 gmirror gm0a is the partition containing the bootable (active) partition -- fernan
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?520894aa0707272126g42b88d41q95477f2d1dd3689b>