SUMMARY *** NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols. See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports *** STEPS TO REPRODUCE 1. Mount a USB drive with the GUI widget 2. Shut down plasmashell and relaunch from a command line with a working directory at or below the mount point of the USB drive 3. Attempt to safely remove the USB drive with the GUI widget OBSERVED RESULT The USB drive fails to unmount via the GUI widget, or indeed via umount, until the plasmashell is closed and relaunched from a different working directory. No diagnostic is given. EXPECTED RESULT plasmashell should be able to unmount this drive, (by, for instance, changing its current working directory). SOFTWARE/OS VERSIONS Linux/KDE Plasma: NixOS 23.05 (available in About System) KDE Plasma Version: 5.27.7 KDE Frameworks Version: 5.106.0 Qt Version: 5.15.9 ADDITIONAL INFORMATION Encountered this issue after a plasmashell crash and I relaunched the plasmashell from the nearest command line handy, which happened to be in a subdirectory of the mounted drive, because I was using it to transfer files. Because this process was quite time consuming, it wasn't until the next day that I attempted to remove the drive, and I spent a few mystified minutes trying to figure out what was holding the drive open. I don't think this would be a commonly encountered issue, but it's also one that seems to be easy to fix by changing the current working directory on launch, as plasmashell doesn't seem to be sensitive to this value at all.
How exactly did you quit and relaunch plasma? What command did you use?
(In reply to Nate Graham from comment #1) > How exactly did you quit and relaunch plasma? What command did you use? Sorry about the long delay in response, I seem to have not received a notification. You can reproduce this behavior by doing $ cd /mount/point $ kquitapp5 plasmashell && kstart5 plasmashell $ cd / to launch the plasmashell from below the mount point, launch plasmashell within the pwd of the mounted drive, then exit the mounted drive (so the shell itself isn't holding the mount point open).
Thanks. Does the problem happen if you restart plasmashell using `systemctl restart --user plasma-plasmashell.service` instead?
(In reply to Nate Graham from comment #3) > Thanks. Does the problem happen if you restart plasmashell using `systemctl > restart --user plasma-plasmashell.service` instead? The problem does not happen when I use systemctl to restart the service.
Awesome. That's the supported way to restart plasma, so I'd recommend doing that instead of what you were doing before.
(In reply to Nate Graham from comment #5) > Awesome. That's the supported way to restart plasma, so I'd recommend doing > that instead of what you were doing before. Practically speaking, using `kstart5 plasmashell` is by far and away the most commonly documented process, from both seemingly official (https://userbase.kde.org/Plasma) and unofficial sources. Particularly the ones that show up when simply performing a web search across a variety of search engines for "kde restart plasma". In fact, this particular difference seems to have tripped even you up just last year. https://bugs.kde.org/show_bug.cgi?id=448475#c30 I don't mean to be difficult, as I have absolutely no illusions that this is an important bug that needs to be addressed; it's just a obscure, sharp edge that I happened to bump up against. It just seemed out of left field that a very established and documented pattern is not the supported method.
It has indeed tripped me up in the past. :) One thing I could see us doing is making `plasmashell --replace` run the systemctl command if you're using the systemd boot process. Let's track that at Bug 474995.