https://bugs.kde.org/show_bug.cgi?id=423187

Frank Gehann <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #41 from Frank Gehann <[email protected]> ---
I investigated a mounted-CIFS variant of this issue and prepared KIO patch
proposals. My reproducer is Dolphin 26.08.1 with KIO 6.30.0 and Qt 6.11.2 on
Fedora 44, copying one approximately 100 MB local file to a mounted SMB3
share while navigating directories on the same mount.

There were two distinct sources of delay:

1. Dolphin's main thread performed synchronous filesystem probes. Captured
   callers included KFileItem permission checks used by Dolphin's action
updates,
   KFileItemListProperties parent-writability checks, directory
canonicalization,
   KDirWatch setup/metadata checks and .hidden processing. Some individual
calls
   took several seconds. Even a mount-ID statx with DONT_SYNC could still wait
   during remote path traversal, so changing statfs alone was insufficient.

2. After removing those UI-thread stalls, navigation responded but directory
   contents still remained loading until copying finished. Independent
directory
   reads outside Dolphin also stalled while the buffered upload was queued.
   Thus making the UI asynchronous alone did not resolve this second symptom.

The proposed general KIO changes classify Linux mounted paths from mountinfo
without traversing the remote path, use listing metadata for advisory
permission
checks on known slow mounts, resolve canonical paths and initialize watches off
the lister thread, and delegate .hidden processing to the file worker with an
acknowledgement/compatibility fallback. Actual operations still enforce
permissions.

A separate experimental Linux CIFS patch, disabled by default, enables at most
two outstanding 1 MiB direct writes with KIO_CIFS_COPY_DIRECT=1. This avoided
the
writeback queue delaying directory reads in my test and reports completed
writes.
The earlier periodic-fdatasync experiment was slower and was discarded.

I personally tested the final 6.30 implementation in Dolphin and confirmed
responsive navigation, directory contents loading during copying, and working
progress. For a 111,403,369-byte file, an instrumented CopyJob finished in
22.055 s versus
21.730 s for an unpaced reference; a concurrent listing completed in 0.904 s.
Progress normally updated around every 200 ms. A watched-directory navigation
run loaded the requested directory 2.508 s after navigation started, while the
copy continued until 22.550 s. Checksums matched. These are individual network
measurements, not a general performance guarantee.

Two draft merge requests are now available for upstream review:

- UI fixes: https://invent.kde.org/frameworks/kio/-/merge_requests/2469
- Experimental CIFS copying and manual diagnostics:
  https://invent.kde.org/frameworks/kio/-/merge_requests/2470

The second MR builds on the first. Both target KIO master. The master port
preserves the existing upstream mount-ID classification and reworked CopyJob
progress; the additional 6.30 progress correction is only in the tested stable
implementation. Seven navigation/filter/watch cases and the checksum, EINTR,
short-write, disk-full, cancellation and local-copy checks passed on 6.30.

The master port passed syntax checks for its six changed source files, but
still needs a full build/runtime test with Frameworks 6.31 development files;
this machine only has 6.30. The CIFS transfer option also needs broader review
and filesystem validation. I have not verified offline mounts, rclone/FUSE,
NFS or sleeping disks, so I am not proposing that this broad ticket be closed.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to