Bug 19577 - segfault on software raid 1
Summary: segfault on software raid 1
Status: RESOLVED FIXED
Alias: None
Product: hal
Classification: Unclassified
Component: hald (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: high critical
Assignee: David Zeuthen (not reading bugmail)
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-01-15 00:40 UTC by Marin Glibić
Modified: 2009-06-04 01:30 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Marin Glibić 2009-01-15 00:40:16 UTC
On Slackware 12.2 + 2.6.28 kernel hald segfaults while starting, on simple software raid 1. Without the following, on this test machine, hal doesn't work at all on software raid (0.5.11 or 0.5.12rc1).

Jan 14 17:21:01 machinename kernel: hald[23198]: segfault at 0 ip 08077964 sp bffc1290 error 4 in hald[8048000+49000]

Using 0.5.12rc1 (+ 2.6.28 compilation fix, or git from similar period) and reverting this patch solves the problem.

http://cgit.freedesktop.org/hal/commit/?id=fd4305a59fd0f3b9e5a7a260707e11ffebc4926d

So far, cant locate the patch for vanilla 0.5.11, as it seems this patch is not in that version anyway, but it still segfaults.
on 0.5.11, helper utils do start (bad). on 0.5.12rc1, they dont because they realise hald crashed (good).

relevant lines in my fstab:
/dev/md0         /                reiserfs    defaults         1   1
/dev/md1         swap             swap        defaults         0   0
/dev/md2         /home            reiserfs    defaults         1   2

Also, patch in -stable would be awesome if possible. Don't know if this bug is specific to this machine (asus motherboard, 2x sata 1 tb samsung) or configuration.
please contact me for any details and/or testing requests.

gdb output

run --daemon=no --verbose=yes

09:34:18.079 [D] hotplug.c:449: event held back: /sys/devices/pci0000:00/0000:00:1f.2/host2/target2:0:0/2:0:0:0/block/sda/sda3
09:34:18.079 [I] hotplug.c:435: checking event /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb1
09:34:18.079 [D] hotplug.c:399: event /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb1 dependant on /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb
09:34:18.079 [D] hotplug.c:449: event held back: /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb1
09:34:18.079 [I] hotplug.c:435: checking event /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb2
09:34:18.079 [D] hotplug.c:399: event /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb2 dependant on /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb
09:34:18.079 [D] hotplug.c:449: event held back: /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb2
09:34:18.079 [I] hotplug.c:435: checking event /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb3
09:34:18.079 [D] hotplug.c:399: event /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb3 dependant on /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb
09:34:18.079 [D] hotplug.c:449: event held back: /sys/devices/pci0000:00/0000:00:1f.2/host3/target3:0:0/3:0:0:0/block/sdb/sdb3
09:34:18.079 [I] hotplug.c:435: checking event /sys/devices/virtual/block/md1/md1p1
09:34:18.079 [I] blockdev.c:904: block_add: sysfs_path=/sys/devices/virtual/block/md1/md1p1 dev=/dev/md1p1 is_part=1, parent=0x00000000
09:34:18.079 [I] blockdev.c:916: Handling /dev/md1p1 as MD device

Program received signal SIGSEGV, Segmentation fault.
0x0807c414 in hotplug_event_begin_add_blockdev ()
Current language:  auto; currently asm
(gdb) bt
#0  0x0807c414 in hotplug_event_begin_add_blockdev ()
#1  0x0806ba06 in hotplug_event_process_queue ()
#2  0x0806c1ad in process_coldplug_events ()
#3  0x0806d116 in coldplug_synthesize_events ()
#4  0x08068d9c in computer_probing_helper_done ()
#5  0x0805006b in process_reply ()
#6  0x08050091 in call_notify ()
#7  0xb7e213a1 in ?? () from /usr/lib/libdbus-1.so.3
#8  0x087352d8 in ?? ()
#9  0x087417e8 in ?? ()
#10 0xbf89ad78 in ?? ()
#11 0xb7e3aff4 in ?? () from /usr/lib/libdbus-1.so.3
#12 0xb7e3aff4 in ?? () from /usr/lib/libdbus-1.so.3
#13 0x087352d8 in ?? ()
#14 0xbf89ad78 in ?? ()
#15 0xb7e11eb3 in ?? () from /usr/lib/libdbus-1.so.3
#16 0x087352d8 in ?? ()
#17 0x087364d8 in ?? ()
#18 0x00000000 in ?? ()




                   HAL 0.5.12rc1
                  ==============

        prefix:                           /usr
        libdir:                           ${exec_prefix}/lib
        libexecdir:                       ${exec_prefix}/libexec
        bindir:                           ${exec_prefix}/bin
        sbindir:                          ${exec_prefix}/sbin
        datadir:                          ${datarootdir}
        sysconfdir:                       /etc
        localstatedir:                    /var
        docdir:                           /usr/doc/hal-0.5.12rc1
        dbus-1 system.d dir:              /etc/dbus-1/system.d
        pci.ids dir:                      /usr/share
        usb.ids dir:                      /usr/share

        compiler:                         gcc
        cflags:                           -O2 -march=i486 -mtune=i686 -Wall -Wchar-subscripts -Wmissing-declarations -Wnested-externs -Wpointer-arith -Wcast-align -Wsign-compare
        ldflags:                          -Wl,--as-needed
        cppflags:
        xmlto:                            /usr/bin/xmlto
        xmllint:                          /usr/bin/xmllint
        User for HAL:                     haldaemon
        Group for HAL:                    haldaemon
        hald pidfile:                     /var/run/hald.pid
        hald socket dir:                  /var/run/hald
        eject program:                    /usr/bin/eject

        OS backend:                       linux

        use acpi kernel interface:        yes
        use acpid interface:              yes
        use libusb:                       yes
        use libpci:                       yes
        use libparted:                    yes
        use gperf:                        yes
        use PolicyKit:                    no
        use ConsoleKit:                   yes
        use ACL management:               no
        use umount.hal helper:            yes
        use ACPI:                         yes
        use PMU:                          yes
        use APM:                          yes
        use Sony PIC:                     yes

        Macbook backlight support:        yes (Linux only, x86 only, requires libpci)
        Macbook Pro utils:                yes (Linux only, x86 only, requires libpci)
        iMac backlight support:           yes (Linux only, x86)
        OMAP utils:                       no (Linux only, arm only)
        CPU frequency scaling:            yes (Linux only)
        Re-map multimedia keys:           yes (Linux only, requires gperf)
        Forward IBM ACPI events:          no (Linux only)
        Forward Toshiba ACPI events:      no (Linux only)
        USB wireless mouse power:         yes (Linux only, requires libusb)
        Dell Backlight:                   no (Linux only, requires libsmbios >= 0.13.4)

        Support deprecated(removed) keys: no (via a FDI-file)

        Maintainer mode:                  no
        Building verbose mode:            yes
        Building api docs:                yes
        Building docs:                    yes
        Building man pages:               yes
Comment 1 Wojciech Pyczak 2009-02-04 02:46:33 UTC
I've the same problem. Yesterday I tried to setup new RAID10 array and hald (0.5.11) crashed immediately, however I'm not sure that it's caused by raid itself or because I used partitioned raid (I noticed that in your case it also crashed just after detecting /dev/md1p1). I suppose it's the latter since in other case this topic would be flooded right now. Anyway I'm going to confirm that later. 
Comment 2 Danny Kukawka 2009-06-04 01:30:19 UTC
This should be fixed now by:

http://cgit.freedesktop.org/hal/commit/?id=b35bf1fbfc000749010a27f3f35a95ddf6bb0b07


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.