Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1690486 - dracut-install segfault on install of kernel-core-4.20.16-200.fc29.armv7hl
Summary: dracut-install segfault on install of kernel-core-4.20.16-200.fc29.armv7hl
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: dracut
Version: 28
Hardware: armv7hl
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: dracut-maint-list
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-03-19 14:53 UTC by phaet0n
Modified: 2019-04-01 03:06 UTC (History)
5 users (show)

Fixed In Version: dracut-049-26.git20181204.fc29.armv7hl
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-04-01 03:06:42 UTC


Attachments (Terms of Use)

Description phaet0n 2019-03-19 14:53:31 UTC
1) Working install of fedora 29 on a cubox i.mx6 device.
2) dnf upgrade ---> went to install kernel-4.20.16-200
3) On scriptlet for kernel-core-4.20.16-200.fc29.armv7hl

  Running scriptlet: kernel-core-4.20.16-200.fc29.armv7hl                   3/3
/usr/lib/dracut/dracut-init.sh: line 969:  9813 Segmentation fault      (core dumped) $DRACUT_INSTALL ${initdir:+-D "$initdir"} ${loginstall:+-L "$loginstall"} ${hostonly:+-H} ${omit_drivers:+-N "$omit_drivers"} ${srcmods:+--kerneldir "$srcmods"} ${_optional:+-o} ${_silent:+--silent} -m "$@"
dracut: FAILED:  /usr/lib/dracut/dracut-install -D /var/tmp/dracut.hM2FWR/initramfs --kerneldir /lib/modules/4.20.16-200.fc29.armv7hl/ -o -m sr_mod sd_mod scsi_dh ata_piix hid_generic unix ehci-hcd ehci-pci ehci-platform ohci-hcd ohci-pci uhci-hcd xhci-hcd xhci-pci xhci-plat-hcd =drivers/pinctrl

4) dnf continues and install "succeeds", however I uninstalled because this error spooked me, and I don't want a reboot to fail in case of problems.

Sorry I am not super experienced to diagnose further.

Comment 1 Andrew Clayton 2019-03-19 21:06:26 UTC
Same thing on a BeagleBone Black

  Running scriptlet: kernel-core-4.20.16-200.fc29.armv7hl                   3/3 
/usr/lib/dracut/dracut-init.sh: line 969: 13129 Segmentation fault      (core dumped) $DRACUT_INSTALL ${initdir:+-D "$initdir"} ${loginstall:+-L "$loginstall"} ${hostonly:+-H} ${omit_drivers:+-N "$omit_drivers"} ${srcmods:+--kerneldir "$srcmods"} ${_optional:+-o} ${_silent:+--silent} -m "$@"
dracut: FAILED:  /usr/lib/dracut/dracut-install -D /var/tmp/dracut.PzN8xP/initramfs --kerneldir /lib/modules/4.20.16-200.fc29.armv7hl/ -o -m sr_mod sd_mod scsi_dh ata_piix hid_generic unix ehci-hcd ehci-pci ehci-platform ohci-hcd ohci-pci uhci-hcd xhci-hcd xhci-pci xhci-plat-hcd =drivers/pinctrl

  Running scriptlet: kernel-4.20.16-200.fc29.armv7hl                        3/3 

Looking at the installed initramfs, it looked about right

-rw-------   1 root root 17875745 Mar 19 19:56 initramfs-4.20.16-200.fc29.armv7hl.img

The initramfs also ran through lsinitrd without error and also a manual zcat and cpio without error and both showed roughly expected contents.

So I took the plunge and rebooted (this is about an hours drive away!)

Fortunately it came back up OK.

$ uname -r
4.20.16-200.fc29.armv7hl

dracut is dracut-049-25.git20181204.fc29.armv7hl installed Tue 11 Dec 2018 02:17:48 GMT and will have installed numerous kernels since then.

Though the only core files I found is from this run.

Here's the backtrace from gdb (it's /usr/lib/dracut/dracut-install that is segfaulting)

Core was generated by `/usr/lib/dracut/dracut-install -D /var/tmp/dracut.F1k1nq/initramfs --kerneldir'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  string_hash_func (p=0x0) at install/hashmap.c:130
130             for (c = p; *c; c++)
(gdb) bt
#0  string_hash_func (p=0x0) at install/hashmap.c:130
#1  0x00455198 in hashmap_get (h=0xb6caa43c, key=0x0) at install/hashmap.c:362
#2  0x00450a08 in check_hashmap (hm=<optimized out>, item=0x0)
    at install/dracut-install.c:591
#3  0x00452d60 in install_dependent_modules (modlist=0x23574d8)
    at install/dracut-install.c:1247
#4  0x0045347c in install_module (mod=0x2351fe8)
    at install/dracut-install.c:1335
#5  0x0045391c in install_modules (argc=16, argv=<optimized out>)
    at install/dracut-install.c:1673
#6  0x0044f1d4 in main (argc=<optimized out>, argv=0xbef47ec4)
    at install/dracut-install.c:1805

and a full backtrace

(gdb) bt full
#0  string_hash_func (p=0x0) at install/hashmap.c:130
        hash = 5381
        c = 0x0
#1  0x00455198 in hashmap_get (h=0xb6caa43c, key=0x0) at install/hashmap.c:362
        hash = <optimized out>
        e = <optimized out>
#2  0x00450a08 in check_hashmap (hm=<optimized out>, item=0x0)
    at install/dracut-install.c:591
        existing = <optimized out>
#3  0x00452d60 in install_dependent_modules (modlist=0x23574d8)
    at install/dracut-install.c:1247
        mod = 0x23572d8
        itr = 0x23574d8
        path = 0x0
        name = <optimized out>
        ret = <optimized out>
        __func__ = "install_dependent_modules"
#4  0x0045347c in install_module (mod=0x2351fe8)
    at install/dracut-install.c:1335
        ret = 0
        modlist = 0x0
        modpre = 0x23574d8
        modpost = 0x0
        path = <optimized out>
        name = <optimized out>
        __func__ = "install_module"
#5  0x0045391c in install_modules (argc=16, argv=<optimized out>)
    at install/dracut-install.c:1673
        modlist = 0x2356e00
        modname = <optimized out>
        r = <optimized out>
        ret = -1
        ctx = 0x2350260
        itr = 0x2356e00
        mod = 0x2351fe8
        mod_o = 0x0
        abskpath = <optimized out>
        p = <optimized out>
        i = 4632600
        modinst = <optimized out>
        __func__ = "install_modules"
#6  0x0044f1d4 in main (argc=<optimized out>, argv=0xbef47ec4)
    at install/dracut-install.c:1805
        r = 0
        i = 0x234f150 "h\361\064\002d\361\064\002h\361\064\002\001"
        path = <optimized out>
        __func__ = "main"

Comment 2 Russell Odom 2019-03-26 13:05:33 UTC
This looks to be the same as bug 1676357, which is (for me) fixed.


Note You need to log in before you can comment on or make changes to this bug.