Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 196499 - sys-fs/mdadm causes the kernel to panic
Summary: sys-fs/mdadm causes the kernel to panic
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High critical (vote)
Assignee: Gentoo Kernel Bug Wranglers and Kernel Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-10-20 08:57 UTC by Thien Vu
Modified: 2007-10-20 21:28 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thien Vu 2007-10-20 08:57:10 UTC
I have a Promise SX6000. Connected to the SX6000 are six 500GB drives. Since the SX6000 cannot have arrays of >2TB, I have created six arrays with a single drive each and will use software RAID.

I am interfacing with the SX6000 through the I2O interface. Each of the drives shows up as /dev/i2o/hd{a,b,c,d,e,f}. I have created a single partition on each of the drives with type 'Linux raid autodetect'. The partitions correspond to /dev/i2o/hd{a,b,c,d,e,f}1.

I then try to create a RAID array over these partitions with the mdadm command.

mdadm -C -l5 -n6 /dev/md0 /dev/i2o/hda1 /dev/i2o/hdb1 /dev/i2o/hdc1 /dev/i2o/hdd1 /dev/i2o/hde1 /dev/i2o/hdf1

This is when the kernel panics with the following message:
----------[ cut here ]----------
kernel BUG at include/linux/i2o.h:1076!
Invalid opcode: 0000 [#1]
Modules linked in: raid456 xor md_mod ipv6 i2o_block pcspkr rtc i2c_viapro via_rhine mii i2o_core psmouse nfs lockd sunrpc jfs dm_mod scsi_wait_scan usbhid uhci_hcd usb_storage ehci_hcd usbcore
CPU:    0
EIP:    0060:[<f88666b0>]    Not tainted VLI
EFLAGS: 00010287   (2.6.22-gentoo-r8 #1)
EIP is at i2o_driver_dispatch+0x80/0x1d0 [i2o_core]
eax: c1a42800   ebx: 0009f800   ecx: 37c70000   edx: 0009f800
esi: c1a42800   edi: 00000000   ebp: 00000013   esp: c0496fa4
ds: 007b   es: 007b   fs: 0000  gs: 0000   ss: 0068
Process swapper (pid: 0, ti=c0496000 task=c0437280 task.ti=c045c000)
Stack: 00000000 dff35ecc dff35e00 00000246 c1a42800 f8870000 dfe73800 0009f800
       c1a42800 00000000 00000013 f8868101 dfdab2a0 00000000 c013cf55 c043fc1c
       00000013 c013df00 c043fc1c c013df3a c045cf78 00000013 c01065cf
Call Trace:
 [<f8868101>] i2o_pci_interrupt+0x11/0x40 [i2o_core]
 [<c013cf55>] handle_IRQ_event+0x25/0x50
 [<c013df00>] handle_fasteoi_irq+0x0/0x90
 [<c013df3a>] handle_fasteoi_irq+0x3a/0x90
 [<c01065cf>] do_IRQ+0x7f/0xd0
 [<c012e42b>] enqueue_hrtimer+0x6b/0x110
 [<c01047f3>] common_interrupt+0x23/0x28
 [<c0102cba>] default_idle+0x2a/0x40
 [<c01023e3>] cpu_idle+0x43/0x70
 [<c045db25>] start_kernel+0x215/0x2a0
 [<c045d450>] unknown_bootoption+0x0/0x260
 =======================
Code: 74 68 8b 5e 04 89 d8 89 5c 24 14 c1 e8 18 83 f8 13 74 45 8b 44 24 18 8b 58 0c 85 db 74 45 89 f1 8b 44 24 10 ff d3 eb 28 8d 76 00 <0f> 0b eb fe 89 5c 24 0c 89 44 24 08 c7 44 24 04 aa 94 86 f8 c7
EIP: [<f88666b0>] i2o_driver_dispatch+0x80/0x1d0 [i2o_core] SS:ESP 0068:c0496fa4
Kernel panic - not syncing: Fatal exception in interrupt

Reproducible: Always

Steps to Reproduce:
1. Install SX6000, using I2O interface
2. Run mdadm on drives with the above command.
Actual Results:  
See bug report above.

Expected Results:  
mdadm should have created the array and the kernel should not have panicked.

Portage 2.1.3.9 (default-linux/x86/2007.0, gcc-4.1.2, glibc-2.6.1-r0, 2.6.22-gentoo-r8 i686)
=================================================================
System uname: 2.6.22-gentoo-r8 i686 AMD Sempron(tm) 3000+
Timestamp of tree: Wed, 17 Oct 2007 15:50:01 +0000
app-shells/bash:     3.2_p17
dev-java/java-config: 1.3.7, 2.0.33-r1
dev-lang/python:     2.3.5-r3, 2.4.4-r5
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.9-r2
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.61-r1
sys-devel/automake:  1.7.9-r1, 1.8.5-r3, 1.10
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.24
virtual/os-headers:  2.6.22-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=athlon-xp -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-O2 -march=athlon-xp -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.osuosl.org/"
LC_ALL="C"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync10.us.gentoo.org/gentoo-portage"
USE="X acl apache2 berkdb bitmap-fonts cli cracklib crypt dri gdbm gpm iconv ipv6 isdnlog midi mudflap ncurses nls nptl nptlonly openmp pam pcre perl pppd python readline reflection session spl ssl tcpd threads truetype-fonts type1-fonts unicode usb x86 xorg 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 mulaw multi null plug rate route share shm softvol" 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="nv"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LDFLAGS, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY

mdadm version 2.6.2
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-10-20 09:04:33 UTC
Try with 2.6.4 and report back, please.
Comment 2 Thien Vu 2007-10-20 09:09:21 UTC
(In reply to comment #1)
> Try with 2.6.4 and report back, please.
> 

2.6.4 is not in the portage tree anymore.
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2007-10-20 09:13:25 UTC
Sure it is...

echo sys-fs/mdadm >> /etc/portage/package.keywords
Comment 4 Thien Vu 2007-10-20 09:23:57 UTC
(In reply to comment #3)
> Sure it is...
> 
> echo sys-fs/mdadm >> /etc/portage/package.keywords
> 

Ah yes, I misunderstood you. I think of this as a kernel bug and so reverting to kernel-2.6.4 made no sense to me. Anyhow I'll try mdadm-2.6.4 tomorrow but I still think the kernel shouldn't panic from a userspace call.
Comment 5 Thien Vu 2007-10-20 17:09:44 UTC
(In reply to comment #1)
> Try with 2.6.4 and report back, please.

I've confirmed that this is still a problem with mdadm-2.6.4.
Comment 6 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2007-10-20 21:28:04 UTC
This is not specific to mdadm.
If you look at the stack trace from the kernel, it's a fault in the I2O driver.
Please test a 2.6.23* kernel, and if that still fails, take it to the upstream I2O developer or LKML.