Cloning hard drive is stressing me out! I need advice
Linux - NewbieThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Cloning hard drive is stressing me out! I need advice
I have never used rsync before, only DD. But from what I have been reading, rsync is better becasue it will basically mirror your hard drive, thus being able to run the cloned software from the new hard drive.
My problem is I do not know what is the best commands or even the basic commands to use in rsync. I am trying to make an image from a external hard drive to a usb drive. That way my chances of messing up he original software is not as risky becasue I'll just restore the image onto another hard drive.
Does anyone know the best script to have rsync make an image file of a hard drive and place it on a usb drive and then restore it?
If I understand you correct you want to make an image of your harddisk to have a backup, right? Rsync is very confusing in my opinion and not my favorite for that kind of job. I imagine you want to compress what you backup into the image in order to be able to put it on a USB drive. Have a look at CloneZilla, that would be a lot easier I think.
Have a look at CloneZilla, that would be a lot easier I think.
Eric
I agree, it is confusing, but i think it will do what i need. i have tried clonzilla, and it copies the files to another hard drive, but the software will not boot on the new hard drive. i have also tried ghost4linux and DD.
I just don't know how to make one hard drive to be an EXACT copy of the original to run the software.
I'm sorry, I understood you wrong. I thought you would use it for backup but it seems you just want an exact copy of your drive. I think dd should do the job. I've only used it on a few occasions and it always worked flawless. Have a look at this site for some pointers and examples.
I am trying to make an image from a external hard drive to a usb drive. That way my chances of messing up he original software is not as risky becasue I'll just restore the image onto another hard drive.
Thank you
Pasquale, I have just had the same problem. I had to move my data, et al, from a 40 gig HD to a new 500 gig drive. I used clonezilla and it is beautiful. I first did a backup to my USB drive, then I cloned the old to the new drive, again using Clonezilla. If you use it, be sure to get the Quick Reference Card & read it thoroughly! It has step by step how to do a CLONE of your old drive. You can move from a small drive to a larger one after using Gparted to partition the new drive the way you want it. Again, RTFI!!! RTFI!! I can't emphasize enough, RTFI!! do it several times before doing anything with the drives. I promise it works like a charm.
Michael
I have a basic script (scheduled as a cron job daily) that backs up my primary drives to a back up drive daily. You can even combine with SSH to do across a network. So I always have a current copy. After a little reading you may find rsync is a very handy tool.
I agree, it is confusing, but i think it will do what i need. i have tried clonzilla, and it copies the files to another hard drive, but the software will not boot on the new hard drive. i have also tried ghost4linux and DD.
I have to say clonezilla works very well for me.
I have cloned disks with it and they boot.
I have retored an image to a different disk & it boots.
The 1 thing I haven't tried is restoring a partition to another disk on a different partition #.
Clonezilla does create a bootable OS.
Another note, to clone or image to usb drive in clonezilla, you can't plug in usb drive until prompted to.
It says plug in device wait 5 seconds, press enter.
Boot to a live-cd, check drive listing with the fdisk -l command, and copy your drive when the drives are not mounted. Where hda and hdb are, you will change to what your drives are listed with fdisk -l.
Code:
dd if=/dev/hda of=/dev/hdb bs=32256
I have copied many smaller drives to a larger drive with dd. When all is complete I then use G-parted to expand the partition of the new drive.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.