gmirror on a slice uncertainty
Harry Newton
hn+freebsd at yewbarrow.net
Fri Jun 29 14:20:23 UTC 2007
I've just set up a GEOM gmirror on two slices on two disks, and would
very much appreciate it if someone could validate what I've
done. General information below and questions at end. This might just
be motivated by paranoia on my part ...
Many thanks in advance
- Harry
Background:
- FreeBSD 6.2-STABLE
- AMD64 & Two (2) 340GB SATA II disks
What I want to do:
- Create two slices on each disk (20GB + 284GB)
- / /usr /usr/src /usr/ports SWAP on first disk (/dev/ad4s1)
- /rii /home /usr/obj /usr/local SWAP on second disk (/dev/ad6s1)
- use gmirror(8) to use ad4s2 and ad6s2 to provide /dev/mirror/home
What I did:
- use sysinstall(8) to create the slices:
hydra# fdisk -vp ad4
# /dev/ad4
g c620181 h16 s63
p 1 0xa5 63 41929587
a 1
p 2 0xa5 41929650 583207695
- and partition ad4s1 and ad6s1:
hydra# bsdlabel ad4s1
# /dev/ad4s1:
8 partitions:
# size offset fstype [fsize bsize bps/cpg]
a: 2097152 0 4.2BSD 2048 16384 28528
b: 4194304 2097152 swap
c: 41929587 0 unused 0 0 # "raw" part,
don't edit
d: 10485760 6291456 4.2BSD 2048 16384 28528
e: 4194304 16777216 4.2BSD 2048 16384 28528
f: 20958067 20971520 4.2BSD 2048 16384 28528
- and the same for the other disk. Install FreeBSD.
- then:
gmirror label -v -n home ad4s2
gmirror load
bsdlabel -w -B /dev/mirror/home
gmirror insert home ad6s2
gmirror rebuild -v home ad6s2
What's concerning me ?
- this error message about partition c:
hydra# bsdlabel ad6s2
# /dev/ad6s2:
8 partitions:
# size offset fstype [fsize bsize bps/cpg]
a: 583207678 16 4.2BSD 2048 16384 28520
c: 583207694 0 unused 0 0 # "raw" part,
don't edit
bsdlabel: partition c doesn't cover the whole unit!
bsdlabel: An incorrect partition c may cause problems for standard
system utilities
- which I get on ad4s2 but not on the provided mirror:
hydra# bsdlabel /dev/mirror/home
# /dev/mirror/home:
8 partitions:
# size offset fstype [fsize bsize bps/cpg]
a: 583207678 16 4.2BSD 2048 16384 28520
c: 583207694 0 unused 0 0 # "raw" part,
don't edit
- and this line in /var/log/messages:
WARNING: Expected rawoffset 0, found 41929650
So, what am I asking ?
- have I set up the mirror etc correctly ?
- what is causing the bsdlabel error messages on slice 2 ?
More information about the freebsd-geom
mailing list