<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>488853</bug_id>
          
          <creation_ts>2024-06-21 01:41:38 +0000</creation_ts>
          <short_desc>Plasma X11 with Session Restore enabled fails to shutdown/logout/restart, keeps hanging at black screen with mouse cursor</short_desc>
          <delta_ts>2024-10-02 20:02:02 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Plasma</classification>
          <product>plasmashell</product>
          <component>Session Management</component>
          <version>6.1.4</version>
          <rep_platform>Neon</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.kde.org/show_bug.cgi?id=487912</see_also>
    
    <see_also>https://bugs.gentoo.org/show_bug.cgi?id=938925</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>regression</keywords>
          <priority>VHI</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>1.0</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ham L.">thetechguy1011</reporter>
          <assigned_to name="Plasma Bugs List">plasma-bugs-null</assigned_to>
          <cc>asturm</cc>
    
    <cc>breakingspell</cc>
    
    <cc>carlosd.kde</cc>
    
    <cc>gj.eldering</cc>
    
    <cc>hiphish</cc>
    
    <cc>jr</cc>
    
    <cc>kde</cc>
    
    <cc>kdedev</cc>
    
    <cc>keplicz</cc>
    
    <cc>mark.coetsee</cc>
    
    <cc>mwoodj</cc>
    
    <cc>natalie_clarius</cc>
    
    <cc>nate</cc>
    
    <cc>neon-bugs-null</cc>
    
    <cc>nylle</cc>
    
    <cc>qydwhotmail</cc>
    
    <cc>root</cc>
    
    <cc>stevee</cc>
    
    <cc>svkatz80</cc>
    
    <cc>thetechguy1011</cc>
          
          <cf_commitlink>https://invent.kde.org/plasma/plasma-workspace/-/commit/792586f26e532dc049fc2f613d9a77db976f9054</cf_commitlink>
          <cf_versionfixedin>6.2.0</cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2330014</commentid>
    <comment_count>0</comment_count>
    <who name="Ham L.">thetechguy1011</who>
    <bug_when>2024-06-21 01:41:38 +0000</bug_when>
    <thetext>***
If you&apos;re not sure this is actually a bug, instead post about it at https://discuss.kde.org

If you&apos;re reporting a crash, attach a backtrace with debug symbols; see https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***

SUMMARY
In KDE Neon 6.1, when I&apos;m trying to make use of X11 instead of Wayland, I cannot logout, shutdown, or restart normally. Wayland is NOT impacted.

STEPS TO REPRODUCE
1. Upon reaching the login screen, specify the Plasma (X11) desktop environment.
2. Complete the login process, activating aforementioned desktop environment.
3. Attempt to logout, shutdown, or restart.

OBSERVED RESULT
Black screen with cursor still present. The kwin/ksmserver process does not appear to terminate at all, leaving the default tty2 unusable.

EXPECTED RESULT
kwin/ksmserver should terminate gracefully and swiftly instead of hanging and not doing anything else, completing the logout/shutdown/restart action.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: KDE Neon
KDE Plasma Version: 6.1.0
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.0

ADDITIONAL INFORMATION

WORKAROUNDS USED
To complete the process, I either need to send a SIGHUP, SIGTERM, or SIGKILL to /usr/bin/ksmserver to achieve a logout, or pass the `reboot` or `shutdown` commands to another tty session.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2330145</commentid>
    <comment_count>1</comment_count>
    <who name="nyl">nylle</who>
    <bug_when>2024-06-21 09:36:42 +0000</bug_when>
    <thetext>can confirm this x11 arch linux kde plasma 6.1 kwin, logout prompt failing see here:
https://0x0.st/XTdh.txt
full session journal:
https://0x0.st/XTdO.txt</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2330740</commentid>
    <comment_count>2</comment_count>
    <who name="Darius">root</who>
    <bug_when>2024-06-22 20:30:41 +0000</bug_when>
    <thetext>I can also confirm this, same log as @nyl</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2330750</commentid>
    <comment_count>3</comment_count>
    <who name="VK">svkatz80</who>
    <bug_when>2024-06-22 21:02:04 +0000</bug_when>
    <thetext>Same problem on amdgpu, but no such problem on nvidia.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2330778</commentid>
    <comment_count>4</comment_count>
    <who name="nyl">nylle</who>
    <bug_when>2024-06-23 02:34:20 +0000</bug_when>
    <thetext>(In reply to VK from comment #3)
&gt; Same problem on amdgpu, but no such problem on nvidia.

I can confirm problem DOES exist on nvidia</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2332571</commentid>
    <comment_count>5</comment_count>
    <who name="VK">svkatz80</who>
    <bug_when>2024-06-27 10:54:37 +0000</bug_when>
    <thetext>On plasma-workspace 6.1.1-1 and 6.1.0-1 the problem still exists.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2332982</commentid>
    <comment_count>6</comment_count>
    <who name="Michael Wood">mwoodj</who>
    <bug_when>2024-06-28 07:20:25 +0000</bug_when>
    <thetext>I am running Plasma 6.1.1 with nvidia 555 driver. Logout fails on x11 but works properly with wayland.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2338214</commentid>
    <comment_count>7</comment_count>
    <who name="Piotr Keplicz">keplicz</who>
    <bug_when>2024-07-18 11:48:35 +0000</bug_when>
    <thetext>I experience similar problems. Session doesn&apos;t end when logging out, leaves a blank screen with the mouse cursor. I&apos;m using X11, happens with and without the external screen attached.

Using KDE neon with Plasma 6.1.2, problems started after an upgrade to 6.1.0.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2342541</commentid>
    <comment_count>8</comment_count>
    <who name="VK">svkatz80</who>
    <bug_when>2024-08-02 16:24:13 +0000</bug_when>
    <thetext>On plasma-workspace 6.1.3-1 the problem still exists.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2342557</commentid>
    <comment_count>9</comment_count>
    <who name="VK">svkatz80</who>
    <bug_when>2024-08-02 16:43:49 +0000</bug_when>
    <thetext>In System settings &gt; Session &gt; Desktop Session, select &apos;Start with an empty session&apos; and reboot. 
The problem disappears: plasma &apos;Restart&apos; and &apos;Shut down&apos; work as expected.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2344379</commentid>
    <comment_count>10</comment_count>
    <who name="Ham L.">thetechguy1011</who>
    <bug_when>2024-08-09 13:24:00 +0000</bug_when>
    <thetext>So this bug exists across all graphical environments (Intel, nVidia, AMD) and still exists on the latest version of Plasma, breaking session saving. Can we get this escalated somehow?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2344401</commentid>
    <comment_count>11</comment_count>
    <who name="Gerrit Jan">gj.eldering</who>
    <bug_when>2024-08-09 14:55:06 +0000</bug_when>
    <thetext>On openSUSE Slowroll i have the same problem.
When I activate “manually saved session”, the shutdown fails.
However, if I set it to “at last logout” everything works fine.
The latest Slowroll, did not solved the problem!</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2351596</commentid>
    <comment_count>12</comment_count>
    <who name="Andreas Sturmlechner">asturm</who>
    <bug_when>2024-09-05 11:44:32 +0000</bug_when>
    <thetext>Reverting https://invent.kde.org/plasma/plasma-workspace/-/commit/0857d18dfc3fc870a7f768731fdf46dc3abc5f8f was shown to &quot;fix&quot; this problem, but of course it is no solution.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2351645</commentid>
    <comment_count>13</comment_count>
    <who name="Bug Janitor Service">bug-janitor</who>
    <bug_when>2024-09-05 14:44:12 +0000</bug_when>
    <thetext>A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4684</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2351647</commentid>
    <comment_count>14</comment_count>
    <who name="Fushan Wen">qydwhotmail</who>
    <bug_when>2024-09-05 14:45:27 +0000</bug_when>
    <thetext>Any affected user can test https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4684 ?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2357557</commentid>
    <comment_count>15</comment_count>
    <who name="Bug Janitor Service">bug-janitor</who>
    <bug_when>2024-09-20 03:47:00 +0000</bug_when>
    <thetext>🐛🧹 ⚠️ This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information, then set the bug status to REPORTED. If there is no change for at least 30 days, it will be automatically closed as RESOLVED WORKSFORME.

For more information about our bug triaging procedures, please read https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging.

Thank you for helping us make KDE software even better for everyone!</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2357661</commentid>
    <comment_count>16</comment_count>
    <who name="Bug Janitor Service">bug-janitor</who>
    <bug_when>2024-09-20 12:36:56 +0000</bug_when>
    <thetext>A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4731</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2357673</commentid>
    <comment_count>17</comment_count>
    <who name="Fushan Wen">qydwhotmail</who>
    <bug_when>2024-09-20 13:01:41 +0000</bug_when>
    <thetext>Git commit 9bd2dcc8a785d977cdf67a7cbb467423803e3327 by Fushan Wen, on behalf of David Edmundson.
Committed on 20/09/2024 at 13:01.
Pushed by fusionfuture into branch &apos;master&apos;.

startkde: Disable session management in our session management

We have two types of session restore, ksmserver for ICE clients and a
small fallback app that runs after ksmserver for any stragglers.

This fallback app is a gui application, as such it will try and connect
to ksmserver. This isn&apos;t useful and can cause a block.

M  +1    -0    startkde/session-restore/restore.cpp
M  +1    -0    startkde/session-restore/save.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/9bd2dcc8a785d977cdf67a7cbb467423803e3327</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2357679</commentid>
    <comment_count>18</comment_count>
    <who name="Steve Evans">stevee</who>
    <bug_when>2024-09-20 13:26:17 +0000</bug_when>
    <thetext>I just tried https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4684 and it did /not/ work. I did this after building with the patch:

1. Create a new user so there is no old user cruft to confuse things.
2. Log on.
3. Log off. This worked
4. Logged on again.
5. Changed the Session Restore setting to When session was manually saved.
6. Added a konsole to the desktop.
7. Saved the session.
8. Log off. This hung. I waited 30 minutes, it still hadn&apos;t logged off so I killed ksmserver and the logoff then completed.

I will now try the new patch https://invent.kde.org/plasma/plasma-workspace/-/commit/9bd2dcc8a785d977cdf67a7cbb467423803e3327</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2357683</commentid>
    <comment_count>19</comment_count>
    <who name="Fushan Wen">qydwhotmail</who>
    <bug_when>2024-09-20 13:33:28 +0000</bug_when>
    <thetext>Git commit 792586f26e532dc049fc2f613d9a77db976f9054 by Fushan Wen.
Committed on 20/09/2024 at 13:02.
Pushed by fusionfuture into branch &apos;Plasma/6.2&apos;.

startkde: Disable session management in our session management

We have two types of session restore, ksmserver for ICE clients and a
small fallback app that runs after ksmserver for any stragglers.

This fallback app is a gui application, as such it will try and connect
to ksmserver. This isn&apos;t useful and can cause a block.


(cherry picked from commit 9bd2dcc8a785d977cdf67a7cbb467423803e3327)

Co-authored-by: David Edmundson &lt;kde@davidedmundson.co.uk&gt;

M  +1    -0    startkde/session-restore/restore.cpp
M  +1    -0    startkde/session-restore/save.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/792586f26e532dc049fc2f613d9a77db976f9054</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2357694</commentid>
    <comment_count>20</comment_count>
    <who name="Steve Evans">stevee</who>
    <bug_when>2024-09-20 14:13:44 +0000</bug_when>
    <thetext>The patch https://invent.kde.org/plasma/plasma-workspace/-/commit/9bd2dcc8a785d977cdf67a7cbb467423803e3327 worked for me. Thanks.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2357857</commentid>
    <comment_count>21</comment_count>
    <who name="Andreas Sturmlechner">asturm</who>
    <bug_when>2024-09-21 08:33:33 +0000</bug_when>
    <thetext>*** Bug 487616 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2362086</commentid>
    <comment_count>22</comment_count>
    <who name="Nate Graham">nate</who>
    <bug_when>2024-10-02 20:02:02 +0000</bug_when>
    <thetext>*** Bug 493952 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>