Clone a Hard Drive Using an Ubuntu Live CD
- by Trevor Bekolay
Whether you’re setting up multiple computers or doing a full backup, cloning hard drives is a common maintenance task. Don’t bother burning a new boot CD or paying for new software – you can do it easily with your Ubuntu Live CD.
Not only can you do this with your Ubuntu Live CD, you can do it right out of the box – no additional software needed! The program we’ll use is called dd, and it’s included with pretty much all Linux distributions. dd is a utility used to do low-level copying – rather than working with files, it works directly on the raw data on a storage device.
Note: dd gets a bad rap, because like many other Linux utilities, if misused it can be very destructive. If you’re not sure what you’re doing, you can easily wipe out an entire hard drive, in an unrecoverable way.
Of course, the flip side of that is that dd is extremely powerful, and can do very complex tasks with little user effort. If you’re careful, and follow these instructions closely, you can clone your hard drive with one command.
We’re going to take a small hard drive that we’ve been using and copy it to a new hard drive, which hasn’t been formatted yet.
To make sure that we’re working with the right drives, we’ll open up a terminal (Applications > Accessories > Terminal) and enter in the following command
sudo fdisk –l
We have two small drives, /dev/sda, which has two partitions, and /dev/sdc, which is completely unformatted. We want to copy the data from /dev/sda to /dev/sdc.
Note: while you can copy a smaller drive to a larger one, you can’t copy a larger drive to a smaller one with the method described below.
Now the fun part: using dd. The invocation we’ll use is:
sudo dd if=/dev/sda of=/dev/sdc
In this case, we’re telling dd that the input file (“if”) is /dev/sda, and the output file (“of”) is /dev/sdc. If your drives are quite large, this can take some time, but in our case it took just less than a minute.
If we do sudo fdisk –l again, we can see that, despite not formatting /dev/sdc at all, it now has the same partitions as /dev/sda.
Additionally, if we mount all of the partitions, we can see that all of the data on /dev/sdc is now the same as on /dev/sda.
Note: you may have to restart your computer to be able to mount the newly cloned drive.
And that’s it…If you exercise caution and make sure that you’re using the right drives as the input file and output file, dd isn’t anything to be scared of. Unlike other utilities, dd copies absolutely everything from one drive to another – that means that you can even recover files deleted from the original drive in the clone!
Similar Articles
Productive Geek Tips
Reset Your Ubuntu Password Easily from the Live CDHow to Browse Without a Trace with an Ubuntu Live CDRecover Deleted Files on an NTFS Hard Drive from a Ubuntu Live CDCreate a Bootable Ubuntu 9.10 USB Flash DriveWipe, Delete, and Securely Destroy Your Hard Drive’s Data the Easy Way
TouchFreeze Alternative in AutoHotkey
The Icy Undertow Desktop
Windows Home Server – Backup to LAN
The Clear & Clean Desktop
Use This Bookmarklet to Easily Get Albums
Use AutoHotkey to Assign a Hotkey to a Specific Window
Latest Software Reviews
Tinyhacker Random Tips
Xobni Plus for Outlook
All My Movies 5.9
CloudBerry Online Backup 1.5 for Windows Home Server
Snagit 10
Windows Media Player Glass Icons (icons we like)
How to Forecast Weather, without Gadgets
Outlook Tools, one stop tweaking for any Outlook version
Zoofs, find the most popular tweeted YouTube videos
Video preview of new Windows Live Essentials
21 Cursor Packs for XP, Vista & 7