[parted-devel] [PATCH 6/6] libparted: fix optimal IO alignment

Phillip Susi psusi at ubuntu.com
Fri Dec 21 15:25:36 UTC 2012


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

On 12/21/2012 7:15 AM, John Gilmore wrote:
> There are very good reasons to copy entire partitions.  Such as
> making a backup copy of a damaged partition before attempting to
> repair it. Or copying an entire partition off of a disk that's
> giving SMART warnings or otherwise showing imminent signs of
> failure.  Frequently these very good reasons occur in the middle of
> a system administration

Under such circumstances, one doesn't care about optimal IO alignment.

> crisis -- at the wrong time for some self-appointed expert halfway 
> across the Internet to have built the software so that it won't do 
> what the sysadmin asks it to because "people really shouldn't be
> doing that".

Nobody is talking about making software not do anything.

> Copying entire devices is similar to copying partitions --
> especially for single-partition devices, which are very common --
> and should be equally well supported.

If you can dd the whole disk, it's not any harder to dd the partition
after partitioning the new disk with proper alignment.  There really
isn't any need for them both to use an artificially high common alignment.

If people really want a 1MiB alignment mode, I'm not opposed to it,
but it should not be confused with optimal mode.

>> Trying to do this with a disk with mdraid or lvm partitions on it
>> will really confuse the hell out of mdadm/lvm.
> 
> Sounds like a bug in mdadm and lvm.  They should at least ignore 
> duplicate partitions, rather than getting confused.  But they are
> a minor part of the market (most devices don't contain any mdraid
> or lvm partitions), so we shouldn't let this bug control what we do
> for devices in general.

How do you tell which one is the duplicate?  You can't, hence the
confusion.  You run into the same problem with simple disks and
filesystem UUIDs.  They are supposed to be unique, and you break that
assumption when you dd.


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

iQEcBAEBAgAGBQJQ1H9wAAoJEJrBOlT6nu756JYH/0nfGoxf15pu1QA6vhbmXijQ
ko/IWxaf/XWCISOLc9Uo19Ekz0UY3nCqK5tnO+VM7YkNqDa5SFZ6pFitqME9Hh/O
fEi+3YbAOtaleFfMDjt1z4yjBFE4fBxeq4/dDwZu4+2Li/YXL0SXJlm56HXLz/7A
os/pzxuJB42XyX9m17ZaQKOY7fvnGyzr6jgjwYxVarLA78tvEIuaSXYL6XZ08YvU
+rOT98CvU8AaCRjCrfkUWsiS1Z1KpEbVOQ48Pw30g0RtwMDZd7kZB1wfprqR8Stn
yKP48e0oMDIaLbxtsD1CPbfcPqCP6zelzju25EGExVV5pyU0JIFiOr8ITN92Lwo=
=G0AV
-----END PGP SIGNATURE-----



More information about the parted-devel mailing list