Hello. Help me please.
I'm installed FreeBSD 7.3-Release using 2 SATA 1TB disks, how described there
ad5 and ad6
MBR \ boot on UFS + root on ZFS
I'm have same bsdlabel on two disks:
a: -> for /bootdir ( /boot on ZFS links to -> bootdir/boot on UFS)
d: -> for ZFS
and mirrored one to other
/etc/fstab on root ZFS:
If ad6 fails - machine can boot and work online, but if ad5 fails... because this:
i'm need login to machine directly and change /dev/ad5s1a to /dev/ad6s1a in /etc/fstab to get machine back online...
The question is how change this automatically if ad5s1a or ad5 dont exists in /dev/ ?
I'm installed FreeBSD 7.3-Release using 2 SATA 1TB disks, how described there
ad5 and ad6
MBR \ boot on UFS + root on ZFS
I'm have same bsdlabel on two disks:
Code:
8 partitions:
# size offset fstype [fsize bsize bps/cpg]
a: 2097152 0 4.2BSD 4096 16384 8
b: 8388608 2097152 swap
c: 1953525105 0 unused 0 0 # "raw" part, don't edit
d: 1943039345 10485760 4.2BSD 0 0 0
a: -> for /bootdir ( /boot on ZFS links to -> bootdir/boot on UFS)
d: -> for ZFS
and mirrored one to other
Code:
$ zpool status
pool: tank
state: ONLINE
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
tank ONLINE 0 0 0
mirror ONLINE 0 0 0
ad6s1d ONLINE 0 0 0
ad5s1d ONLINE 0 0 0
errors: No known data errors
/etc/fstab on root ZFS:
Code:
$ cat /etc/fstab
# Device Mountpoint FStype Options Dump Pass#
/dev/mirror/swap none swap sw 0 0
/dev/ad5s1a /bootdir ufs rw 1 0
/dev/ad6s1a /mnt/bootdir ufs rw 1 0
/dev/acd0 /cdrom cd9660 ro,noauto 0 0
Code:
$ cat /boot/loader.conf
geom_mirror_load="YES"
zfs_load="YES"
vfs.root.mountfrom="zfs:tank/root"
Code:
$ mount
tank/root on / (zfs, local)
devfs on /dev (devfs, local)
/dev/ad5s1a on /bootdir (ufs, local)
/dev/ad6s1a on /mnt/bootdir (ufs, local)
tank/jails on /jails (zfs, local)
tank/jails/ftp on /jails/ftp (zfs, local)
tank/jails/mail on /jails/mail (zfs, local)
tank/jails/www on /jails/www (zfs, local)
tank/tmp on /tmp (zfs, local)
tank/usr on /usr (zfs, local)
tank/var on /var (zfs, local)
/usr/ports on /jails/www/usr/ports (nullfs, local, noatime)
/usr/src on /jails/www/usr/src (nullfs, local, noatime, read-only)
devfs on /jails/www/dev (devfs, local)
/usr/ports on /jails/mail/usr/ports (nullfs, local, noatime)
/usr/src on /jails/mail/usr/src (nullfs, local, noatime, read-only)
devfs on /jails/mail/dev (devfs, local)
/usr/ports on /jails/ftp/usr/ports (nullfs, local, noatime)
/usr/src on /jails/ftp/usr/src (nullfs, local, noatime, read-only)
devfs on /jails/ftp/dev (devfs, local)
If ad6 fails - machine can boot and work online, but if ad5 fails... because this:
Code:
/dev/ad5s1a /bootdir ufs rw 1 0
The question is how change this automatically if ad5s1a or ad5 dont exists in /dev/ ?