When I open Konsole through the Application Launcher, "toolbox enter" works fine. However, I have a keyboard shortcut for Konsole to open a new window with "Meta+Return", and if I try to run "toolbox enter" in that window then the process freezes for several minutes until timing out.
I was able to reproduce this with a brand new user: 1. Log in with new user. 2. Create a new shortcut for Konsole for "Open a new window" (Shortcuts->Add Application...->Konsole->Open a New Window). 3. Press the shortcut keys to open a new Konsole window (in my case Meta+Return). 4. Run "toolbox create". 5. Run "toolbox enter". it will now sit there for several minutes before silently ending. 6. Close Konsole window. Go to Application Launcher and open Konsole through the menu. 7. Run "toolbox enter". It should immediately enter the container.
I can not reproduce that. Do you have custom profiles? or toolbox containers?
Metadata Update from @siosm: - Issue tagged with: needinfo
No, I don't believe I do. This is a relatively-new Kinoite install and I haven't done much configuration. I did make sure to run podman system reset before trying it on my main profile.
Some additional findings: - Running toolbox enter in the "shortcut" window leaves behind a conmon process that doesn't go away when it times out. Trying multiple times creates an additional conmon process each time. - While these stuck processes are running, I can't use toolbox enter in the "normal" Konsole window. I have to kill -9 the stuck conmon processes, at which point toolbox immediately starts working in the normal Konsole window. - I checked pstree and it looks a bit weird. For the normal Konsole windows, conmon comes up under a nested systemd (so pstree shows systemd->systemd->conmon), while the shortcut Konsole windows have conmon come up under the root systemd (so it shows systemd->conmon).
Let me know if there's any further info I can provide, I know that's probably not a lot to go on.
This could have to do with the cgroups integration that does (or doesn't) happen when launching the app.
Could you show the cgroup Konsole is in for both cases?
I'm not entirely sure if I'm doing this right, but here's what I'm seeing when I run "cat /proc/self/cgroup".
"Normal" Konsole:
$ cat /proc/self/cgroup 0::/user.slice/user-1000.slice/user@1000.service/app.slice/app-org.kde.konsole-ce8c71cdd0024998bc8d50c1b286502c.scope
"Shortcut" Konsole:
/proc/self/cgroup 0::/user.slice/user-1000.slice/session-1.scope
I also checked "systemctl status" and got the relevant lines. The working "toolbox enter" is under app.slice and the stalled "toolbox enter" is under user.slice.
│ │ ├─user.slice │ │ │ ├─libpod-conmon-b878d32cdd54db85fff5ba2e5f3478a50b83e63b27ba75b0aa2bb799a14bc923.scope │ │ │ │ └─3774 /usr/bin/conmon --api-version 1 -c b878d32cdd54db85fff5ba2e5f3478a50b83e63b27ba75b0aa2bb799a14bc923 -u 70527640e23152a361400f118de7535c991d56ffa83c621b8b3a272b131dca89 -r /usr/bin/crun -b /var/home/ctristan/> │ │ │ ├─libpod-b878d32cdd54db85fff5ba2e5f3478a50b83e63b27ba75b0aa2bb799a14bc923.scope │ │ │ │ └─container │ │ │ │ ├─3282 toolbox --log-level debug init-container --gid 1000 --home /var/home/ctristan --shell /bin/bash --uid 1000 --user ctristan --monitor-host --home-link --media-link --mnt-link │ │ │ │ ├─3396 /bin/bash -l │ │ │ │ └─3778 /bin/bash -l │ │ │ ├─podman-3731.scope │ │ │ │ └─3731 podman --log-level error exec --detach-keys --interactive --tty --user ctristan --workdir /var/home/ctristan --env=COLORTERM=truecolor --env=DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus --env=DESKT> │ │ │ └─podman-pause-8586834681177583875.scope │ │ │ └─3107 podman │ │ ├─app.slice │ │ │ └─app-org.kde.konsole-ce8c71cdd0024998bc8d50c1b286502c.scope │ │ │ ├─1993 /usr/bin/konsole │ │ │ ├─2010 /bin/bash │ │ │ ├─3056 toolbox enter │ │ │ ├─3279 /usr/bin/conmon --api-version 1 -c b878d32cdd54db85fff5ba2e5f3478a50b83e63b27ba75b0aa2bb799a14bc923 -u b878d32cdd54db85fff5ba2e5f3478a50b83e63b27ba75b0aa2bb799a14bc923 -r /usr/bin/crun -b /var/home/ctristan/> │ │ │ ├─3349 podman --log-level error exec --detach-keys --interactive --tty --user ctristan --workdir /var/home/ctristan --env=COLORTERM=truecolor --env=DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus --env=DESKT> │ │ │ └─3392 /usr/bin/conmon --api-version 1 -c b878d32cdd54db85fff5ba2e5f3478a50b83e63b27ba75b0aa2bb799a14bc923 -u acd6f343aa796d091dca3238d54d744f73ba5acc93b678490d65eb9791c1eaea -r /usr/bin/crun -b /var/home/ctristan/>
That's exactly what I suspected. When launching "normally" via the app launcher Konsole gets spawned into its own scope, which is what is expected.
When launching via shortcut that doesn't happen. It's basically the same as running "konsole" directly from a terminal, skipping all the cgroups integration. I thought that was already fixed in the shortcuts framework, but I need to double check.
That said I have no idea why the cgroup difference would cause the behavior you are describing
See https://bugs.kde.org/show_bug.cgi?id=433362 and https://invent.kde.org/frameworks/kglobalaccel/commit/061c45df933f6a346c85c34fe10df6f1bd857908
Things work fine for me. What version of frameworks/kglobalaccel do you have installed?
If I'm looking at the correct spot, I have frameworks 5.89, which should include the fix mentioned for 5.86, although I'm not sure where to check for kglobalaccel specifically.
I'd love to get this resolved, but at this point it sounds like it's entirely a localized issue and not project-specific. I'll go ahead and close this since it's not-reproducible outside of my install. If you're still willing to help then that would be great, otherwise if I can get it reproducible from a completely fresh install then I'll re-visit.
Thank you very much for your time!
Metadata Update from @ctristan: - Issue close_status updated to: Invalid - Issue status updated to: Closed (was: Open)