Sunday, November 4, 2012

How To Clone And Backup Your Hard Disks/USB Drives/CDs & DVDs In Ubuntu 12.10/12.04/Linux Mint 13


In this tutorial, we will see how to clone hard disks, USB keys, CDs/DVDs, etc. in a system running Ubuntu/Linux Mint. There are many tools for copying data under Ubuntu, but in this article we will see only two.

1. Mondo Rescue

Mondo Rescue is a command line utility that allows users to backup/restore from/to hard disk partitions, usb flash drives, CD-R/RW disks, DVD disks, etc. To install Mondo Rescue in Ubuntu 12.10/12.04 or Linux Mint 13, open the terminal and run these commands:


wget ftp://ftp.mondorescue.org/ubuntu/`lsb_release -r|awk '{print $2}'`/mondorescue.sources.list
sudo sh -c "cat mondorescue.sources.list >> /etc/apt/sources.list" 
sudo apt-get update 
sudo apt-get install mondo

To start it, run this command:

sudo mondoarchive

Select now the media where you want to store your data:


Then follow backup instructions.

2. Clone Disks with the DD Command

You can also use the dd command line utility to backup your disks. Here are some examples:

- To clone a partition to another parition, use this command:

dd if=/dev/sda1 of=/dev/sda2 bs=4096 conv=noerror

- To copy a whole disk to another disk, use this command:

dd if=/dev/sda1 of=/dev/sda3 bs=1M conv=noerror

- If you want to copy your partition to an image file, use this command:

dd if=/dev/sda2 of=/path/to/backup-file.iso bs=4096 conv=noerror

- To copy a CD, run this command:

dd if=/dev/cdrom of=/path/to/backup-file.iso

- To copy a DVD, use this command:

dd if=/dev/dvd of=/path/to/backup-file.iso

No comments:

Post a Comment