Click to See Complete Forum and Search --> : Quick advice on hdd swap.
gkedrovs
05-05-2003, 05:20 PM
Can I swap out a hdd easily? I live in Costa Rica but am up in Edina, MN, right now. I can get a hdd CHEAP up here to replace my full one back home. But, I would need to swap them out and use the smaller one in a server I'm putting together. I'm unsure, thought, about how to get the new hdd bootable and all my present stuff from the old one to the new one. Is it do-able? Is it fairly easy? Or should I just get 2 hdd and just ADD one to my machine and have the extra one for the server?
Any ideas? I'm up against time here. Going home soon.
Thanks.
-Greg
Stween
05-05-2003, 07:32 PM
I'm not entirely sure what the question is asking here, although I am slightly tired ;)
The command 'dd' could be used to mirror one disk to another, which would then be bootable just like the old disk - I think. Even if it wasn't, with a boot disk handy, booting up and running lilo would finish off setting up the new, smaller hard drive, with all the content as was on the older drive. This all assumes everything on the old drive will fit onto the smaller drive.
If you say you can get the drives cheap though, why not just buy two?? ;)
gkedrovs
05-05-2003, 10:46 PM
Sorry I wasn't clear...
I have a 40-gig hdd right now that is full. It is dual boot: win98 and RH8.0.
I would like to get an 80-gig hdd and replace the old one. But, I have spent a ton of time getting everything set up the way I want (on my 40 gig), so I don't want to lose it all. I'd like to have an exact copy of the 40 transferred to the 80, and then I'd pull the 40 and put it in my server.
If I don't go that route, then I gotta get two 30 or two 40-gig drives: one for my machine (and that would mean I'd have 2) and one for my server.
But... the 80-gig is cheaper than two 40-gigs. You know? That's all. I'm a tightwad...
-gk
Stween
05-06-2003, 04:57 PM
Ahh, I get it now...
Well, what I'd try doing would be this:
Get the new 80GB drive, and set up the partitions in a similar style to what you have on your 40GB drive. Use dd to transfer data from one partition to it's replacement partition, ie
dd if=/dev/hda1 of=/dev/hda1
Once this is done, remove the 40GB drive, wire up the 80GB as the primary drive, fire up with a boot disk, and run lilo to get the boot loader installed. Test the system :)
From there you can do whatever you want with the old 40GB drive. I offer no guarantees that this process will work, however, but I've done similar things before. Instead of dd, you might want to create your partitions, then format them (using mke2fs), and simply copy the files over when both drives are in the same machine. That should theoretically do the same thing - my only concern is what happens to the extra space on the new drive's partitions when dd'ing a smaller partition into it.... anyone any ideas?)
Simply buying two drives though would probably be easier... ;)
justlinux.com
Copyright 2007 Jupitermedia Corporation All Rights Reserved.