Bug 1215845

Summary: lightdm: no Xserver restart when killing Xserver
Product: [openSUSE] openSUSE Tumbleweed Reporter: Stefan Seyfried <seife>
Component: X11 ApplicationsAssignee: Alexei Sorokin <sor.alexei>
Status: IN_PROGRESS --- QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P3 - Medium CC: mrmazda, seife
Version: Current   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Stefan Seyfried 2023-09-30 16:49:34 UTC
seife@strolchi:~> rpm -qf /usr/lib/systemd/system/display-manager.service
xdm-1.1.14-4.3.x86_64
seife@strolchi:~> grep OnFai /usr/lib/systemd/system/display-manager.service
OnFailure=plymouth-quit.service

I killed the lightdm login screen with ctrl-alt-backspace and it did not come back again.

Investigating, I found this in the journal:

Sep 30 18:34:57 strolchi lightdm[1475]: pam_unix(lightdm-greeter:session): session closed for user lightdm
Sep 30 18:34:57 strolchi systemd[1]: session-1.scope: Deactivated successfully.
Sep 30 18:34:57 strolchi systemd[1]: session-1.scope: Consumed 1.622s CPU time.
Sep 30 18:34:57 strolchi systemd-logind[1135]: Session 1 logged out. Waiting for processes to exit.
Sep 30 18:34:57 strolchi systemd-logind[1135]: Removed session 1.
Sep 30 18:34:57 strolchi display-manager[1353]: Starting service lightdm
Sep 30 18:34:57 strolchi systemd[1]: display-manager.service: Main process exited, code=exited, status=1/FAILURE
Sep 30 18:34:57 strolchi systemd[1]: display-manager.service: Failed with result 'exit-code'.
Sep 30 18:34:58 strolchi systemd[1]: display-manager.service: Triggering OnFailure= dependencies.
Sep 30 18:34:58 strolchi systemd[1]: display-manager.service: Failed to enqueue OnFailure= job, ignoring: Unit plymouth-quit.service not found.
Sep 30 18:34:58 strolchi systemd[1]: display-manager.service: Consumed 1.290s CPU time.

I think however that the OnFailure failure is not the reason for the problem but that the display-manager.service should have a "Restart=on-failure" line.

current tumbleweed, xfce4 desktop, lightdm login manager
strolchi:~ # head -3 /etc/os-release
NAME="openSUSE Tumbleweed"
# VERSION="20230927"
ID="opensuse-tumbleweed"
Comment 1 Stefan Dirsch 2023-10-01 12:38:17 UTC
Hmm. Killing it once should not terminate the display manager. Could you please check this behaviour with a displaymanager like xdm or gdm? 

I know that these are adjusted to terminate themselves if X crashes 3 times in a row in a short amount of time. So you have a chance to get into the system on Linux console. But not after killing X once ...
Comment 2 Stefan Seyfried 2023-10-02 10:05:35 UTC
lightdm: ctrl-alt-backspace twice => lightdm exits
xdm: ctrl-alt-backspace twice => xdm restarts
  repeat, third time xdm exits.

So might be a lightdm issue.
Comment 3 Stefan Dirsch 2023-10-02 10:23:29 UTC
Reassigning to maintainer of lightdm.