-   Fedora (
-   -   newbie - need help to configure RAID1 (

xdragon 07-16-2006 10:20 PM

newbie - need help to configure RAID1
i have problem to setup new server with RAID1. Server PC model is HP ProLiant M110 G3. After install the Fedora core 5, the error occur "Disk /dev/md3 doesn't contain a valid partition table". I check the mdstat by enter this command line "cat /proc/mdstat", the result listed as below:
Personalities : [raid1]
md0 : active raid1 sdb1[1] sda1[0]
200704 blocks [2/2] [UU]

md2 : active raid1 sdb3[1] sda3[0]
34812736 blocks [2/2] [UU]

md3 : active raid1 sdb5[1] sda5[0]
1052160 blocks [2/2] [UU]

md4 : active raid1 sdb6[1] sda6[0]
1124416 blocks [2/2] [UU]

md1 : active raid1 sdb2[1] sda2[0]
40957632 blocks [2/2] [UU]

if enter "fdisk -l" it will have this problem.
Disk /dev/md0: 205 MB, 205520896 bytes
2 heads, 4 sectors/track, 50176 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md0 doesn't contain a valid partition table

i check /etc/mdadm.conf
DEVICE /dev/sda2 /dev/sdb2 /dev/sda1 /dev/sdb1 /dev/sda3 /dev/sdb3 /dev/sda6 /dev/sdb6 /dev/sda5 /dev/sdb5
ARRAY /dev/md1 level=raid1 num-devices=2 UUID=9085a26b:45047086:54104233:1fe52da8
ARRAY /dev/md0 level=raid1 num-devices=2 UUID=f8839477:c84153f4:24ee3d61:dce62e21
ARRAY /dev/md2 level=raid1 num-devices=2 UUID=2542be4f:f2787dbf:4fbba4b9:62b20aa7
ARRAY /dev/md4 level=raid1 num-devices=2 UUID=5f7b49ee:9be6bb8d:713df29e:97c64ea5
ARRAY /dev/md3 level=raid1 num-devices=2 UUID=c80d208d:6f7dbe47:27d00e30:e935722b

does anyone can help me to solve this problem?


i_grok 07-17-2006 07:05 PM

Actually, this isn't really a problem. Your md devices aren't supposed to have a partition table on them. For some reason, fdisk continues to look for one.

If you do a

df -h
you will see that the md devices are already mounted and working fine.

Were there an actual problem with /dev/md3, you would see something like this in /proc/mstat:

md3 : active raid1 sdb5[1]
1052160 blocks [1/2] [_U]

I assume the reason you even realized this was happening is that you saw an error message on boot? You should be able to fix the issue by editting /etc/init.d/boot.swap. You need find the line where it calls

fdisk -l
and change it to

fdisk -l 2> /dev/null

xdragon 07-17-2006 09:01 PM

Hi i_grok,
thank you for helping me, i have found the /dev/mdx is mounted working properly by giving the command as what you suggested "df -h", but i can't find the "/etc/init.d/boot.swap" file. how should i do to fix this problem?

I have other problems, when i type the command "dmraid -ay", the error is listed as below:-
dmraid -ay
No RAID disks
Does it cause the problem?

I get this error message by issue this command "dmesg | tail". this kind of message also occur when boot up server, but is another type of message.
audit(1153185060.063:288): avc: denied { execmod } for pid=4084 comm="firefox-bin" name="" dev=md1 ino=916827 scontext=root:system_r:unconfined_t:s0-s0:c0.c255 tcontext=root:object_r:user_home_t:s0 tclass=file

Any idea of this error?


Emmanuel_uk 07-18-2006 01:00 AM



dmraid -ay error
This is normal.
I do not think you can use mdadm and dmraid.
Most people prefer mdadm anyway.
Have a look at the mdadm man page if you have not already

PS: raid1 is no substitute for good backups

i_grok 07-18-2006 02:02 PM

I agree with Emmanuel_uk - you should use mdadm. It will do everything you need.

As for the errors you see on boot, I still wouldn't worry about them. If you want to know what is causing them, you might be able to find them with:

cd /etc/init.d
grep "fdisk -l" *

What you are seeing in dmesg looks like selinux messages. It is a security feature, but if all it is printing is warnings, it probably isn't a big issue. You can disable selinux if you wish - I don't personally have much experience with it.

Emmanuel_uk 07-18-2006 03:40 PM


What you are seeing in dmesg looks like selinux messages.
Yes it does
xdragon, you need serious reading about security on server
if you are not used to things like SELinux.
I think there are 2 modes in SELinux, one where you just check what would be
locked, and what sort of rights are granted, then there is the mode
where this is enabled. Watch out because as a beginner one can lock oneself out
in some circumstances, with possibly no way back.
Sorry cannot help more, have done some reading on SEL but not implemented it ever/yet.

Happy linux to you

xdragon 07-18-2006 08:37 PM

thank you (i_grok & Emmanuel_uk), I will use mdadm. Do you have any best web site regarding the selinux?

by the way, how to install the modules.cgz driver? what is the proper step to install driver?

Emmanuel_uk 07-19-2006 01:06 AM

There is the NSA website for SEL, there might be a few tutorials around
(one by IBM, some publications by the Linux Journal). Do not know more than that.

re modules, loading them in memory is with modprobe, usually automated
via /etc/modules.conf
re install ang dz file, see the sticky in mandriva forum about tar.gz for example,
or better look in LQ bookmark for rute, and also newbie admin guide.

All times are GMT -5. The time now is 11:44 AM.