Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 24 Sep 2004 14:36:27 -0400
From:      Paul Mather <paul@gromit.dlib.vt.edu>
To:        Chris Elsworth <chris@shagged.org>
Cc:        freebsd-geom@freebsd.org
Subject:   Re: WARNING: Expected rawoffset 0, found 63 ?
Message-ID:  <1096050986.9306.72.camel@zappa.Chelsea-Ct.Org>
In-Reply-To: <20040924171810.GA80912@shagged.org>
References:  <20040924160620.GA77997@shagged.org> <1096044939.9306.54.camel@zappa.Chelsea-Ct.Org> <20040924171810.GA80912@shagged.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 2004-09-24 at 13:18, Chris Elsworth wrote:

> At this point, or indeed, even now, if you disklabel -r on your mirror
> device, does it not give you warnings about partition c? If not,
> that's where we start to differ :)

First of all, you should probably get into the habit of using bsdlabel
under 5.x, not disklabel.  (I remember at one point that disklabel used
to complain about that rawoffset difference.)  Perhaps they are exactly
the same nowadays, but at one point they weren't.

Here's what I get when I run disklabel on my mirror:

>>>>>
zappa# disklabel -r /dev/mirror/raid1
# /dev/mirror/raid1:
8 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
  a:   524288        0    4.2BSD     2048 16384 32776 
  b:  2039392   524288      swap                    
  c: 20964760        0    unused        0     0         # "raw" part, don't edit
  d:   524288  2563680    4.2BSD     2048 16384 32776 
  e: 17876792  3087968    4.2BSD     2048 16384 28552 
<<<<<

The only time I get a complaint about partition c is when I run it on
the underlying components (providers).  Then, it complains about it not
covering the whole device, which makes sense because it is picking up a
"ghost" label of the mirror, which is slightly smaller than the
underlying providers because it uses a few sectors from them for its own
metadata.  E.g.:

>>>>>
zappa# disklabel -r /dev/ad1s1
# /dev/ad1s1:
8 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
  a:   524288        0    4.2BSD     2048 16384 32776 
  b:  2039392   524288      swap                    
  c: 20964760        0    unused        0     0         # "raw" part, don't edit
  d:   524288  2563680    4.2BSD     2048 16384 32776 
  e: 17876792  3087968    4.2BSD     2048 16384 28552 
disklabel: partition c doesn't cover the whole unit!
disklabel: An incorrect partition c may cause problems for standard system utilities
zappa# disklabel -r /dev/label/drive1s1
# /dev/label/drive1s1:
8 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
  a:   524288        0    4.2BSD     2048 16384 32776 
  b:  2039392   524288      swap                    
  c: 20964760        0    unused        0     0         # "raw" part, don't edit
  d:   524288  2563680    4.2BSD     2048 16384 32776 
  e: 17876792  3087968    4.2BSD     2048 16384 28552 
disklabel: partition c doesn't cover the whole unit!
disklabel: An incorrect partition c may cause problems for standard system utilities
zappa# gmirror list
Geom name: raid1
State: COMPLETE
Components: 2
Balance: split
Slice: 4096
Flags: NONE
SyncID: 1
ID: 2974744038
Providers:
1. Name: mirror/raid1
   Mediasize: 10733957120 (10.0)
   Sectorsize: 512
   Mode: r4w4e1
Consumers:
1. Name: label/drive0s1
   Mediasize: 10733957632 (10.0)
   Sectorsize: 512
   Mode: r4w4e2
   State: ACTIVE
   Priority: 0
   Flags: DIRTY, HARDCODED
   SyncID: 1
   ID: 3924739636
2. Name: label/drive1s1
   Mediasize: 10733957632 (10.0)
   Sectorsize: 512
   Mode: r4w4e2
   State: ACTIVE
   Priority: 0
   Flags: DIRTY, HARDCODED
   SyncID: 1
   ID: 1083938085

Geom name: raid1.sync

zappa# 
<<<<<

(I get the same results when using bsdlabel instead of disklabel.  Note
how the mediasize of the providers of the mirror is slightly bigger [by
one 512-byte sector] than that of the mirror itself.)

Cheers,

Paul.
-- 
e-mail: paul@gromit.dlib.vt.edu

"Without music to decorate it, time is just a bunch of boring production
 deadlines or dates by which bills must be paid."
        --- Frank Vincent Zappa



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1096050986.9306.72.camel>