Bug 823795

Summary: systemd-logind first start fails which causes plasma-desktop to crash if logging immediately after system starts up
Product: [Fedora] Fedora Reporter: Michal Piotrowski <bastian_knight>
Component: systemdAssignee: Than Ngo <than>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: unspecified    
Version: 16CC: johannbg, jreznik, kevin, lpoetter, ltinkl, metherid, mschmidt, notting, plautrba, rdieter, rnovacek, systemd-maint, than
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-11 12:33:06 UTC Type: Bug
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
plasma-desktop stack trace
none
NetworkManager crash info from /var/log/messages
none
A copy of /var/log/messages
none
dmesg with systemd debug logging
none
systemctl dump
none
output of /bin/systemd --test --system --log-level=debug none

Description Michal Piotrowski 2012-05-22 07:36:57 UTC
Created attachment 585948 [details]
plasma-desktop stack trace

Description of problem:
If I log in to KDE desktop immediately after system starts up, plasma-desktop crashes. Subsequent log ins don't cause the crash. Furthemore, if I wait some time after system start, then log to KDE desktop, the crash also does not occur.

Based on stack trace and /var/log/messages I suspect a problem with an interaction with NetworkManager. I am not sure which component is the cause of the crash: KDE or NetworkManager.

Version-Release number of selected component (if applicable):
kde-workspace-4.8.3-3.fc16.x86_64
NetworkManager-0.9.4-3.git20120403.fc16.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Log in to KDE desktop immediately after system starts up (the faster the better chance to reproduce the problem)
  
Actual results:
plasma-desktop crashes

Expected results:
plasma-desktop doesn't crash

Additional info:
I am attaching plasma-desktop stack-trace and relevant information from /var/log/messages

Comment 1 Michal Piotrowski 2012-05-22 08:02:40 UTC
Created attachment 585956 [details]
NetworkManager crash info from /var/log/messages

I attach relevant info from /var/log/messages about NetworkManager crash which occured at the same time as plasma-desktop crash.

I tried to install debug symbols for NetworkManager, but after that the crashes for NetworkManager weren't logged to /var/log/messages. plasma-desktop crashed as before, as explained in the report.

Comment 2 Kevin Kofler 2012-05-22 08:19:17 UTC
Both the crashes are inside D-Bus code, I wonder whether there's something wrong with D-Bus.

Comment 3 Michal Piotrowski 2012-05-22 08:38:32 UTC
Is it possible that systemd doesn't start D-Bus fast enough or that systemd doesn't wait for D-Bus to be fully started before displaying login screen?

Comment 4 Michal Piotrowski 2012-05-25 06:26:09 UTC
I have found out, that crash occurs when systemd-logind.service is in a failed state. The service always fails when it starts for the first time. Therefore I changed the description and component of the bug. I will attach systemd log files shortly.

Comment 5 Michal Piotrowski 2012-05-25 06:28:55 UTC
Created attachment 586776 [details]
A copy of /var/log/messages

A full copy of /var/log/message from one boot

Comment 6 Michal Piotrowski 2012-05-25 06:30:08 UTC
Created attachment 586777 [details]
dmesg with systemd debug logging

Comment 7 Michal Piotrowski 2012-05-25 06:31:21 UTC
Created attachment 586778 [details]
systemctl dump

Comment 8 Michal Piotrowski 2012-05-25 06:32:34 UTC
Created attachment 586779 [details]
output of /bin/systemd --test --system --log-level=debug

Comment 9 Michal Schmidt 2012-05-25 09:08:45 UTC
This is an unusual error:

[   22.913291] systemd[1]: RequestName() failed: Access denied

Do you have the pristine file /etc/dbus-1/system.d/org.freedesktop.systemd1.conf or are there any modifications or a possible corruption?

Comment 10 Michal Piotrowski 2012-05-26 05:53:23 UTC
I have the pristine file /etc/dbus-1/system.d/org.freedesktop.systemd1.conf. I have compared my file with the one from downloaded RPM package (systemd-37-19.fc16.x86_64.rpm) and the files are identical.

Comment 11 Lennart Poettering 2012-05-31 00:04:06 UTC
My guess is that some package installed a bogus D-Bus policy file which corrupts the whole boot.

Comment 12 Michal Schmidt 2012-06-07 07:36:26 UTC
Let's see what policy D-Bus files are there. Could you attach a tarball of everything in /etc/dbus-1/ ?

Comment 13 Michal Piotrowski 2012-06-11 12:33:06 UTC
I have upgraded my Fedora installation in the meantime and the problem doesn't appear in Fedora 17. Therefore I think I should close the bug and mark it as next release.