Bug 507768 - If Device Auto-Mount KCM is set to mount all known devices on attach, SD card is immediately re-mounted after being safely removed
Summary: If Device Auto-Mount KCM is set to mount all known devices on attach, SD card...
Status: RESOLVED DUPLICATE of bug 467751
Alias: None
Product: neon
Classification: KDE Neon
Component: Packages Unstable Edition (other bugs)
Version First Reported In: unspecified
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Neon Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-08-02 04:23 UTC by Patrick Silva
Modified: 2025-12-26 17:35 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
screen recording (3.04 MB, video/webm)
2025-08-02 04:23 UTC, Patrick Silva
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Silva 2025-08-02 04:23:23 UTC
Created attachment 183724 [details]
screen recording

STEPS TO REPRODUCE
1. insert a SD card and mount it
2. open Device Auto-Mount KCM
3. check the checkbox to mount "All known devices" on attach and apply the change
4. try to unmount the sd card using the "Safely remove" option from Disks & Devices aaplet or from context menu of the Places panel of Dolphin

OBSERVED RESULT
the system does not unmount the SD card as expected; the device is immediately re-mounted after being "safely removed" instead. The "Safely remove" option works as expected if the checkbox to mount "All known devices" on attach is unchecked in the KCM. Please watch the attached screen recording.

EXPECTED RESULT
the SD card should remain unmounted after the provided steps

SOFTWARE/OS VERSIONS
Operating System: KDE neon Unstable Edition
KDE Plasma Version: 6.4.80
KDE Frameworks Version: 6.17.0
Qt Version: 6.9.1
Graphics Platform: Wayland
Comment 1 TraceyC 2025-08-06 00:14:47 UTC
Thanks for the bug report. I'm not able to reproduce this on Plasma 6.4.3 or git-master. 
Can you get system logs for around the time you try to unmount the SD Card?
Comment 2 Patrick Silva 2025-08-06 11:26:08 UTC
The journal log prints these messages immediately after click on "Safely remove" button

ago 06 08:23:26 neon-laptop2 systemd[1]: media-stalker-SANDISK.mount: Deactivated successfully.
ago 06 08:23:26 neon-laptop2 udisksd[941]: Cleaning up mount point /media/stalker/SANDISK (device 179:1 is not mounted)
ago 06 08:23:26 neon-laptop2 udisksd[941]: Unmounted /dev/mmcblk0p1 on behalf of uid 1000
ago 06 08:23:26 neon-laptop2 kernel:  mmcblk0: p1
ago 06 08:23:26 neon-laptop2 (udev-worker)[7260]: mmcblk0p1: Process '/usr/bin/unshare -m /usr/bin/snap auto-import --mount=/dev/mmcblk0p1' failed with exit code 1.
ago 06 08:23:26 neon-laptop2 vivaldi-stable[4158]: [4154:4182:0806/082326.920751:ERROR:chromium/google_apis/gcm/engine/registration_request.cc:291] Registration response error message: DEPRECATED_ENDPOINT
ago 06 08:23:26 neon-laptop2 udisksd[941]: Mounted /dev/mmcblk0p1 at /media/stalker/SANDISK on behalf of uid 1000
Comment 3 TraceyC 2025-08-06 16:57:45 UTC
Thanks for the logs. It looks like the potential culprit is this:

ago 06 08:23:26 neon-laptop2 (udev-worker)[7260]: mmcblk0p1: Process '/usr/bin/unshare -m /usr/bin/snap auto-import --mount=/dev/mmcblk0p1' failed with exit code 1.

If you run this in your terminal, while that SD card is mounted, does it produce any output that's helpful?

/usr/bin/unshare -m /usr/bin/snap auto-import --mount=/dev/mmcblk0p1
Comment 4 Patrick Silva 2025-08-06 18:16:51 UTC
$ /usr/bin/unshare -m /usr/bin/snap auto-import --mount=/dev/mmcblk0p1
unshare: unshare failed: Operation not permitted

$ sudo /usr/bin/unshare -m /usr/bin/snap auto-import --mount=/dev/mmcblk0p1
[sudo] password for myuser: 
auto-import is disabled on classic
Comment 5 TraceyC 2025-08-07 16:22:41 UTC
It looks like the UI is simply showing the sequence of events from the system.
This may be a configuration problem in Neon, I'll send it to them to check into it.


Something that might be more generally actionable would be to surface errors like this from the system if a mount/unmount command results in a system error.
Comment 6 Patrick Silva 2025-09-15 13:22:30 UTC
This bug only occurs when I use the built-in card reader of my laptop. Cannot reproduce using an external usb card reader.
Comment 7 Patrick Silva 2025-12-26 17:35:27 UTC

*** This bug has been marked as a duplicate of bug 467751 ***