[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DD via USB?



"L. V. Lammert" <lvl@omnitec.net> wrote:
> A friend wants to upgrade the HD in his laptop [Windoze]; I
> have a USB drive carrier, but we would need to image the
> drives to preserve the original content.

Consider 2.5" to 3.5" converters and copying the filesystems
_directly_ from old to new inside of another system.  USB
connections are slower.

> Since the driver will be dissimilar size (20G vs. 100G), dd
> won't work, right?

Depends on the geometry.  If both are using the same
sectors/heads, e.g., 63/255, then yes, you can dd the C:
drive as is, and then create a D: drive separately.  You can
also image the MBR with something like "dd if=/dev/hda
of=hda_mbr.dd bs=8225280 count=1 conv=notrunc" (bs=8225280
should be the number of bytes "fdisk -l /dev/hda" reports for
each cylinder -- should be around 8225280 bytes/cylinder for
63/255).

If the drive is FAT, you can use Parted to copy (and image)
the filesystem with a sector by sector copy of _only_ what is
used.  You can restore the MBR with a XP boot CD in rescue
mode and use "fixmbr" (always recommended _instead_ of using
a DOS disk which may have different geometry/support/etc...
issues).

If the drive is NTFS, you can use the LDM tools to copy (and
image) the filesystem with a sector by sector copy of _only_
what is used as well.  Yes, this is completely safe, because
you aren't modifying the filesystem and its file meta-data,
just copying it.

> What's the best approach?

For FAT32, parted is most excellent at direct disk imaging, a
little more work if you want to image to an intermediate
file.

> I assume booting with a Knoppix CD would be a good start,

I use the Fedora Core / RHEL Rescue CDs regularly.

> .. but the copy would also have to include a [modifed] MBR
> with the original boot loader.

If the sector/head geometry matches, you can use the dd
approach above for cylinder 0.  But I'd avoid it if at all
possible.


-- 
Bryan J. Smith     Professional, Technical Annoyance                      b.j.smith@ieee.org      http://thebs413.blogspot.com
----------------------------------------------------
*** Speed doesn't kill, difference in speed does ***

-
To unsubscribe, send email to majordomo@silug.org with
"unsubscribe silug-discuss" in the body.