8.0-BETA1 bsdlabel broken?

John Marshall john.marshall at riverwillow.com.au
Mon Jul 13 05:22:29 UTC 2009


On Sun, 12 Jul 2009, 03:12 +0400, Eygene Ryabinkin wrote:
> OK, changed the patch to make the described checks.  And to fix the error
> with the previous patch -- it will set the offset for writes to zero, so
> it is better to use this patch variant for doing label writes and never
> use the previous one for label modifications.  Though it was doing the
> proper thing for reads.

Thank you!  I applied this patch to bsdlabel.c and now the utility
interprets the labels as expected.

rwsrv05# disklabel /dev/da0s1
# /dev/da0s1:
8 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
  a:  1048576        0    4.2BSD     2048 16384     8 
  b:  8388608  1048576      swap                    
  c: 33543720        0    unused        0     0         # "raw" part, don't edit
  e:  4194304  9437184    4.2BSD     2048 16384 28552 
  f: 19912232 13631488    4.2BSD     2048 16384 28552 

rwsrv05# disklabel /dev/da0s2
# /dev/da0s2:
8 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
  c: 67103505        0    unused        0     0         # "raw" part, don't edit
  d: 33554432        0    4.2BSD     2048 16384 28552 
  e: 33549073 33554432    4.2BSD     2048 16384 28552 

> But anyway, bsdlabel won't let you write the label (old, patched with
> bad patch, patched with the current patch), since it wants to do it via
> the BSD class and our slicer is PART.  Another patch will be submitted ;))

-- 
John Marshall
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-current/attachments/20090713/61c85370/attachment.pgp


More information about the freebsd-current mailing list