View previous topic :: View next topic |
Author |
Message |
proto_culture n00b
Joined: 09 Sep 2002 Posts: 11 Location: Portland. Oregon
|
Posted: Wed Oct 30, 2002 8:04 pm Post subject: cloning gentoo |
|
|
Greetings fellow travelers...
I want to clone my gentoo drive from my primary hard drive to my secondary hard drive located on the same system. I have the information I need to accomplish this, but I thought I would ask around and see if anyone has run into any serious problems or issue's while attempting to accomplish this task.
So...anyone run into any road blocks? Anything I should look out for "gotcha's" and such?
What would be the most common preperations?
thanks everyone!
proto. |
|
Back to top |
|
|
Jester Tux's lil' helper
Joined: 03 Aug 2002 Posts: 128 Location: Nashville, Tennessee
|
Posted: Thu Oct 31, 2002 3:43 pm Post subject: |
|
|
What cloning software are you using? |
|
Back to top |
|
|
slydini Tux's lil' helper
Joined: 30 Oct 2002 Posts: 129 Location: Virginia Beach, VA
|
Posted: Thu Oct 31, 2002 6:15 pm Post subject: |
|
|
Why don't you tell us what cloning method you have already? I have done this in Irix 6.5 by somthing similar to the below:
1. Create new partitions to be >= Source partitions
2. make file system on each new partition
3. make directory to be a temporary mount point: mkdir /clone
4. #mount /dev/hdb3 /clone
5. #cd /clone
6. #dump 0f - / | restore xf -
7. If you have other partitions like /usr then do the same thing for /usr
8. #cd ..
9. #umount /clone
10. #mount /dev/hdb5 /clone
11. #cd /clone
12. #dump 0f - /usr | restore xf -
13. After it finishes #cd ..
14. #umount /clone
15. #rmdir /clone
I am assuming in this case ext2 filesystem and hda3 is your root partition and hda5 is the original /usr partition and your new disk is hdb3 ,hdb5. Don't know if this can be done with ext3 or reiserfs yet. I have not tested it yet in Linux but I'll try it out just as soon as I get a chance. _________________ _______________________________________
Oh how I love Linux, especially on gentoo. |
|
Back to top |
|
|
slydini Tux's lil' helper
Joined: 30 Oct 2002 Posts: 129 Location: Virginia Beach, VA
|
Posted: Thu Oct 31, 2002 11:32 pm Post subject: |
|
|
I did some more digging into this issue and it appears that there is a lot more to it than in my previous post. I am not even sure if there is an equivilant to the dump command in linux. If there is I sure would like to know what it is. Anyway there is a HOWTO on upgrading your hard disk that has the info for accomplishing the cloning in linux. Why not try it out and tell us how it goes? _________________ _______________________________________
Oh how I love Linux, especially on gentoo. |
|
Back to top |
|
|
sarumont Tux's lil' helper
Joined: 31 Oct 2002 Posts: 94 Location: /dev/urandom
|
Posted: Fri Nov 01, 2002 12:04 am Post subject: |
|
|
Would you be so kind as to showing us to this specific HOWTO on cloning? I've recently tried to move my root partition to a larger partition by manually copying all directories from my / to that partition (minus dirs such as /mnt, /proc, and /tmp, of course). Then I edited the /etc/fstab and my grub.lst. It will boot the kernel, but restart either after the kernel is done booting or toward the end...I can't tell where it is in the process due to the quickness of the restart. Any help would be welcome. |
|
Back to top |
|
|
_SkeLeToN_ Guru
Joined: 12 Sep 2002 Posts: 506 Location: Montreal,Canada
|
Posted: Fri Nov 01, 2002 12:14 am Post subject: |
|
|
Just a question regarding this issue. Does the command dd would work on that particular situation.
ex : dd if=/dev/hda1 of=/mnt/clone/usr-img
?? |
|
Back to top |
|
|
slydini Tux's lil' helper
Joined: 30 Oct 2002 Posts: 129 Location: Virginia Beach, VA
|
Posted: Fri Nov 01, 2002 12:32 am Post subject: |
|
|
Sarumont the link I was refering to is:
http://www.tldp.org/HOWTO/mini/Hard-Disk-Upgrade/
And the dd command might work and it might not. I havn't tried it across drives that have differing geometry. If the drives were the same size and of the same manufacture then I would think using dd would work. But I havn't tried it yet to prove it. The method in the HOWTO uses the cp command which is very similar to the dd command. I havn't actually tried any disk to disk copy stuff in linux my experience is mainly with IRIX using the dump command. It is real easy in IRIX. But I aims to find a better way unless someone else chimes in with a better solution. _________________ _______________________________________
Oh how I love Linux, especially on gentoo. |
|
Back to top |
|
|
sarumont Tux's lil' helper
Joined: 31 Oct 2002 Posts: 94 Location: /dev/urandom
|
Posted: Fri Nov 01, 2002 5:11 am Post subject: |
|
|
Thanks for the link. The method that they give on that site worked for me. You do have to get out of KDE, of course. I booted from the Gentoo CD, mounted the new partition and the current (both on ext3 and on the same drive) and then I just copied everything over and make /proc and any other directories that I had. And of course set up my fstab and grub. |
|
Back to top |
|
|
zypher Retired Dev
Joined: 10 Jun 2002 Posts: 416 Location: Cologne, ger.
|
Posted: Fri Nov 01, 2002 7:56 am Post subject: |
|
|
I have quite some expierience with pseudo-cloning (copy-jobs of systems).
I boot into R.I.P (google for it). It's a ram-linux you can boot from hdd, the name is "Rescue Is Possible)".
You can use the live-cd as well of course.
Then I do a cd / then a tar -czsplf /not/myrootpartition/myroot.tgz *
Do this with all your partitions separately.
Then mount the new hdd/partitions and untar the tarfiles accordingly.
Edit fstab and install grub and you're done.
Worked flawlessly more than ten times.
I even had a cronjob on my server, building a tarfile of my root-partition every two nights or so _________________ linux user 65882 |
|
Back to top |
|
|
Flummi n00b
Joined: 23 Oct 2002 Posts: 13 Location: Erfurt (Germany)
|
Posted: Sun Nov 03, 2002 10:33 pm Post subject: |
|
|
zypher wrote: |
You can use the live-cd as well of course.
Then I do a cd / then a tar -czsplf /not/myrootpartition/myroot.tgz *
|
Actually you can send the output of the tar-command through a pipe to a second tar-command, which extracts it immediatly in the right partition, like this:
tar -clpf - / | ( cd /neues-root ; tar -xpf - )
This should make it possible to be used, even if you have not enough space left to save your complete partition in a file.
Flummi |
|
Back to top |
|
|
Master_Of_Disaster l33t
Joined: 28 Feb 2003 Posts: 610 Location: 15.05072° East, 48.13747° North (aka Mauer), Austria
|
|
Back to top |
|
|
|