LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-14-2011, 11:35 AM   #1
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Rep: Reputation: 16
Best way to create an image of my hard drive?


I've performed a clean install of Linux on my system, and would like to create a snapshot of my whole disk so that I can go back to a fresh state immediately.

I used to use DriveImage XML and it was a FANTASTIC program, but unfortunately the boot CD containing it can only be created by having Windows installed. So it might be time to explore a new program that is equally simple and effective as that one.

I'd like your recommendations of imaging programs that are free, and that work off a boot CD/DVD (because the live backup thing generally takes much longer for imaging an entire disk).

One thing I liked about DriveImage XML was that it stored the backup in a fairly readable format, so if one day DriveImage XML were no longer available you wouldn't lose your backed up data. Any such programs?

Also, would these programs work for a drive that contains an encrypted root partition (i.e. enabling the encryption checkbox in the CentOS installation)?
 
Old 06-14-2011, 11:44 AM   #2
pentode
Member
 
Registered: Dec 2005
Location: Oregon
Distribution: Debian Testing
Posts: 488

Rep: Reputation: 38
If I understand your question, I think the standard Linux dd command will work. Not sure about the encryption issue.

Have a look here:

http://www.backuphowto.info/linux-ba...-disk-clone-dd
 
Old 06-14-2011, 11:58 AM   #3
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Original Poster
Rep: Reputation: 16
I should have mentioned that those programs also offer the option not of taking a raw dump of the drive, but of copying only the used space. So a 60GB disk with only 12GB used would result in a 12GB image, whereas I think the dd command would result in a 60GB image.
 
Old 06-14-2011, 12:13 PM   #4
travisdh1
Member
 
Registered: Sep 2008
Distribution: Fedora
Posts: 129

Rep: Reputation: 21
Have you looked at clonezilla? It's worked well for me so far in very limited use (one windows machine and one linux machine.)
 
Old 06-14-2011, 12:17 PM   #5
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,979

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
I've recently used Clonezilla to create an image of my Windows 7 Partitions. I created the images on an external harddrive. Afterwards I've repartitioned the disk (where formerly Win7 resided) and installed OpenBSD. Last week I needed Windows 7 again, restored it with Clonezilla and Win7 is running properly now.

I think when it works for Windows it will be also an excellent tool to backup Linux-partitions. I have used the Clonezilla-Live-CD, but there is also an USB-Image available.

Clonezilla works very fast and compresses the files so that free diskspace doesn't use any space on the backup-medium.

Markus
 
Old 06-14-2011, 01:51 PM   #6
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Original Poster
Rep: Reputation: 16
Thanks for the suggestion, I'm looking at clonezilla right now.

Is it correct of me to say that if the drive I'm backing up contains a 100MB boot partition and an 80GB root partition that is ENCRYPTED, then clonezilla won't be able to inspect the filesystem and back up only the used portion? (And for a restore, it won't be able to enter the encryption password if I provide it and backup the image to the encrypted partition.)

Does anyone know of any software that would be able to do this, where it recognizes the Linux encryption and works with it (obviously with a user-supplied password of the encrypted partition)? Because that would be the best of both worlds, where I could continue to have an encrypted partition, but also not have huge drive images that take a very long time to backup and to restore.
 
Old 06-14-2011, 02:02 PM   #7
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,979

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
Quote:
Originally Posted by veeruk101 View Post
Thanks for the suggestion, I'm looking at clonezilla right now.

Is it correct of me to say that if the drive I'm backing up contains a 100MB boot partition and an 80GB root partition that is ENCRYPTED, then clonezilla won't be able to inspect the filesystem and back up only the used portion? (And for a restore, it won't be able to enter the encryption password if I provide it and backup the image to the encrypted partition.)
...
Mh, this is a very special case, if I were you I would try this out on a virtual machine. Look here: http://sourceforge.net/projects/clon.../topic/4406233

Markus
 
Old 06-14-2011, 05:01 PM   #8
jefro
Moderator
 
Registered: Mar 2008
Posts: 15,691

Rep: Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264Reputation: 2264
Clonezilla can clone it based on file by file if it can read or has read support for the filesystem. If not is reverts to dd.
 
Old 06-14-2011, 05:05 PM   #9
frieza
Senior Member
 
Registered: Feb 2002
Location: harvard, il
Distribution: Ubuntu 11.4,DD-WRT micro plus ssh,lfs-6.6,Fedora 15,Fedora 16
Posts: 3,202

Rep: Reputation: 397Reputation: 397Reputation: 397Reputation: 397
yeah i second that on DD, DD is what is referred to as a 'bit copier', it copies the raw partition bit for bit (free space included) irregardless of file system or encryption.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Create image for your hard drive the easy way with Redo Backup and Recovery LXer Syndicated Linux News 0 07-06-2010 05:40 PM
How do I create a drive image in Ubuntu? (I use DriveImageXML in XP) Pebbles01 Linux - Newbie 2 04-24-2009 08:29 AM
Using dd and gzip to create hard drive image but image is bigger than hard drive? banz Linux - Software 3 11-22-2008 05:25 AM
How to create image of NTFS drive? zaoka Linux - Software 1 09-01-2005 06:28 PM
hard drive failing, how can I create an image of my drive? oily_rags SUSE / openSUSE 6 07-07-2005 03:19 PM


All times are GMT -5. The time now is 02:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration