Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 295397 - =sys-fs/mdadm-3.0: return value change breaks raid-start.sh startup script
Summary: =sys-fs/mdadm-3.0: return value change breaks raid-start.sh startup script
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal with 1 vote (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on: 119380
Blocks:
  Show dependency tree
 
Reported: 2009-12-02 05:17 UTC by Gordon Malm (RETIRED)
Modified: 2015-04-18 17:53 UTC (History)
13 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
mdadm3-Asv-output-20091202.txt (mdadm3-Asv-output-20091202.txt,51.07 KB, text/plain)
2009-12-02 17:26 UTC, Gordon Malm (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gordon Malm (RETIRED) gentoo-dev 2009-12-02 05:17:26 UTC
* Autoloaded 5 module(s)
* Starting up RAID devices ...
                      [ !! ]
* Setting up dm-crypt mappings ...              [ ok ]

# grep -A5 Starting.*RAID /lib/rcscripts/addons/raid-start.sh
                ebegin "Starting up RAID devices"
                create_devs ${devs}
                output=$(mdadm -As 2>&1)
                ret=$?
                [ ${ret} -ne 0 ] && echo "${output}"
                eend ${ret}

# qlist -ICv mdadm
sys-fs/mdadm-3.0
# mdadm -As
# echo $?
2

# emerge -1 =sys-fs/mdadm-2.6.8
...
# mdadm -As
# echo $?
0

GCC_SPECS="/usr/lib/gcc/i686-pc-linux-gnu/4.3.4/vanilla.specs" FEATURES="-distcc" MAKEOPTS="-j3" emerge -1 =sys-fs/mdadm-3.0
...
# mdadm -As
# echo $?
2

# emerge --info
Portage 2.1.6.13 (hardened/linux/x86/10.0, gcc-4.3.4, glibc-2.9_p20081201-r2, 2.6.28-hardened-r9-2009120101 i686)
=================================================================
System uname: Linux-2.6.28-hardened-r9-2009120101-i686-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_3800+-with-gentoo-1.12.13
Timestamp of tree: Tue, 24 Nov 2009 00:45:02 +0000
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [enabled]
app-shells/bash:     4.0_p28
dev-lang/python:     2.6.2-r1
sys-apps/baselayout: 1.12.13
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.13, 2.63-r1
sys-devel/automake:  1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6a
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=athlon64 -msse3 -O2 -fomit-frame-pointer -fno-ident -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /var/bind"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-march=athlon64 -msse3 -O2 -fomit-frame-pointer -fno-ident -pipe"
DISTDIR="/var/cache/portage/distfiles"
FEATURES="distcc distclean distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch userpriv usersandbox usersync"
GENTOO_MIRRORS="http://gentoo.mirrors.tds.net/gentoo/ http://gentoo.chem.wisc.edu/gentoo/ http://open-systems.ufl.edu/mirrors/gentoo/ http://mirror.its.uidaho.edu/pub/gentoo/"
LDFLAGS="-Wl,-O1,--hash-style=gnu"
MAKEOPTS="-j7"
PKGDIR="/var/cache/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_EXTRA_OPTS="--progress --exclude-from=/etc/portage/rsync_excludes"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage/live"
PORTDIR_OVERLAY="*snip* - nothing relevant here"
SYNC="Cannot emerge --sync, using read-only portage over NFS!"
USE="3dnow 3dnowext a52 aac aalib acl acpi adns alsa ao audiofile bash-completion bcmath berkdb bluetooth bzip2 cairo calendar caps cdb cdda cddb cdinstall cdparanoia cdr cgi clamav cli cracklib crypt css ctype cups curl curlwrappers cvs cxx dbm dbus dbx dedicated directfb djvu doc dri dts dv dvd dvdr dvdread encode enscript exif expat fam fbcon ffmpeg fftw flac flatfile fontconfig foomaticdb fortran ftp gcj gd gdbm geoip ggi gif ginac gmp gnuplot gnutls gpm gps graphviz gsl gstreamer guile hal hardened hddtemp hdf5 iconv idn ieee1394 imap imlib inifile ipv6 javascript jbig jpeg jpeg2k kerberos ladspa lame lapack latex lcms ldap libcaca libnotify libsamplerate libwww lm_sensors logrotate lua lzo mad madwifi maildir mailwrapper matroska mbox memlimit mhash midi mikmod mime mmap mmx mmxext mng modplug modules mp3 mpeg mpi mplayer mudflap musepack ncurses netboot netcdf nis nls nntp nocd nptl nptlonly ocaml ocamlopt offensive ogg openal openexr openmp osc pam pcntl pcre pda pdf perl pic plotutils png portaudio posix ppds pppd python radius raw rdesktop readline recode reflection rss ruby samba sasl scanner sdl session sharedext sharedmem shorten simplexml skey slang slp smartcard sndfile snmp soap sockets socks5 sox speex spell spl sqlite sqlite3 sse sse2 sse3 ssl startup-notification subversion svg svga sysfs syslog sysvipc szip taglib tcl tcpd theora threads tidy tiff timidity tokenizer truetype unicode urandom usb v4l v4l2 vcd vhosts videos vim-syntax vnc vorbis wavpack wddx wifi win32codecs wmf x264 x86 xattr xface xinetd xml xmlrpc xsl xvid yaz zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1        emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m  maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="apm ark chips cirrus cyrix dummy fbdev glint i128 i740 imstt intel    mach64 mga neomagic nsc nv r128 radeon rendition s3 s3virge savage      siliconmotion sis sisusb tdfx tga trident tseng v4l vesa vga via vmware    voodoo"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS
Comment 1 SpanKY gentoo-dev 2009-12-02 08:56:42 UTC
you dont describe your raid at all.  do you have one ?  what is your config file look like ?  what if you use the verbose flag ?

mdadm-3.0 works just fine on my stable system.
Comment 2 Gordon Malm (RETIRED) gentoo-dev 2009-12-02 17:26:31 UTC
Created attachment 211787 [details]
mdadm3-Asv-output-20091202.txt

Hi Mike,

Sorry, yeah that might help.  Late night & sick. :/

Yes I have a RAID and it is working quite fine otherwise.


# cat /proc/mdstat
Personalities : [raid1]
md1 : active raid1 sdb1[1] sda1[0]
      208704 blocks [2/2] [UU]

md2 : active raid1 sdb2[1] sda2[0]
      2160640 blocks [2/2] [UU]

md5 : active raid1 sdb5[1] sda5[0]
      14345920 blocks [2/2] [UU]

md6 : active raid1 sdb6[1] sda6[0]
      46090368 blocks [2/2] [UU]

md7 : active raid1 sdb7[1] sda7[0]
      12297600 blocks [2/2] [UU]

md8 : active raid1 sdb8[1] sda8[0]
      34820736 blocks [2/2] [UU]

md9 : active raid1 sdb9[1] sda9[0]
      30724160 blocks [2/2] [UU]

md10 : active raid1 sdb10[1] sda10[0]
      153605376 blocks [2/2] [UU]

md11 : active raid1 sdb11[1] sda11[0]
      108551104 blocks [2/2] [UU]

md12 : active raid1 sdb12[1] sda12[0]
      12297600 blocks [2/2] [UU]

md13 : active raid1 sdb13[1] sda13[0]
      22539072 blocks [2/2] [UU]

md14 : active raid1 sdb14[1] sda14[0]
      22539072 blocks [2/2] [UU]

md15 : active raid1 sdb15[1] sda15[0]
      28201984 blocks [2/2] [UU]

unused devices: <none>

# qlist -ICv mdadm
sys-fs/mdadm-2.6.8
# mdadm -Asv
# echo $?
0

# emerge -1 =sys-fs/mdadm-3.0
...
# mdadm -Asv
<output attached>
# echo $?
2
# mdadm --detail --scan
ARRAY /dev/md15 metadata=0.90 UUID=b44f91bd:8b87f6a6:4e3d2d1d:50e9d94b
ARRAY /dev/md14 metadata=0.90 UUID=ae69ed9f:4b3a9e31:70bc4d0b:12551434
ARRAY /dev/md13 metadata=0.90 UUID=5ef232a1:88d8cf2a:549684fb:359eb6a8
ARRAY /dev/md12 metadata=0.90 UUID=a515a60a:081ed4aa:c3522935:c0f5f816
ARRAY /dev/md11 metadata=0.90 UUID=51d1e1ca:06645599:10b65925:73914f45
ARRAY /dev/md10 metadata=0.90 UUID=b7fabe1c:393d5db9:19b0c086:28f9cf36
ARRAY /dev/md9 metadata=0.90 UUID=0917fca3:4d31d918:83e7d517:8bde5826
ARRAY /dev/md8 metadata=0.90 UUID=76e9ed04:2f8a4501:93f6780c:7ae0f40a
ARRAY /dev/md7 metadata=0.90 UUID=6b7431e3:cbfec883:14c7f7a4:d314844c
ARRAY /dev/md6 metadata=0.90 UUID=11df6552:5e88d29a:e8d41057:c353f86d
ARRAY /dev/md5 metadata=0.90 UUID=c4981d9e:40d5b603:4855f000:f124c3e6
ARRAY /dev/md2 metadata=0.90 UUID=96eec7fe:fe944a7c:60d0b526:7eaa3e00
ARRAY /dev/md1 metadata=0.90 UUID=1625ae44:de8044f9:81fe697c:0b2d3a11
# grep ^ARRAY /etc/mdadm.conf
ARRAY /dev/md1 level=raid1 num-devices=2 metadata=0.90 UUID=1625ae44:de8044f9:81fe697c:0b2d3a11
ARRAY /dev/md2 level=raid1 num-devices=2 metadata=0.90 UUID=96eec7fe:fe944a7c:60d0b526:7eaa3e00
ARRAY /dev/md5 level=raid1 num-devices=2 metadata=0.90 UUID=c4981d9e:40d5b603:4855f000:f124c3e6
ARRAY /dev/md6 level=raid1 num-devices=2 metadata=0.90 UUID=11df6552:5e88d29a:e8d41057:c353f86d
ARRAY /dev/md7 level=raid1 num-devices=2 metadata=0.90 UUID=6b7431e3:cbfec883:14c7f7a4:d314844c
ARRAY /dev/md8 level=raid1 num-devices=2 metadata=0.90 UUID=76e9ed04:2f8a4501:93f6780c:7ae0f40a
ARRAY /dev/md9 level=raid1 num-devices=2 metadata=0.90 UUID=0917fca3:4d31d918:83e7d517:8bde5826
ARRAY /dev/md10 level=raid1 num-devices=2 metadata=0.90 UUID=b7fabe1c:393d5db9:19b0c086:28f9cf36
ARRAY /dev/md11 level=raid1 num-devices=2 metadata=0.90 UUID=51d1e1ca:06645599:10b65925:73914f45
ARRAY /dev/md12 level=raid1 num-devices=2 metadata=0.90 UUID=a515a60a:081ed4aa:c3522935:c0f5f816
ARRAY /dev/md13 level=raid1 num-devices=2 metadata=0.90 UUID=5ef232a1:88d8cf2a:549684fb:359eb6a8
ARRAY /dev/md14 level=raid1 num-devices=2 metadata=0.90 UUID=ae69ed9f:4b3a9e31:70bc4d0b:12551434
ARRAY /dev/md15 level=raid1 num-devices=2 metadata=0.90 UUID=b44f91bd:8b87f6a6:4e3d2d1d:50e9d94b
# mdadm --examine /dev/sda6
/dev/sda6:
          Magic : a92b4efc
        Version : 0.90.00
           UUID : 11df6552:5e88d29a:e8d41057:c353f86d
  Creation Time : Sat Jan  3 20:49:39 2009
     Raid Level : raid1
  Used Dev Size : 46090368 (43.96 GiB 47.20 GB)
     Array Size : 46090368 (43.96 GiB 47.20 GB)
   Raid Devices : 2
  Total Devices : 2
Preferred Minor : 6

    Update Time : Wed Dec  2 09:11:28 2009
          State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0
       Checksum : 5cf1b896 - correct
         Events : 6


      Number   Major   Minor   RaidDevice State
this     0       8        6        0      active sync   /dev/sda6

   0     0       8        6        0      active sync   /dev/sda6
   1     1       8       22        1      active sync   /dev/sdb6
(^^ others are pretty much the same - look ok)
Comment 3 Gordon Malm (RETIRED) gentoo-dev 2009-12-02 17:27:48 UTC
Re-opening.  LMK if there's anything else I can provide to help.  Thanks!
Comment 4 Richard Scott 2009-12-11 22:40:19 UTC
I've also got this problem. mdadm devices are all ok, just get the "[!!]" at boot time :-(
Comment 5 Clemente Aguiar 2010-03-26 11:01:19 UTC
The same here.

mdadm devices are all ok, just get the "[!!]" at
boot time.

This has started happening after I upgraded the kernel, which has setting to "Autodetect RAID arrays during kernel boot".


Comment 6 toon 2010-04-29 07:39:53 UTC
This is a 'me too'.
I experience the same problem using sys-fs/mdadm-3.0
# uname -a
Linux wwwood2 2.6.32-gentoo-r7 #1 SMP Mon Apr 26 17:13:15 CEST 2010 x86_64 AMD Athlon(tm) Dual Core Processor 4850e AuthenticAMD GNU/Linux

The RAID devices appear okay.  System is running fine.
Just getting the [!!] during startup of the RAID devices.
Comment 7 Florian CROUZAT (SuperFlo) 2010-08-25 09:51:10 UTC
(In reply to comment #6)
> This is a 'me too'.
> I experience the same problem using sys-fs/mdadm-3.0
> # uname -a
> Linux wwwood2 2.6.32-gentoo-r7 #1 SMP Mon Apr 26 17:13:15 CEST 2010 x86_64 AMD
> Athlon(tm) Dual Core Processor 4850e AuthenticAMD GNU/Linux
> 
> The RAID devices appear okay.  System is running fine.
> Just getting the [!!] during startup of the RAID devices.
> 

+1, same behavior here, mdadm -Av always returns 2 where the script checks for a 0. Otherwise, all the raid devices seems to work fine at runtime.

Comment 8 theduck02 2010-09-07 12:53:24 UTC
I too have this problem, but would like to propose a solution.

I am building a system with 3 x RAID 1 and 1 x RAID 5 arrays. All have 0.9 superblocks and all are autodetected by the kernel. Hence, none need to be built using the /lib/rcscripts/addons/raid-start.sh script.

So why not suppress the script by removing "raid" from the list of augments assigned to RC_VOLUME_ORDER variable in /etc/conf.d/rc.

I have done this and it stops this error:

* Starting up RAID devices ...                      [ !! ]


It also suppresses another error which I encounter when my system shuts down. This error reads:

mdadm: fail to stop array /dev/md0: Device or resource busy
md0 is my root partition

This error occurs when the machine is rebooted or halted and is emanating from the /lib/rcscripts/addons/raid-stop.sh script  If you refer to comment #11 of bug report 119380, it seems Neil Brown (the mdadm main developer) believes that it not necessary to shutdown RAIDs during reboot or halt.
 
I would be interested on other people views on this approach to solving this problem.

Many thanks,

theDuck
Comment 9 Martin Mokrejš 2010-09-21 17:50:08 UTC
(In reply to comment #8)

> I would be interested on other people views on this approach to solving this
> problem.

On my system I also use the kernel autodetect functionality to detect my raid1 to yield /, but works only from 0.90 and 1.0 metadata, not newer so people with large arrays need something for the startup.

I would be close the say that I agree to drop these scripts but that is not possible. But, the scripts could grep through /proc/config.gz or /etc/mdadm.conf and not fiddle with those arrays which have the < 1.1 metadata or if the kernel feature is available. If the file(s) does not exist, keep current behavior.

I think the culprit on shutdown is that files (probably the pid files of running processes) are opened on / while the script is started. In my case on several machines, I have md0 which is /boot and md1 which is the root filesystem. I think that md0 is shutdown first while md1 after, which should be correct for my layout, but could be an issue for others. Nevertheless, I see these messages on start and stop everywhere where I use raid.
Comment 10 eponymous 2011-02-06 11:37:55 UTC
(In reply to comment #0)
> * Autoloaded 5 module(s)
> * Starting up RAID devices ...
>                       [ !! ]
> * Setting up dm-crypt mappings ...              [ ok ]
> 
> # grep -A5 Starting.*RAID /lib/rcscripts/addons/raid-start.sh
>                 ebegin "Starting up RAID devices"
>                 create_devs ${devs}
>                 output=$(mdadm -As 2>&1)
>                 ret=$?
>                 [ ${ret} -ne 0 ] && echo "${output}"
>                 eend ${ret}
> 
> # qlist -ICv mdadm
> sys-fs/mdadm-3.0
> # mdadm -As
> # echo $?
> 2
> 
> # emerge -1 =sys-fs/mdadm-2.6.8
> ...
> # mdadm -As
> # echo $?
> 0
> 
> GCC_SPECS="/usr/lib/gcc/i686-pc-linux-gnu/4.3.4/vanilla.specs"
> FEATURES="-distcc" MAKEOPTS="-j3" emerge -1 =sys-fs/mdadm-3.0
> ...
> # mdadm -As
> # echo $?
> 2
> 
> # emerge --info
> Portage 2.1.6.13 (hardened/linux/x86/10.0, gcc-4.3.4, glibc-2.9_p20081201-r2,
> 2.6.28-hardened-r9-2009120101 i686)
> =================================================================
> System uname:
> Linux-2.6.28-hardened-r9-2009120101-i686-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_3800+-with-gentoo-1.12.13
> Timestamp of tree: Tue, 24 Nov 2009 00:45:02 +0000
> distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632)
> [enabled]
> app-shells/bash:     4.0_p28
> dev-lang/python:     2.6.2-r1
> sys-apps/baselayout: 1.12.13
> sys-apps/sandbox:    1.6-r2
> sys-devel/autoconf:  2.13, 2.63-r1
> sys-devel/automake:  1.8.5-r3, 1.9.6-r2, 1.10.2
> sys-devel/binutils:  2.18-r3
> sys-devel/gcc-config: 1.4.1
> sys-devel/libtool:   2.2.6a
> virtual/os-headers:  2.6.27-r2
> ACCEPT_KEYWORDS="x86"
> CBUILD="i686-pc-linux-gnu"
> CFLAGS="-march=athlon64 -msse3 -O2 -fomit-frame-pointer -fno-ident -pipe"
> CHOST="i686-pc-linux-gnu"
> CONFIG_PROTECT="/etc /var/bind"
> CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf
> /etc/gconf /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo
> /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d
> /etc/texmf/web2c /etc/udev/rules.d"
> CXXFLAGS="-march=athlon64 -msse3 -O2 -fomit-frame-pointer -fno-ident -pipe"
> DISTDIR="/var/cache/portage/distfiles"
> FEATURES="distcc distclean distlocks fixpackages parallel-fetch protect-owned
> sandbox sfperms strict unmerge-orphans userfetch userpriv usersandbox usersync"
> GENTOO_MIRRORS="http://gentoo.mirrors.tds.net/gentoo/
> http://gentoo.chem.wisc.edu/gentoo/ http://open-systems.ufl.edu/mirrors/gentoo/
> http://mirror.its.uidaho.edu/pub/gentoo/"
> LDFLAGS="-Wl,-O1,--hash-style=gnu"
> MAKEOPTS="-j7"
> PKGDIR="/var/cache/portage/packages"
> PORTAGE_CONFIGROOT="/"
> PORTAGE_RSYNC_EXTRA_OPTS="--progress
> --exclude-from=/etc/portage/rsync_excludes"
> PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress
> --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles
> --exclude=/local --exclude=/packages"
> PORTAGE_TMPDIR="/var/tmp"
> PORTDIR="/usr/portage/live"
> PORTDIR_OVERLAY="*snip* - nothing relevant here"
> SYNC="Cannot emerge --sync, using read-only portage over NFS!"
> USE="3dnow 3dnowext a52 aac aalib acl acpi adns alsa ao audiofile
> bash-completion bcmath berkdb bluetooth bzip2 cairo calendar caps cdb cdda cddb
> cdinstall cdparanoia cdr cgi clamav cli cracklib crypt css ctype cups curl
> curlwrappers cvs cxx dbm dbus dbx dedicated directfb djvu doc dri dts dv dvd
> dvdr dvdread encode enscript exif expat fam fbcon ffmpeg fftw flac flatfile
> fontconfig foomaticdb fortran ftp gcj gd gdbm geoip ggi gif ginac gmp gnuplot
> gnutls gpm gps graphviz gsl gstreamer guile hal hardened hddtemp hdf5 iconv idn
> ieee1394 imap imlib inifile ipv6 javascript jbig jpeg jpeg2k kerberos ladspa
> lame lapack latex lcms ldap libcaca libnotify libsamplerate libwww lm_sensors
> logrotate lua lzo mad madwifi maildir mailwrapper matroska mbox memlimit mhash
> midi mikmod mime mmap mmx mmxext mng modplug modules mp3 mpeg mpi mplayer
> mudflap musepack ncurses netboot netcdf nis nls nntp nocd nptl nptlonly ocaml
> ocamlopt offensive ogg openal openexr openmp osc pam pcntl pcre pda pdf perl
> pic plotutils png portaudio posix ppds pppd python radius raw rdesktop readline
> recode reflection rss ruby samba sasl scanner sdl session sharedext sharedmem
> shorten simplexml skey slang slp smartcard sndfile snmp soap sockets socks5 sox
> speex spell spl sqlite sqlite3 sse sse2 sse3 ssl startup-notification
> subversion svg svga sysfs syslog sysvipc szip taglib tcl tcpd theora threads
> tidy tiff timidity tokenizer truetype unicode urandom usb v4l v4l2 vcd vhosts
> videos vim-syntax vnc vorbis wavpack wddx wifi win32codecs wmf x264 x86 xattr
> xface xinetd xml xmlrpc xsl xvid yaz zlib" ALSA_CARDS="ali5451 als4000 atiixp
> atiixp-modem bt87x ca0106 cmipci emu10k1        emu10k1x ens1370 ens1371 es1938
> es1968 fm801 hda-intel intel8x0 intel8x0m  maestro3 trident usb-audio via82xx
> via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop
> empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul
> mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions
> alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file
> authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user
> autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires
> ext_filter file_cache filter headers include info log_config logio mem_cache
> mime mime_magic negotiation rewrite setenvif speling status unique_id userdir
> usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev"
> KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001
> mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="apm ark chips cirrus cyrix
> dummy fbdev glint i128 i740 imstt intel    mach64 mga neomagic nsc nv r128
> radeon rendition s3 s3virge savage      siliconmotion sis sisusb tdfx tga
> trident tseng v4l vesa vga via vmware    voodoo"
> Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG,
> LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS
> 

I am also seeing this problem:

http://forums.gentoo.org/viewtopic-p-6568423.html#6568423
Comment 11 Yaroslav Isakov 2011-04-01 21:34:51 UTC
I found a root of problem in my case - It's udev. I disable mdraid service, and have # CONFIG_MD_AUTODETECT is not set, but cat /proc/mdstat shows me properly configured raid array. So I find 'mdadm' string in /lib, and it was found in /lib/udev/rules.d/64-md-raid.rules. I've deleted this file, add mdraid service to boot runlevel, and now there is no error on boot
Comment 12 Yaroslav Isakov 2011-04-01 21:45:19 UTC
More precisely, conflict with mdraid is in these lines:
ENV{ID_FS_TYPE}=="linux_raid_member", ACTION=="remove", RUN+="/sbin/mdadm -If $name"
ENV{ID_FS_TYPE}=="linux_raid_member", ACTION=="add", RUN+="/sbin/mdadm --incremental $env{DEVNAME}"
Comment 13 Fab 2011-05-28 21:19:46 UTC
Confirming comment #11 and comment #12. I commented the two lines in /lib/udev/rules.d/64-md-raid.rules, and, with mdraid on boot runlevel, the error is gone.
Comment 14 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2012-02-12 07:21:06 UTC
Can you please all retest with newer mdadm? raid-start.sh is long gone.
Comment 15 Fab 2012-07-05 15:50:23 UTC
(In reply to comment #14)
> Can you please all retest with newer mdadm? raid-start.sh is long gone.

Please define 'newer'. I just did a fresh stable amd64 gentoo installation with some RAID1 arrays, mdadm-3.1.4 here, and the problem is still there. Comment #13 is still valid.
Comment 16 Philipp Periventas 2012-07-22 23:03:43 UTC
Same error occurs here. Fresh amd64 install, mdadm-3.1.4 and sys-fs/udev-171-r6.
Comment 17 Fab 2013-09-25 11:05:36 UTC
On a stable system I recently upgraded to mdadm-3.2.6-r1, and the mdraid init script fails to start correctly :
> * Starting up RAID devices ...   [ !! ]

But RAID arrays are mounted.
Comment 18 Matthias Nagl 2013-09-25 13:09:05 UTC
For me the problem was solved by removing lvm and mdraid from the boot runlevel.

These services are obviously not necessary if raid/lvm are assembled by genkernel's initrd although they are recommended by this popular howto: http://www.gentoo.org/doc/de/gentoo-x86+raid+lvm2-quickinstall.xml
Comment 19 Fab 2013-09-26 08:36:01 UTC
(In reply to Matthias Nagl from comment #18)
> For me the problem was solved by removing lvm and mdraid from the boot
> runlevel.
> 
> These services are obviously not necessary if raid/lvm are assembled by
> genkernel's initrd although they are recommended by this popular howto:
> http://www.gentoo.org/doc/de/gentoo-x86+raid+lvm2-quickinstall.xml

I do not use genkernel, and my initramfs does not assemble RAID arrays, so I need this service at boot, but it fails to start properly despite te fact that arrays are assembled. Can someone please reopen this bug ? Thanks.