Bug 402034

Summary: Provide an easy way to restart KWin and Plasma shell to the user (from virtual console)
Product: [Plasma] kde-cli-tools Reporter: leftcrane <leftcrane>
Component: generalAssignee: Aleix Pol <aleixpol>
Status: RESOLVED NOT A BUG    
Severity: major CC: kde
Priority: NOR Flags: leftcrane: Usability-
Version: 5.14.4   
Target Milestone: ---   
Platform: Kubuntu   
OS: Linux   
Latest Commit: Version Fixed In:

Description leftcrane 2018-12-12 01:49:09 UTC
there are several different solutions being suggested online and I haven't found a single one that allows me to restart both precesses successfully (compositing gets disabled, complains about no display not being found, plasma gets terminated but wont restart, or plasma gets terminated but the applets start to work in really weird ways)

I find myself frequently needing to use this feature due to desktop freezing, either because of third-party software, ram consumption or KDE bugs (hard to figure out). I don't want to log out or reboot cause then I lose all my work.

Due to it's single-threaded design, Gnome (on X) has a one liner:

--replace

KDE needs some kind of script but I can't figure out what that script should be. I suspect many users are in the same position (as evidenced by the popularity of this question and the variety of answers). It is also unclear whether the solution for X and Wayland would be different.

People need a simple, reliable way too unbork the shell and WM in case of emergency. It's a wishlist, but I'd like it have a high priority.
Comment 2 Kai Uwe Broulik 2018-12-12 08:53:57 UTC
You shouldn't find yourself in the situation where you would need to do this. File bug reports for the individual issues but just restarting everything all the time is not a solution and not something we encourage.

There's ways to do this: kwin_x11 --replace for KWin and plasmashell --replace for plasmashell.