Web lists-archives.com

Re: Plasma5 user sessions




Hi Max,

if you're using Plasma 5.11, then you don't need to look into the "plasma-workspace/startkde/waitforname" folder, because 5.11 has it. So the notifications should be delayed on your system already. But of course you can still take a look and check the patch out, which added it [1], because maybe you find a clue why it doesn't work in your setup.

There is also the folder "$HOME/.config/plasma-workspace/env", whose scripts gets executed as well on session start, but late in the process to my knowledge. So it might be an idea to put your notification script there.

Regarding the logout/shutdown: we are talking about a single desktop PC with multiple users being logged in at the same time and one of them in his currenctly active session requests a shutdown, right? The user also has the right to shutdown while other users are logged in, right? First you didn't specify where you hook into at the moment to execute your logout tasks. logind provides the D-Bus signal PrepareForShutdown, so maybe try to hook into this if you don't do it already. Also two years ago there was a change to systemd's behavior in killing processes directly [2], so maybe try to reverse this behavior with the respective flag. I assume a properly configured system should have no problem with this though.

Also consider using systemd user services instead of putting scripts in "/etc/X11/Xsession.d" [3].

Cheers
Roman

[1] https://phabricator.kde.org/D5012
[2] https://www.golem.de/news/aufraeumen-von-prozessen-beim-logout-systemd-neuerung-sorgt-fuer-nutzerkontroversen-1605-121176.html
[3] https://superuser.com/questions/1037466/how-to-start-a-systemd-service-after-user-login-and-stop-it-before-user-logout

On Mon, Jan 15, 2018 at 5:58 PM, Max Harmathy <max.harmathy@xxxxxxxxxxx> wrote:
Am 15.01.2018 15:29, schrieb David Edmundson:

    org.freedesktop.Notifications. However on our development release those
    messages get displayed as windows instead of the usual bubbles. It seems
    that the notification handling is not ready when the autostarts are running.

There is a fix for this in Plasma 5.10 onwards.
Or you can backport the "plasma-workspace/startkde/waitforname"  folder

Make sure any Dbus calls are sent asyncronously, otherwise you'll block your startup.



Thank you David for your quick reply!

We are currently using plasma 5.11 from bionic (Ubuntu 18.04).
I will have a look into "plasma-workspace/startkde/waitforname".


As for the logind problem: I can reproduce this with a current kde-neon:
* log in with two local users
* one user logs out by selecting "Reboot"
* both sessions get killed instantly


--
Max Harmathy
IT@M - Dienstleister für Informations- und Telekommunikationstechnik
der Landeshauptstadt München

Geschäftsbereich Werkzeuge und Infrastruktur
Servicebereich Städtische Arbeitsplätze
Serviceteam LiMux-Arbeitsplatz I23

Agnes-Pockels-Bogen 21, 80992 München

Tel.: +49 89 233-782223
E-Mail: max.harmathy@xxxxxxxxxxx

********************************************************************************
Diese E-Mail wurde von einem LiMux-Arbeitsplatz aus versandt.
********************************************************************************
Elektronische Kommunikation mit der Landeshauptstadt München siehe: http://www.muenchen.de/ekomm

Bitte denken Sie an die Umwelt, bevor Sie diese E-Mail ausdrucken. Pro Blatt sparen Sie durchschnittlich 15g Holz, 260ml Wasser, 0,05kWh Strom und 5g CO2.