Open dafanasiev opened 3 years ago
It's systemd/logind job to clean up not cinnamon-session.
Maybe this Pr would help. https://github.com/linuxmint/cinnamon-session/pull/141
@leigh123linux hmm..
I try to recompile cinnamon-session from master
branch with apply patch from #141 (in docker container):
git clone https://github.com/linuxmint/cinnamon-session.git
cd cinnamon-session
wget https://github.com/linuxmint/cinnamon-session/pull/141.patch -O /tmp/141.patch
git am /tmp/141.patch
docker run -it --rm -v $PWD:/app -w /app linuxmintd/mint20.1-amd64 /bin/bash
#inside docker
$> apt update && apt upgrade && mint-build && exit
#in host:
sudo mv /usr/bin/cinnamon-session /usr/bin/cinnamon-session.bak
sudo cp ./debian/cinnamon-session/usr/bin/cinnamon-session /usr/bin/cinnamon-session
reboot
## do logout(user1)-login(user2) steps
But I see the same picture in processes.
Do you have any other ideas other than "apt remove gnome-calendar geoclue-2.0" ?
Try editing /etc/systemd/logind.conf and uncomment / change
#KillUserProcesses=no
to
KillUserProcesses=yes
https://www.freedesktop.org/software/systemd/man/logind.conf.d.html
I found this https://bugs.launchpad.net/ubuntu/+source/geoclue-2.0/+bug/1871728
You could edit /etc/xdg/autostart/geoclue-demo-agent.desktop
NotShowIn=GNOME;
And add X-Cinnamon
NotShowIn=GNOME;X-Cinnamon;
@leigh123linux ok, I think that KillUserProcesses=yes
will work, but this is bad option.
About editing /etc/xdg/autostart/geoclue-demo-agent.desktop
.
I install fresh (and clean) linux mint cinnamon edition 20.1 into VM and apply geoclue-demo-agent.desktop
"patch". Yes, now geclue-demo agent wont start. But there is the similar problem, now with "printer applet":
Steps
user2@user1-vm:~$ sudo loginctl list-sessions
SESSION UID USER SEAT TTY
c2 1000 user1 seat0
c4 1001 user2 seat0
2 sessions listed. user2@user1-vm:~$ sudo loginctl session-status c2 c2 - user1 (1000) Since: Sun 2021-04-11 09:22:10 MSK; 1min 33s ago Leader: 981 Seat: seat0; vc7 Display: :0 Service: lightdm; type x11; class user Desktop: cinnamon State: closing Unit: session-c2.scope └─1629 /usr/bin/python3 /usr/share/system-config-printer/applet.py
"applet.py(1629)" in processes without "parent":
```sh
user2@user1-vm:~$ sudo pstree -p -s user1
applet.py(1629)
systemd(995)─┬─(sd-pam)(996)
├─dbus-daemon(1013)
├─dconf-service(1256)─┬─{dconf-service}(1257)
│ └─{dconf-service}(1274)
├─evolution-addre(1498)─┬─{evolution-addre}(1504)
│ ├─{evolution-addre}(1506)
│ ├─{evolution-addre}(1512)
│ ├─{evolution-addre}(1513)
│ └─{evolution-addre}(1517)
├─evolution-calen(1489)─┬─{evolution-calen}(1490)
│ ├─{evolution-calen}(1491)
│ ├─{evolution-calen}(1492)
│ ├─{evolution-calen}(1493)
│ ├─{evolution-calen}(1496)
│ └─{evolution-calen}(1497)
├─evolution-sourc(1452)─┬─{evolution-sourc}(1462)
│ ├─{evolution-sourc}(1467)
│ └─{evolution-sourc}(1472)
├─goa-daemon(1333)─┬─{goa-daemon}(1338)
│ ├─{goa-daemon}(1340)
│ └─{goa-daemon}(1343)
├─goa-identity-se(1346)─┬─{goa-identity-se}(1347)
│ └─{goa-identity-se}(1349)
├─gvfs-afc-volume(1310)─┬─{gvfs-afc-volume}(1321)
│ ├─{gvfs-afc-volume}(1322)
│ └─{gvfs-afc-volume}(1324)
├─gvfs-goa-volume(1329)─┬─{gvfs-goa-volume}(1330)
│ └─{gvfs-goa-volume}(1331)
├─gvfs-gphoto2-vo(1325)─┬─{gvfs-gphoto2-vo}(1326)
│ └─{gvfs-gphoto2-vo}(1328)
├─gvfs-mtp-volume(1297)─┬─{gvfs-mtp-volume}(1303)
│ └─{gvfs-mtp-volume}(1306)
├─gvfs-udisks2-vo(1269)─┬─{gvfs-udisks2-vo}(1282)
│ ├─{gvfs-udisks2-vo}(1285)
│ └─{gvfs-udisks2-vo}(1294)
├─gvfsd(1021)─┬─gvfsd-trash(1522)─┬─{gvfsd-trash}(1523)
│ │ └─{gvfsd-trash}(1524)
│ ├─{gvfsd}(1023)
│ └─{gvfsd}(1024)
├─gvfsd-fuse(1027)─┬─{gvfsd-fuse}(1031)
│ ├─{gvfsd-fuse}(1032)
│ ├─{gvfsd-fuse}(1033)
│ ├─{gvfsd-fuse}(1034)
│ └─{gvfsd-fuse}(1041)
├─gvfsd-metadata(1530)─┬─{gvfsd-metadata}(1531)
│ └─{gvfsd-metadata}(1532)
└─obexd(1485)
After kill "printer applet":
user2@user1-vm:~$ sudo kill -9 1629
user2@user1-vm:~$ sudo loginctl list-sessions
SESSION UID USER SEAT TTY
c4 1001 user2 seat0
1 sessions listed.
UPD: as I see this applet starts by cinnamon-session
.
@leigh123linux ok, I think that
KillUserProcesses=yes
will work, but this is bad option.
Why do you consider it bad to ensure logind cleans up it own mess? TBH the guy from the bug report I linked who claims it to be the nuclear option is totally clueless and doesn't understand logind role.
@leigh123linux yes, KillUserProcesses=yes
works as expected.
Steps to reproduce My PC used by two users. After user1 logout and user2 login I can see some processes from user1.
I see process 1185 /usr/libexec/geoclue-2.0/demos/agent:
but cant see it in tree:
ok, I try to find parent:
But I cant understood why systemd run this process (can anyone help?).
After I kill process 1185 (
kill -9 1185
) session for user1 and all other user1 processes (that listed above) gone away.I not sure that this is bug in cinnamon-session.
Expected behaviour
Session for user must be closed when user logout.
Additinal info
gdb 1185