[parted-devel] Trying to figure out whats going wrong with sun disk label (off by one?)

Phillip Susi psusi at ubuntu.com
Wed Oct 31 20:59:59 UTC 2012


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 10/30/2012 8:15 AM, Bryce wrote:
> Partition alignment seems to be set for cylinder boundry's so
> sectors * heads (255 * 63 = 16065 but is this not wrong since
> sector and head 0 exist so the math should work out as 256*64 =
> 16384 instead? or am I the victim of lack of sleep? (technically I
> guess LBA drives logically don't give a damn)

There are 63 sectors, numbered 0-62, thus a cylinder is 63 * 255 sectors.

> Similarly the python call to 
> optimumAlignment.intersect(disk.partitionAlignment) is WAAAAAAAY
> out of whack being some weird 15.68 *GB* interval, which seems to
> be the cylinder boundry * 2048. What the correct math for that
> should be I'm unclear on. I think the code is trying to find the
> least common multiple which would spilt out that value. If so the
> LCM would be 16384 (16Mb) which would be significantly more sane.
> I'd just like to confirm that this is the source of the wild values
> I'm getting and that fixing the math would fix the issue so that
> I'm not trashing some other consideration I'm being ignorant of.

The math looks correct to me, the question is why are you trying to
align *both* to a cylinder boundary *and* to a MiB boundary?



-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iQEcBAEBAgAGBQJQkZFPAAoJEJrBOlT6nu754NAH/0/9Z92mACl7Et63h0JAiLNi
JKP+8SPUBNVIqXKICYlZRD+32VPpa/kNWF7//n5XgLlfLP8hzGDDtgzz9oW1g6Jr
UhN51iEW86m6/BpENcwSQ7UxrptJqxQmE9PerCfcuo42a7n37wJ2gElq5sAjUaEK
Qc6fT+SvYNdRGyGF71ZygGPbu0cyLHQ3Uu2pfWCCCKcpOY9r350DspTsRcyHt5C9
N6BVjo+MBsfEjh7ZjhWzfakFVZxHHETvnbloKeUqYQjLthraCg8Cj+9wQydnnWzg
OFynRDvCYT+YwmGSexvr5ewsC1MtHyfdvzkrnGq1MSWmM+VVoxXWnCLdm5qdbCA=
=aDvs
-----END PGP SIGNATURE-----



More information about the parted-devel mailing list