Bug 862678

Summary: systemd SEGV
Product: [openSUSE] openSUSE 13.1 Reporter: Juergen Weigert <jw>
Component: BasesystemAssignee: systemd maintainers <systemd-maintainers>
Status: RESOLVED DUPLICATE QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: suse-beta
Version: Final   
Target Milestone: ---   
Hardware: i686   
OS: openSUSE 13.1   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Bug Depends on:    
Bug Blocks: 357354    

Description Juergen Weigert 2014-02-06 22:16:55 UTC
After resume, XFCE tells me networking is disabled.
Starting the network from the icon changes nothing. 

Shutdown also fails. cannot communicate with /etc/initctl.

/var/log/messages has this:
2014-02-04T11:02:39.555791+01:00 d237 kernel: [62341.358846] PM: resume of devices complete after 1424.281 msecs
2014-02-04T11:02:39.555794+01:00 d237 kernel: [62341.359211] PM: Finishing wakeup.
2014-02-04T11:02:39.555797+01:00 d237 kernel: [62341.359214] Restarting tasks ... 
2014-02-04T11:02:39.555800+01:00 d237 kernel: [62341.359285] traps: systemd[1] general protection ip:b7605e58 sp:bff6f1d8 error:0 in libc-2.18.so[b74bc000+1ab000]
2014-02-04T11:02:39.558355+01:00 d237 systemd-logind[1145]: Lid opened.
2014-02-04T11:02:39.567992+01:00 d237 kernel: [62341.367401] done.
2014-02-04T11:02:39.568015+01:00 d237 kernel: [62341.367418] video LNXVIDEO:00: Restoring backlight state
2014-02-04T11:02:39.607364+01:00 d237 systemd[1]: Caught <SEGV>, dumped core as pid 30546.
2014-02-04T11:02:39.608940+01:00 d237 systemd[1]: Freezing execution.
2014-02-04T11:02:39.687066+01:00 d237 laptop-mode: Warning: Configuration file /etc/laptop-mode/conf.d/board-specific/* is not readable, skipping.

Starting systemd manually does not change anything.
Apparently a hard reset is necessary once systemd dies.
Comment 1 Dr. Werner Fink 2014-02-11 07:55:48 UTC
To which process belongs pid 30546?

And why does a process try to use /etc/initctl instead of /dev/initctl?

Please attach the core dump and the exact version of the systemd packages.
Comment 2 Juergen Weigert 2014-02-11 11:57:55 UTC
It is /dev/initctl, of course. Sorry. 

Happened again yesterday. Another symptom:
Many processes hang in '[defunct]' with parent pid 1.

/var/log/messages has:
2014-02-11T11:56:21.525652+01:00 d237 systemd[1]: Caught <SEGV>, dumped core as pid 10497.
2014-02-11T11:56:21.528194+01:00 d237 systemd[1]: Freezing execution.

ls -l /core
-rw------- 1 root root 18526208 Feb 11 11:56 /core

sudo file /core 
/core: ELF 32-bit LSB core file Intel 80386, version 1 (SYSV), SVR4-style, from '/sbin/init showopts'

rpm -qi systemd
Name        : systemd
Version     : 208
Release     : 15.1
Architecture: i586
Install Date: Wed 22 Jan 2014 05:26:10 PM CET
Group       : System/Base
Size        : 6381939
License     : LGPL-2.1+
Signature   : RSA/SHA256, Mon 23 Dec 2013 03:21:11 PM CET, Key ID b88b2fd43dbdc284
Source RPM  : systemd-208-15.1.src.rpm
Build Date  : Mon 16 Dec 2013 05:11:13 PM CET
Build Host  : cloud135
Relocations : (not relocatable)
Packager    : http://bugs.opensuse.org
Vendor      : openSUSE
URL         : http://www.freedesktop.org/wiki/Software/systemd
Summary     : A System and Session Manager
Description :
Systemd is a system and service manager, compatible with SysV and LSB
init scripts for Linux. systemd provides aggressive parallelization
capabilities, uses socket and D-Bus activation for starting services,
offers on-demand starting of daemons, keeps track of processes using
Linux cgroups, supports snapshotting and restoring of the system state,
maintains mount and automount points and implements an elaborate
transactional dependency-based service control logic. It can work as a
drop-in replacement for sysvinit.
Distribution: openSUSE 13.1
Comment 3 Dr. Werner Fink 2014-02-11 12:24:54 UTC
(In reply to comment #2)

 linux:~ # /sbin/init showopts
 Expected single character argument.
 linux:~ # rpm -q --changelog systemd | head -n 3
 * Mon Feb 10 2014 werner@suse.de
 - Add patch 0145-logind-use-correct-who-enum-values-with-KillUnit.patch
   to be able to kill sessions (bnc#860574)

btw: Where is the core dump attached plus the used systemd version or install the debuginfo as well as the debugsource and help me to debug this.
Comment 4 Juergen Weigert 2014-02-11 14:18:22 UTC
Core file upload failed in bugzilla, after a long wait, sorry. It succeeds immediatly here:
https://www.dropbox.com/s/5uwtsqt1woyv1rc/systemd-init-core.10497

With the available debuginfo package, gdb can only say this:

Core was generated by `/sbin/init showopts'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0xb7746424 in __kernel_vsyscall ()
(gdb) quit

A long list of zypper commands is suggested. They all fail to bring in additional debuginfo: E.g. No provider of 'debuginfo(build-id) = b76532d3fe2dbe8e7e7ad0a95ab07c019a3fbb67' found.
Comment 5 Dr. Werner Fink 2014-02-11 15:05:30 UTC
(In reply to comment #4)

What does

       rpm -qi systemd

show to you?  Please show me also.
Comment 6 Dr. Werner Fink 2014-02-11 15:08:12 UTC
Beside this you may miss some repositories like openSUSE-13.1-Debug and openSUSE-13.1-Update-Debug
Comment 7 Dr. Werner Fink 2014-02-11 15:20:01 UTC
 ELF 32-bit LSB
Comment 8 Dr. Werner Fink 2014-02-11 15:23:19 UTC
Maybe a dup of bug #861488 ?
Comment 9 Dr. Werner Fink 2014-02-11 16:04:28 UTC
I've found

   http://ftp5.gwdg.de/pub/opensuse/debug/update/13.1/i586/
   http://ftp5.gwdg.de/pub/opensuse/update/13.1/i586/

very useful.  With this it should be possible to get the appropiate packages.
Comment 10 Juergen Weigert 2014-02-11 16:06:02 UTC
(In reply to comment #5)
> (In reply to comment #4)
> 
> What does
> 
>        rpm -qi systemd
> 
> show to you?  Please show me also.

> rpm -qi systemd
Name        : systemd
Version     : 208
Release     : 15.1
Architecture: i586
Install Date: Wed 22 Jan 2014 05:26:10 PM CET
Group       : System/Base
Size        : 6381939
License     : LGPL-2.1+
Signature   : RSA/SHA256, Mon 23 Dec 2013 03:21:11 PM CET, Key ID b88b2fd43dbdc284
Source RPM  : systemd-208-15.1.src.rpm
Build Date  : Mon 16 Dec 2013 05:11:13 PM CET
Build Host  : cloud135
Relocations : (not relocatable)
Packager    : http://bugs.opensuse.org
Vendor      : openSUSE
URL         : http://www.freedesktop.org/wiki/Software/systemd
Summary     : A System and Session Manager
Description :
Systemd is a system and service manager, compatible with SysV and LSB
init scripts for Linux. systemd provides aggressive parallelization
capabilities, uses socket and D-Bus activation for starting services,
offers on-demand starting of daemons, keeps track of processes using
Linux cgroups, supports snapshotting and restoring of the system state,
maintains mount and automount points and implements an elaborate
transactional dependency-based service control logic. It can work as a
drop-in replacement for sysvinit.
Distribution: openSUSE 13.1
Comment 11 Juergen Weigert 2014-02-11 16:20:31 UTC
Both openSUSE-13.1-Update-Debug and openSUSE-13.1-Debug from opensuse.org are already here. Thanks for the tip with gwdg! Now I can pull some of the dependencies that gdb asks for. Here is what I get:

#0  0xb7746424 in __kernel_vsyscall ()
#1  0xb7630276 in raise (sig=sig@entry=11)
    at ../nptl/sysdeps/unix/sysv/linux/pt-raise.c:37
#2  0x08052a88 in crash (sig=11) at src/core/main.c:143
#3  <signal handler called>
#4  __strnlen_sse2 () at ../sysdeps/i386/i686/multiarch/strlen-sse2.S:125
#5  0xb74b47c6 in _IO_vfprintf_internal (s=s@entry=0xbfcfa920, 
    format=<optimized out>, 
    format@entry=0x8117dec "PRIORITY=%i\nSYSLOG_FACILITY=%i\n%s%.*s%s%s%.*i%s%s%.*s%s%s%.*s%sSYSLOG_IDENTIFIER=%s\n", ap=0xbfcfaa78 "V\216\021\b\326|\021\b\001", 
    ap@entry=0xbfcfaa64 "\006") at vfprintf.c:1629
#6  0xb756d580 in ___vsnprintf_chk (
    s=s@entry=0xbfcfadec "PRIORITY=6\nSYSLOG_FACILITY=3\nCODE_FILE=\bl", 
    maxlen=<optimized out>, maxlen@entry=2048, flags=flags@entry=1, 
    slen=slen@entry=4294967295, 
    format=format@entry=0x8117dec "PRIORITY=%i\nSYSLOG_FACILITY=%i\n%s%.*s%s%s%.*i%s%s%.*s%s%s%.*s%sSYSLOG_IDENTIFIER=%s\n", args=args@entry=0xbfcfaa64 "\006")
    at vsnprintf_chk.c:63
#7  0xb756d4a7 in ___snprintf_chk (
    s=s@entry=0xbfcfadec "PRIORITY=6\nSYSLOG_FACILITY=3\nCODE_FILE=\bl", 
    maxlen=maxlen@entry=2048, flags=flags@entry=1, slen=slen@entry=4294967295, 
    format=format@entry=0x8117dec "PRIORITY=%i\nSYSLOG_FACILITY=%i\n%s%.*s%s%s%.*i%s%s%.*s%s%s%.*s%sSYSLOG_IDENTIFIER=%s\n") at snprintf_chk.c:34
#8  0x080b8235 in snprintf (
    __fmt=0x8117dec "PRIORITY=%i\nSYSLOG_FACILITY=%i\n%s%.*s%s%s%.*i%s%s%.*s%s%s%.*s%sSYSLOG_IDENTIFIER=%s\n", __n=2048, 
    __s=0xbfcfadec "PRIORITY=6\nSYSLOG_FACILITY=3\nCODE_FILE=\bl")
    at /usr/include/bits/stdio2.h:64
#9  log_do_header (
    header=header@entry=0xbfcfadec "PRIORITY=6\nSYSLOG_FACILITY=3\nCODE_FILE=\bl", level=level@entry=30, file=file@entry=0x80e5c6e "src/core/manager.c", 
    line=line@entry=1736, 
    func=func@entry=0x80e7556 <__func__.13183> "process_event", 
    object_name=object_name@entry=0x0, object=object@entry=0x0, size=2048)
    at src/shared/log.c:445
#10 0x080b99d9 in log_struct_internal (level=30, level@entry=6, 
    file=file@entry=0x80e5c6e "src/core/manager.c", line=line@entry=1736, 
    func=func@entry=0x80e7556 <__func__.13183> "process_event", 
    format=format@entry=0x80e6bf0 "MESSAGE_ID=%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x") at src/shared/log.c:750
#11 0x0805a66d in process_event (ev=0xbfcfb6a8, m=<optimized out>)
    at src/core/manager.c:1733
#12 manager_loop (m=0x8ddd658) at src/core/manager.c:1858
#13 0x080505e3 in main (argc=2, argv=0xbfcfbbc4) at src/core/main.c:1652
Comment 12 Dr. Werner Fink 2014-02-11 16:29:01 UTC
Compare with https://bugzilla.novell.com/show_bug.cgi?id=861488#c5  ... 

I'd like to see this a duplicate ;)
Comment 13 Dr. Werner Fink 2014-02-11 16:49:51 UTC
dup of bnc #861488

*** This bug has been marked as a duplicate of bug 861488 ***
Comment 14 Dr. Werner Fink 2014-02-11 17:14:10 UTC
Correct to the first occurrence

*** This bug has been marked as a duplicate of bug 851044 ***
Comment 15 Juergen Weigert 2014-02-11 17:17:41 UTC
yes, its a dup. My machine: historic 32bit, Lenovo X60s.