LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 01-07-2006, 11:55 PM   #1
Cirdan
Member
 
Registered: Nov 2005
Distribution: Arch Linux
Posts: 84

Rep: Reputation: 15
Copying from one hard drive to another


As some of you may know, I have two hard drives. One of them I have Windows, other I have Linux. Because Windows is Windows, its going bad, and it runs chckdisk at bootup. My Dad said we probably need to whipe it out/reformat it. I fell I am ready to make the switch over to Linux full time. So since on my second hard drive I have built a LFS system, I really don't want to re-build it. Is it possible to just copy everything over? And what do I need to with the boot loader(Grub)?
 
Old 01-08-2006, 03:33 AM   #2
carl0ski
Member
 
Registered: Sep 2004
Location: Melbourne, Victoria Australia
Distribution: Support those that support you :)
Posts: 872
Blog Entries: 12

Rep: Reputation: 30
Quote:
Originally Posted by Cirdan
As some of you may know, I have two hard drives. One of them I have Windows, other I have Linux. Because Windows is Windows, its going bad, and it runs chckdisk at bootup. My Dad said we probably need to whipe it out/reformat it. I fell I am ready to make the switch over to Linux full time. So since on my second hard drive I have built a LFS system, I really don't want to re-build it. Is it possible to just copy everything over? And what do I need to with the boot loader(Grub)?
i cant really say about grub but lilo will work.

copy all /
to you new hdd /mnt/new

LNS you should know how to change root and env?
cause i dont remember.
but once /mnt/new is your root you can edit
vi /etc/lilo.conf
edit it to suit where the hdd is (unfortunately different personally i hotswapped My ide drives at the point)

change hda to hdb or whatever

save and run
/sbin/lilo
it write a boot record to the MBR
hopefully
 
Old 01-08-2006, 03:42 AM   #3
silmaril8n
Member
 
Registered: May 2004
Posts: 123

Rep: Reputation: 15
Is chroot the command needed?
 
Old 01-08-2006, 06:00 AM   #4
carl0ski
Member
 
Registered: Sep 2004
Location: Melbourne, Victoria Australia
Distribution: Support those that support you :)
Posts: 872
Blog Entries: 12

Rep: Reputation: 30
yep chroot is it

it escaped my mind for some reason.

another risky method is hot swap hdds after copying and run lilo.

change to
init 1
remove power cable from each drive (Very important as if you unplug IDE first hdd gets wiped.) once power is off remove the ide cables.

the one you freshly copied stuff to make sure is master like the original and plug in its place .

then run lilo.
 
  


Reply



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
Copying one hard drive to a partition and having it bootable... how? Nebetsu Linux - Hardware 24 01-02-2006 01:07 PM
problem copying knoppix kernel to hard drive fatblueduck Linux - General 4 06-14-2005 06:16 PM
Mandrake is copying / to the 2nd hard drive nedjo Linux - Networking 0 05-13-2004 05:39 AM
need help copying a hard drive valueduser Linux - General 6 10-17-2003 08:26 AM
copying current setup to new hard-drive noshellswill Linux - Hardware 3 10-14-2003 09:43 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:55 PM.

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
Open Source Consulting | Domain Registration