[sf-lug] debian vs ubuntu question
Rick Moen
rick at linuxmafia.com
Sat Feb 16 18:14:01 PST 2019
Quoting Alex Kleider (akleider at sonic.net):
> Assuming (once the live distro is booted) that one can be certain
> that the computer's
> hard drive is /dev/sdb
> and the 'nice large USB external drive' is /dev/sdc
> (and further assuming if any of their partitions are auto mounted
> that they all be first 'umounted')
> would the correct 'dd' command be:
> dd if='/dev/sdb' of='/dev/sdc'
> ?
Yeah, that would work -- and it would be best if the partitions were
unmounted[1] for purposes of any bitwise copy. To speed it up, you would
probably want to crank up dd's the 'bs' (blocksize) value, as otherwise
it'd probably be excruciatingly slow. On that:
http://blog.tdg5.com/tuning-dd-block-size/
In most contexts, I actually actively oppose the idea of bitwise copies,
preferring file-by-file copying, e.g., using rsync. But maybe making a
pristine safety copy of a brand-new partition is a reasonable exception.
[1] Given that you're doing bitwise copying, there's no need to mount
the filesystem in question, so _avoiding_ mounting it is cheap insurance
to ensure that it's quiescent.
More information about the sf-lug
mailing list