Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 19th August 2009, 19:15
treeman treeman is offline
Junior Member
 
Join Date: May 2009
Posts: 29
Thanks: 0
Thanked 1 Time in 1 Post
Default Raid 1 on centos won't boot with 1 drive removed

I have just installed a fresh copy of centos 5 and created raid 1 on 2 drives.
Both my drives are 40gb but different brands. I successfully created raid 1 by following guides, which gave me this setup:

RAID Devices
/dev/md0 ext3 [check mark] 100
/dev/md1 swap [check mark] 1024
/dev/md2 ext3 [check mark] [remaining space]

Hard Drives
/dev/sda
/dev/sda1 /dev/md0 software RAID [no check mark] 100
/dev/sda2 /dev/md1 software RAID [no check mark] 1024
/dev/sda3 /dev/md2 software RAID [no check mark] [remaining space]
/dev/sdb
/dev/sdb1 /dev/md0 software RAID [no check mark] 100
/dev/sdb2 /dev/md1 software RAID [no check mark] 1024
/dev/sdb3 /dev/md2 software RAID [no check mark] [remaining space]

I also instelled grub on both drives.

So everything is good the system is up and running, but I decide to test raid and unplug 1 of the drives, trying to boot only from the remaining 1.

I get the grub screen, then centos startup but it gives me bad superblock, a few lines with directories that can't be found and finally a kernel panic. When i replug so both drives are on system boots fine.

What am I doing wrong? I just want to make sure the system will be able to run if one drive fails. Thank you for any help guys!
Reply With Quote
Sponsored Links
  #2  
Old 20th August 2009, 16:52
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,751 Times in 2,581 Posts
Default

What's in /boot/grub/menu.lst? Did you try this guide? http://www.howtoforge.com/software-r...-boot-fedora-8
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 21st August 2009, 05:59
treeman treeman is offline
Junior Member
 
Join Date: May 2009
Posts: 29
Thanks: 0
Thanked 1 Time in 1 Post
 
Default

Thank you for the guide, I actually managed to get it going by getting some ideas from the link.

The main thing that stuck out to me compared to the examples was the output from
cat /proc/mdstat

My output differed in this line
md2 : active raid1 sda3[0]
4618560 blocks [2/1] [CHUNKS]

instead of

md2 : active raid1 sda3[0]
4618560 blocks [2/1] [U_]

So i decided to reinstall and looks like its working now, I can boot from either hard drive after installing grub on both disks.

The main culprits that I can think of are:
1. It was late at night and I might of kept the last raid device as raid0 (default) instead of raid1
2. I installed kernel crash support on the initial installation which was also quoted in menu.lst from grub. This time I did not install kernel crash support

Now I am getting:

Personalities : [raid1]
md0 : active raid1 hdb1[1] hda1[0]
200704 blocks [2/2] [UU]

md1 : active raid1 hdb2[1] hda2[0]
2048192 blocks [2/2] [UU]

md2 : active raid1 hdb3[1] hda3[0]
36828928 blocks [2/2] [UU]

Thanx for your help, and hope that somebody stuck in the same situation can get some info from me too.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Raid 1 failure but only old data left on remaining drive heals1ic Installation/Configuration 3 6th January 2010 13:57
Centos 5.2 + ISPConfig 3 tutorial - Problem with email tanakskool Server Operation 1 3rd June 2009 17:22
dual boot xp & centos 5 m3tr HOWTO-Related Questions 2 24th January 2009 14:45
Software RAID 1, if one drive fails I can't boot just from the other! oskare100 Server Operation 1 23rd September 2007 09:30
SATA Software RAID 1 on Linux mphayesuk Installation/Configuration 2 21st February 2006 12:31


All times are GMT +2. The time now is 15:44.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.