LinuxQuestions.org
Review your favorite Linux distribution.
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 09-21-2011, 08:44 PM   #1
SimGuy
Member
 
Registered: Jul 2008
Posts: 38

Rep: Reputation: 17
How do I create a swappable hard drive


Hi everyone,
I have several computers with the same hardware and removable hard drives. I want to be able to create several back up hard drives that I can simply swap out if one goes bad in the computers. I am runnign CentOS 5.4.

I have set up the partitioning scheme with /boot, /, swap, and /home and have tried to swap out the drives but get a kernel panic every time.

Is there a specific partitioning scheme, fstab setup or grub.conf arguments that I need to have set up in order for this to work?

Any advice is greatly appreciated!

Thanks!
 
Old 09-21-2011, 09:24 PM   #2
replica9000
Member
 
Registered: Jul 2006
Location: Quahog, Rhode Island
Distribution: Debian 'Sid', FreeBSD, Android
Posts: 624
Blog Entries: 2

Rep: Reputation: 103Reputation: 103
Can I have some more information?

Are you swapping drives with the system on or off? Also can you post your fstab?
 
Old 09-22-2011, 10:49 AM   #3
SimGuy
Member
 
Registered: Jul 2008
Posts: 38

Original Poster
Rep: Reputation: 17
The system is off when I swap drives. I do a full shut down, swap the drives then turn the computer back on. I have one computer that I have been doing some development on and trying to get this swappable hard drive issue resolved. I have a second computer where I am testing swapping the hard drives. Both systems are identical hardware. The system loads up just fine on the original computer that I loaded CentOS onto but when I try to move that hard drive to another computer that's when I have problems. I will post fstab for both systems when I get a chance.

The error message is as follows:
Code:
mount: could not find filesystem '/dev/root'
setuproot: moving /dev failed: No such file or directory
setuproot: error mounting /proc: No such file or directory
setuproot: error mounting /sys: No such file or directory
switchroot: mount failed: No such file or directory
Kernel panic - not synching: Attempted to kill init!
 
Old 09-22-2011, 12:00 PM   #4
replica9000
Member
 
Registered: Jul 2006
Location: Quahog, Rhode Island
Distribution: Debian 'Sid', FreeBSD, Android
Posts: 624
Blog Entries: 2

Rep: Reputation: 103Reputation: 103
The drive that you are swapping has the root filesystem on it?
 
Old 09-22-2011, 03:13 PM   #5
jefro
Guru
 
Registered: Mar 2008
Posts: 11,121

Rep: Reputation: 1362Reputation: 1362Reputation: 1362Reputation: 1362Reputation: 1362Reputation: 1362Reputation: 1362Reputation: 1362Reputation: 1362Reputation: 1362
I suspect some issue with how each system is using the disk. Disk id may need to have entries set by uuid. To fix it by labels like sdx then you have to have bios and maybe some other things set to match all systems.
 
Old 09-23-2011, 02:26 AM   #6
business_kid
Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 6,195

Rep: Reputation: 533Reputation: 533Reputation: 533Reputation: 533Reputation: 533Reputation: 533
In the misbehaving machine, it looks like you are putting that drive in the wrong place. The grub entry you use is incorrect - that's why it can't find /dev/root.

What you are doing is crazy, btw. Leave the OS - store & move data, and only if you have regular backups. Is there a network drive they can both access?
 
  


Reply

Tags
boot, centos, grub


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
Best way to create an image of my hard drive? veeruk101 Linux - Newbie 8 06-14-2011 04:05 PM
Cannot unmount from hard-drive to create partiontions TeenyLemon Linux - Hardware 3 02-28-2009 07:00 PM
Using dd and gzip to create hard drive image but image is bigger than hard drive? banz Linux - Software 3 11-22-2008 04:25 AM
hard drive failing, how can I create an image of my drive? oily_rags Suse/Novell 6 07-07-2005 02:19 PM
hot swappable ide hard disks chens_83 Linux - General 1 09-23-2002 07:39 PM


All times are GMT -5. The time now is 03:46 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration