Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Debian This forum is for the discussion of Debian Linux.


  Search this Thread
Old 12-28-2005, 04:17 PM   #1
LQ Newbie
Registered: Dec 2004
Location: Denmark
Distribution: Debian
Posts: 22

Rep: Reputation: 15
Question Software Raid automount


I'm have two 120gb HD and decided to setup a software raid and mount /home on the raid. The raid is created with mdadm and works fine. But the raid doesn't start after reboot! I'm running Sarge with a standard 2.6.8-smp kernel and wrote "md" and "raid1" in "/etc/modules" and created the "/etc/mdadm/mdadm.conf"-file. All i need to type after reboot is "mdadm -As /dev/md0" then it mounts perfectly. I could set "mdadm ..." in my startup script, but i would prefer if it worked proper. Filetype has been set to "0xFD = Linux Raid autodetect" with cfdisk.
I read in the howto that the modules has to be builtin the kernel, but i don't if that is true...
Old 01-25-2006, 10:31 AM   #2
Registered: Aug 2003
Distribution: Debian, Ubuntu
Posts: 188

Rep: Reputation: 30
as far as I got into this problem, you are right: I had the same problem, built a new kernel with raid and scsi support builtin and found, that the kernel tried to autodetect.
( dmesg | grep md : Some autodetection messages )

BUT... It still doesn't work...
I think, problem is now, that the kernel first tries to autodetect the RAID. After this, it detects the sata drives, which whould hold the array :-(

Don't know, what to do whith this, now...
Old 01-25-2006, 01:40 PM   #3
Registered: Feb 2003
Location: 1st hop-NYC/NewJersey shore,north....2nd hop-upstate....3rd hop-texas...4th hop-southdakota(sturgis)...5th hop-san diego.....6th hop-atlantic ocean! Final hop-resting in dreamland dreamwalking and meeting new people from past' night.
Distribution: Siduction, the only way to do Debian Unstable
Posts: 506

Rep: Reputation: Disabled
Make sure mdadm is ticked in rcconf to start at boot and not manual start only.
What is your fstab entries for the MD devices?
Mtab has nothing to do with booting and automounting md devices,its basically a reference file.
Also when setting up the drives in cfdisk it should be set to "fd - Linux raid autodetect".

Some suggest to add this to fstab md line....errors=remount-ro after the filesystem type.
I believe I have "defaults" only.

/dev/md0 /media/md0 ext3 auto,users,exec 0 0
/dev/md1 /media/md1 reiserfs auto,users,exec 0 0
/dev/md2 /media/md2 reiserfs auto,users,exec 0 0

Also,whats the output of;
dmesg | grep md

and/or mount | grep md
Old 01-25-2006, 01:51 PM   #4
LQ Newbie
Registered: Dec 2004
Location: Denmark
Distribution: Debian
Posts: 22

Original Poster
Rep: Reputation: 15
This is embarrassing...

.. Normally I always preach that people should post the solution, if they find it them self. I forgot...

Filled out the conf-file, "/etc/mdam/mdadm.conf". The "DEVICE" is filled out manually, and the rest output from the command.
# mdadm detail scan >>/etc/mdadm/mdadm.conf
DEVICE /dev/hdc1 /dev/hdd1
ARRAY /dev/md0 level=raid1 numdevices=
2 UUID=9c20fb1b:76733dcb:68e23c5f:b84c0b8a
In Debian there is a startup-file in "/etc/default/mdadm", it can be edited with "dpkg-reconfigure mdadm" or by hand. Mine looks like this...
# This file is automatically generated.
# Run 'dpkg-reconfigure mdadm' to modify it.
If the modules isn't builtin they should be loaded at startup. In Debian they are posted in "/etc/modules".
libata - As far as i know, it's a basic ata-module.
md - The softwareRAID modules.
raid1 - Gives raid1 support. If other raid-types is needed, that particular modules should be loaded.
/dev/md0        /home           ext3    defaults 0    0

Last edited by nogetfx; 01-26-2006 at 03:58 AM.
Old 02-15-2006, 04:19 PM   #5
Registered: Aug 2003
Distribution: Debian, Ubuntu
Posts: 188

Rep: Reputation: 30
Just to mention: If problems persist, you should make sure, that all neccessary drivers are available for the kernel. Modules make problems if loaded too late... These flavour of problem can e located in dmesg.
I had several days fun before I got all sata stuff built in...


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
Why can't I mount this md0 raid? (mdadm and software raid) cruiserparts Linux - Software 35 01-05-2013 03:35 PM
Is it possible to convert from using hardware RAID to software RAID? kindredstar Linux - Hardware 2 12-19-2005 09:13 AM
Software RAID to recover data from HW RAID ocschwar Linux - Hardware 5 02-25-2005 10:05 PM
Can fake raid be converted to linux software raid? jmacdonald801 Linux - General 3 01-30-2005 12:33 PM
moving system from ide software raid to new box with scsi raid ftumsh Linux - General 0 10-28-2003 09:34 AM > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 09:33 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration