How to clone a drive from the Linux command line

883

Cloning a drive in Linux actually isn’t too terribly difficult–especially if you’re comfortable with the Linux command line interface. But how do you do it? First you’ll need a bootable ISO image, of just about any Linux distribution, on a flash drive. You’ll also need a new drive to clone to. That target drive must be as big or bjgger than the drive you’re cloning. I prefer to go with bigger, just to be safe.

Once you have all of that ready, boot the machine with the source drive, using the bootable Linux distribution. Once you’ve logged in, make sure to attach the target drive to the system and find out where the target drive is located with the command:
cat /proc/partitions

You should see a listing of all available drives, but they shouldn’t be mounted. You’ll need the name of the source and target drives.

[Source: TechRepublic]