Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 May 2011 10:31:38 +0400
From:      "Andrey V. Elsukov" <bu7cher@yandex.ru>
To:        Brandon Gooch <jamesbrandongooch@gmail.com>
Cc:        "Andrey V. Elsukov" <ae@freebsd.org>, Marcel Moolenaar <marcel@FreeBSD.org>, freebsd-geom@FreeBSD.org
Subject:   Re: SVN r221788: GEOM_PART: integrity check failed (da0, MBR); Western Digital "My Book"
Message-ID:  <4DD0C4CA.6040604@yandex.ru>
In-Reply-To: <BANLkTi=L0-0vJftwDgvLG=P5epxGrBknKw@mail.gmail.com>
References:  <BANLkTim6d96Nrg%2Bayu5LF_vOEDguZN0TFg@mail.gmail.com>	<4DD0A7A3.6020002@FreeBSD.org>	<BANLkTinCRKXTYFg5Sy_uTE_TwX8kdLsi8g@mail.gmail.com>	<4DD0B274.8080209@FreeBSD.org> <BANLkTi=L0-0vJftwDgvLG=P5epxGrBknKw@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enig7C84C65D30DE91B44A7A4151
Content-Type: text/plain; charset=KOI8-R
Content-Transfer-Encoding: quoted-printable

On 16.05.2011 9:35, Brandon Gooch wrote:
> Woah. OK, so:
>=20
> $ sudo geom disk list da0
> Geom name: da0
> Providers:
> 1. Name: da0
>    Mediasize: 2000365289472 (1.8T)
>    Sectorsize: 512
>    Mode: r0w0e0
>    descr: WD My Book 1130
>    ident: 5743415A4134343831393132
>    fwsectors: 63
>    fwheads: 255
>=20
> Not seeing much from this. What exactly do you mean by the partition
> being "out of bounds"? Do you mean that the partition has been
> configured to be larger than the actual size of the disk?

So, i reproduce your problem:
# dd if=3D/dev/zero of=3D./disk oseek=3D3906963455 count=3D1
# mdconfig -f ./disk
# dd if=3D./mbr of=3D/dev/md0
# geom md list
Geom name: md0
Providers:
1. Name: md0
   Mediasize: 2000365289472 (1.8T)
   Sectorsize: 512
   Mode: r0w0e0
   file: /usr/home/devel/disk
   type: vnode
   length: 2000365289472
   fwsectors: 0
   fwheads: 0
   unit: 0

Your disk has mediasize =3D 2000365289472 bytes.
This is 2000365289472/512 =3D 3906963456 sectors.
This means that the first usable sector is 0 and
the last =3D 3906963456 - 1 =3D 3906963455.

But MBR does recalculation of available space and
aligns it to SectorsPerTrack:
last =3D 3906963456 - (3906963456 % 63) - 1 =3D 3906963395 sectors.

This value is smaller than value specified in MBR and integrity
check fails.

#gpart list md0
Geom name: md0
modified: false
state: CORRUPT
fwheads: 255
fwsectors: 63
>>>>>>>>>last: 3906963395
>>>>>>>>>first: 63
entries: 4
scheme: MBR
Providers:
1. Name: md0s1
   Mediasize: 2000364240896 (1.8T)
   Sectorsize: 512
   Mode: r0w0e0
   rawtype: 7
   length: 2000364240896
   offset: 1048576
   type: ntfs
   index: 1
>>>>>>>>>   end: 3906963455
>>>>>>>>>   start: 2048
Consumers:
1. Name: md0
   Mediasize: 2000365289472 (1.8T)
   Sectorsize: 512
   Mode: r0w0e0

--=20
WBR, Andrey V. Elsukov


--------------enig7C84C65D30DE91B44A7A4151
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)

iQEcBAEBAgAGBQJN0MTOAAoJEAHF6gQQyKF6o9cIAIs9HPocqS3vihL/0g71OMYM
QrW9EJeCqGLQIExJwwVV6FaKUVn1vStdCe4hc9iYl+DAAPH9pixKtJc0mCirbTCr
4imGkwSx8cWhgRdZKsFrPEOtCtTnFwYMr7rNML8sTUkib8MvSp2pdaCdIrI04BLm
uzGZ12IuV3MB+OTTOb4/OXoTitycQpwWoMoQtl0W3HeqihR0Ebl7eTUxO6wlCBI2
Oze60f+apWYr7lxPYEa/WoXIkaLyA7HtPd30OtvEZ5T9pV++DGK+B0/eSZ0mNQAR
F2t59JmZ+arnQkIzgqyMjwtsqxCo2bLJHs1SKmo+JJxp/pV1MQXtgUISfoGipvc=
=6d0B
-----END PGP SIGNATURE-----

--------------enig7C84C65D30DE91B44A7A4151--



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