Bug 1747720

Summary: [abrt] systemd-udev: __openat_2(): systemd-udevd killed by SIGABRT
Product: [Fedora] Fedora Reporter: kxra
Component: systemdAssignee: systemd-maint
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 30CC: lnykryn, msekleta, ssahani, s, systemd-maint, zbyszek
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
URL: https://retrace.fedoraproject.org/faf/reports/bthash/d13a0d026f3329cd59e6e494162c4245899c5846
Whiteboard: abrt_hash:73bcad6286d43d0a5d36aa5d587cab18567bf7e3;VARIANT_ID=workstation;
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-09-12 15:55:26 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
File: backtrace
none
File: cgroup
none
File: core_backtrace
none
File: cpuinfo
none
File: dso_list
none
File: environ
none
File: limits
none
File: maps
none
File: mountinfo
none
File: open_fds
none
File: proc_pid_status none

Description kxra 2019-08-31 22:27:56 UTC
Version-Release number of selected component:
systemd-udev-241-8.git9ef65cb.fc30

Additional info:
reporter:       libreport-2.10.1
backtrace_rating: 4
cmdline:        /usr/lib/systemd/systemd-udevd
crash_function: __openat_2
executable:     /usr/lib/systemd/systemd-udevd
journald_cursor: s=7cebf7c1a8a349a4977f8a0cc2717160;i=6018;b=f0ccbe99978f442fac41cbeeb3db7e9b;m=23884ccc97;t=58b9e846b9237;x=a27d1916e90c3d56
kernel:         5.1.5-300.fc30.x86_64
rootdir:        /
runlevel:       N 5
type:           CCpp
uid:            0

Truncated backtrace:
Thread no. 1 (8 frames)
 #0 __openat_2 at openat_2.c:25
 #1 read at /usr/include/bits/unistd.h:44
 #2 flush_timer at ../src/libsystemd/sd-event/sd-event.c:2448
 #3 sd_event_wait at ../src/libsystemd/sd-event/sd-event.c:3135
 #4 sd_event_run at ../src/libsystemd/sd-event/sd-event.c:3284
 #5 sd_event_loop at ../src/libsystemd/sd-event/sd-event.c:3313
 #6 main_loop at ../src/udev/udevd.c:1729
 #7 run at ../src/udev/udevd.c:1849

Comment 1 kxra 2019-08-31 22:27:58 UTC
Created attachment 1610377 [details]
File: backtrace

Comment 2 kxra 2019-08-31 22:27:59 UTC
Created attachment 1610378 [details]
File: cgroup

Comment 3 kxra 2019-08-31 22:28:00 UTC
Created attachment 1610379 [details]
File: core_backtrace

Comment 4 kxra 2019-08-31 22:28:01 UTC
Created attachment 1610380 [details]
File: cpuinfo

Comment 5 kxra 2019-08-31 22:28:02 UTC
Created attachment 1610381 [details]
File: dso_list

Comment 6 kxra 2019-08-31 22:28:03 UTC
Created attachment 1610382 [details]
File: environ

Comment 7 kxra 2019-08-31 22:28:04 UTC
Created attachment 1610383 [details]
File: limits

Comment 8 kxra 2019-08-31 22:28:05 UTC
Created attachment 1610384 [details]
File: maps

Comment 9 kxra 2019-08-31 22:28:06 UTC
Created attachment 1610385 [details]
File: mountinfo

Comment 10 kxra 2019-08-31 22:28:07 UTC
Created attachment 1610386 [details]
File: open_fds

Comment 11 kxra 2019-08-31 22:28:08 UTC
Created attachment 1610387 [details]
File: proc_pid_status

Comment 12 Zbigniew Jędrzejewski-Szmek 2019-09-12 15:55:26 UTC

*** This bug has been marked as a duplicate of bug 1300212 ***

Comment 13 Zbigniew Jędrzejewski-Szmek 2019-10-24 10:51:01 UTC

*** This bug has been marked as a duplicate of bug 1747719 ***

Comment 14 Zbigniew Jędrzejewski-Szmek 2019-10-24 11:05:07 UTC
The traceback is pretty strange:

Program terminated with signal SIGABRT, Aborted.
#0  0x00007f55f5be1ec5 in __openat_2 (fd=11, file=0x7ffe29b8c3f0 "\001", oflag=8) at openat_2.c:25
25	  if (__OPEN_NEEDS_MODE (oflag))

Thread 1 (Thread 0x7f55f4bf0940 (LWP 5409)):
#0  0x00007f55f5be1ec5 in __openat_2 (fd=11, file=0x7ffe29b8c3f0 "\001", oflag=8) at openat_2.c:25
No locals.
#1  0x00007f55f58c5d75 in read (__nbytes=<optimized out>, __buf=<optimized out>, __fd=<optimized out>, __fd=<optimized out>, __buf=<optimized out>, __nbytes=<optimized out>) at /usr/include/bits/unistd.h:44
No locals.
#2  flush_timer (e=e@entry=0x55b73f806360, fd=<optimized out>, events=<optimized out>, next=next@entry=0x0) at ../src/libsystemd/sd-event/sd-event.c:2448
        x = 1
        ss = <optimized out>
        __PRETTY_FUNCTION__ = "flush_timer"
#3  0x00007f55f58cc770 in sd_event_wait (e=e@entry=0x55b73f806360, timeout=timeout@entry=18446744073709551615) at ../src/libsystemd/sd-event/sd-event.c:3135
        ev_queue = 0x7ffe29b8c410
        ev_queue_max = <optimized out>
        r = <optimized out>
        m = <optimized out>
        i = <optimized out>
        __PRETTY_FUNCTION__ = "sd_event_wait"

But looking at the code in flush_timer(), we just call read() with a stack variable being the output,
so the output buffer is OK. fd=11 implies that fd is OK. open_fds lists 11:anon_inode:[timerfd].
So I think it got the ABRT signal while blocked on the read, but for some reason gdb misinterprets
that as open(). Most likely the two functions were sharing some code as a result of optimization.
So closing it as DUPLICATED seems ok.

*** This bug has been marked as a duplicate of bug 1300212 ***