Upstream commit 9f1b0f0f1ed should fix this segmentation fault:
http://neil.brown.name/git?p=mdadm;a=commitdiff;h=9f1b0f0f1ed0dd4752be65348a24971335cd50e8

This commit is included in 3.2.4 release, consider updating the whole
package.

FYI, below is a gdb stacktrace of mdadm 3.2.3-2ubuntu1:

#0  0x00007ffff7aa5b91 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007ffff7ae39c9 in fnmatch () from /lib/x86_64-linux-gnu/libc.so.6
#2  0x0000000000409e88 in match_oneof (devices=0x685179 ",/dev/sdb3,/dev/sdc3", 
devname=0x0) at config.c:959
#3  0x000000000040a1b3 in conf_match (st=0x685730, info=0x68da80, devname=0x0, 
verbose=0, rvp=0x0) at config.c:1050
#4  0x000000000044d10b in RebuildMap () at mapfile.c:434
#5  0x000000000044d585 in map_read (melp=0x7fffffffe560) at mapfile.c:201
#6  0x000000000044d67d in map_by_devnum (map=0x7fffffffe560, devnum=0) at 
mapfile.c:309
#7  0x0000000000407335 in main (argc=<optimized out>, argv=<optimized out>) at 
mdadm.c:1477

Source snippets:
#4: /* NB: 3rd argument is NULL */
                                struct mddev_ident *match = conf_match(st, info,
                                                                       NULL, 0,
                                                                       NULL);

#3:  /* NB: devname is a 3rd argument name, i.e. devname==NULL */
                if (array_list->devices &&
                    !match_oneof(array_list->devices, devname)) {

#2: /* NB: fnmatch() receives NULL as a 2nd argument, which leads to SIGSEGV */
                if (fnmatch(patn, devname, FNM_PATHNAME)==0)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/969384

Title:
  mdadm --detail --scan segfaults during update-initramfs

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mdadm/+bug/969384/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to