gmirror on slices & glabel mess
Lev Serebryakov
lev at serebryakov.spb.ru
Thu Jan 13 19:49:38 UTC 2011
Hello, Freebsd-geom.
I have two identical HDDs with one slice on each -- ad4s1 & ad6s1.
These two slices have identical labels:
rescue# bsdlabel ad4s1
# size offset fstype [fsize bsize bps/cpg]
a: 4194304 16 4.2BSD 0 0 0
b: 33554432 4194320 swap
c: 1465149105 0 unused 0 0 # "raw" part, don't edit
d: 33554432 37748752 4.2BSD 0 0 0
e: 2097152 71303184 4.2BSD 0 0 0
f: 134217728 73400336 4.2BSD 0 0 0
g: 209715200 207618064 4.2BSD 0 0 0
h: 1047815841 417333264 4.2BSD 0 0 0
rescue# bsdlabel ad6s
# size offset fstype [fsize bsize bps/cpg]
a: 4194304 16 4.2BSD 0 0 0
b: 33554432 4194320 swap
c: 1465149105 0 unused 0 0 # "raw" part, don't edit
d: 33554432 37748752 4.2BSD 0 0 0
e: 2097152 71303184 4.2BSD 0 0 0
f: 134217728 73400336 4.2BSD 0 0 0
g: 209715200 207618064 4.2BSD 0 0 0
h: 1047815841 417333264 4.2BSD 0 0 0
All partitions but "b" are groupd to form mirrors with names
rootfs, var, tmp, usr, databases, home respectively.
File systems with labels are created on each mirror device. Labels
are the same as mirror device names.
When system boots WITHOUT geom_mirror loaded (rescue system)
"geom_label" sees LAST fs (home):
rescue# ls /dev/ufs
home
rescue#
If geom_mirror is loaded, it adds "/dev/ufs/home" instead of
"/dev/ad4s1h" and filesystem CAN NOT BE MOUNTED from "/dev/ufs/home".
It is 100% reproducible on virtual machine (With much smaller
virtual disks, than my example).
--
// Black Lion AKA Lev Serebryakov <lev at serebryakov.spb.ru>
More information about the freebsd-geom
mailing list