Bug 428962 - Fail to mount the same iso file twice
Summary: Fail to mount the same iso file twice
Status: RESOLVED FIXED
Alias: None
Product: dolphin
Classification: Applications
Component: plugins: ISO mounting (show other bugs)
Version: 20.04.1
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Kwon-Young Choi
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-11-11 11:24 UTC by Kwon-Young Choi
Modified: 2020-11-12 00:35 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kwon-Young Choi 2020-11-11 11:24:48 UTC
SUMMARY
The MountIso plugin fails to mount the same iso file a second time after mounting and unmounting it. 
This leads to an unresponsive dolphin for 10 seconds.

STEPS TO REPRODUCE
1. mount an iso
2. unmount an iso
3. mount an iso

OBSERVED RESULT

Dolphin freeze during 10 seconds.
The iso file is not mounted.

EXPECTED RESULT

The iso file mounts immediately.

SOFTWARE/OS VERSIONS
Operating System: Manjaro Linux
KDE Plasma Version: 5.20.2
KDE Frameworks Version: 5.75.0
Qt Version: 5.15.1
Kernel Version: 5.9.3-1-MANJARO
OS Type: 64-bit
Processors: 8 × Intel® Core™ i7-7820HQ CPU @ 2.90GHz
Memory: 15.2 GiB of RAM
Graphics Processor: Mesa Intel® HD Graphics 630

ADDITIONAL INFORMATION

Both the latest dolphin on manjaro and dolphin built from sources exhibit this behavior.

Interestingly, udisksctl does not have this problem.
So, I compared the dbus calls from mountiso and udisksctl and found that udisksctl does not set the read-only option on the loop-setup call: http://storaged.org/doc/udisks2-api/2.8.4/gdbus-org.freedesktop.UDisks2.Manager.html#gdbus-method-org-freedesktop-UDisks2-Manager.LoopSetup

After removing the read-only option in the mountiso plugin, the mount works as expected.
I'll make a merge-request to fix this immediately.
Comment 1 Bug Janitor Service 2020-11-11 12:43:22 UTC
A possibly relevant merge request was started @ https://invent.kde.org/sdk/dolphin-plugins/-/merge_requests/20
Comment 2 Elvis Angelaccio 2020-11-11 22:50:31 UTC
Git commit 84e48b9ca9f9ecff8da3392e8112cfc2b5065e8b by Elvis Angelaccio, on behalf of Kwon-Young Choi.
Committed on 11/11/2020 at 22:50.
Pushed by elvisangelaccio into branch 'release/20.12'.

Do not use read-only option as udisksctl does

M  +0    -1    mountiso/mountisoaction.cpp

https://invent.kde.org/sdk/dolphin-plugins/commit/84e48b9ca9f9ecff8da3392e8112cfc2b5065e8b