Best partitioning?

Steffen Kluge kluge at fujitsu.com.au
Fri May 27 00:35:13 UTC 2005


On Thu, 2005-05-26 at 13:06 -0400, Deron Meranda wrote:
> > Would cp /dev/zero /dev/hda do the same thing?
> 
> No.

I wish people would stop saying this. It's not true, cp works just fine
and as expected on devices (as does cat, btw), as long as the device
doesn't require special handling (like CD burners, tapes, etc).

>   cp operates at the filesystem level, while dd operates
> at the device level.

So? Isn't /dev/hda a filesystem object? It can be written to just
like /dev/zero can be read from.

>   cp actually wouldn't work because /dev/hda
> is not a filesystem (although it contains an image of a filesystem
> which you access by mounting it first).

cp doesn't expect filesystems as arguments.

>   Also even if cp could
> work, you still might want to erase the non-filesystem portions
> of your disk (e.g., partition tables, boot blocks, swap partitions,
> LVM structures, etc.)

No. Overwriting /dev/hda clobbers the whole disk, MBR, hook, line and
sinker.

Cheers
Steffen.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20050527/da10a143/attachment-0001.sig>


More information about the fedora-list mailing list