Bug 492793 - Ability to unmount a specific URL
Summary: Ability to unmount a specific URL
Status: REPORTED
Alias: None
Product: kiofuse
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: VLO wishlist
Target Milestone: ---
Assignee: a.saoutkin
URL: https://invent.kde.org/system/kio-fus...
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-08 10:33 UTC by Yevhen Popok
Modified: 2024-09-08 22:10 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Yevhen Popok 2024-09-08 10:33:47 UTC
SUMMARY
As mentioned in the KIO-fuse readme, it's possible to unmount kio-fuse mounts with the standard fusermount3 -u $dir command. The problem is that KIO-Fuse uses shared mount point (e.g., /run/user/1000/kio-fuse-AynHjG/) so I can't unmount some specific URL.

STEPS TO REPRODUCE
1. In Dolphin open several network URLs (e.g. sftp://user1@server1 and sftp://user2@server2)
2. That will create few directories in your local filesystem (e.g. "/run/user/1000/kio-fuse-AynHjG/sftp/user1@server1" and "/run/user/1000/kio-fuse-AynHjG/sftp/user1@server1")
3. Now you need to unmount sftp://user1@server1 only and keep sftp://user2@server2 opened

OBSERVED RESULT
User needs to close all relevant files/directories, unmount both URLs with fusermount -u  /run/user/1000/kio-fuse-AynHjG/, then mount again sftp://user2@server2

EXPECTED RESULT
User can unmount specifically sftp://user1@server1 while keeping files/directories on sftp://user2@server2 open.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma:  Fedora 40
KDE Plasma Version:  6.1.4
KDE Frameworks Version: 6.5.0
Qt Version: 6.7.2
Comment 1 Fabian Vogt 2024-09-08 20:41:03 UTC
Why would you unmount a specific URL? KIO itself does not have a concept of mounts, so it wouldn't do anything.
Comment 2 Yevhen Popok 2024-09-08 21:04:41 UTC
(In reply to Fabian Vogt from comment #1)
> Why would you unmount a specific URL? KIO itself does not have a concept of
> mounts, so it wouldn't do anything.

User may want to "disconnect" from remote for multiple reasons.
Some examples:
- security/foolproof considerations (make sure that nothing on remote will be added or deleted using connection from the particular machine)
- not to disturb remote users (e.g., during shutdown, GNOME reports when there are other logged in users)
Comment 3 Fabian Vogt 2024-09-08 22:10:16 UTC
(In reply to Yevhen Popok from comment #2)
> (In reply to Fabian Vogt from comment #1)
> > Why would you unmount a specific URL? KIO itself does not have a concept of
> > mounts, so it wouldn't do anything.
> 
> User may want to "disconnect" from remote for multiple reasons.
> Some examples:
> - security/foolproof considerations (make sure that nothing on remote will
> be added or deleted using connection from the particular machine)

I don't think security applies here, but "foolproof considerations" might, for the case that something important is mounted (e.g. remote home dir) that should not fall victim of a rm -rf /*. Arguably that's futile to mitigate though, it'll always deal maximum damage.

> - not to disturb remote users (e.g., during shutdown, GNOME reports when
> there are other logged in users)

There is no active connection open per mount, only for actions.