How to prevent KDE Dolphin from freezing when using rclone FUSE mounts (Google Drive, OneDrive, etc.)
Hi everyone,
If you are using KDE Plasma and mount your cloud storage (like Google Drive or OneDrive) using rclone mount, you have probably experienced annoying UI freezes in KDE's file manager, Dolphin.
When opening your mount point, Dolphin can completely freeze, turn gray, show "(Not Responding)", and even temporarily lock up parts of the Plasma desktop.
The good news: You don't have to compile any code or switch file managers. You can easily fix this entirely by understanding how rclone caches data, using the right mount options, and applying a quick Dolphin settings tweak. Here is a guide on why this happens and how to solve it.
Why does Dolphin freeze?
Dolphin's main GUI thread often treats FUSE mounts as fast, local filesystems. By default, Dolphin tries to recursively calculate the size of all folders and their subfolders.
When you open a FUSE mount, this triggers Dolphin to make massive metadata requests. If rclone doesn't have the directory structure cached, it has to fetch these details directly from the cloud APIs for every single directory click. The main GUI thread of Dolphin blocks synchronously on the FUSE mount waiting for cloud responses, causing the application to freeze.
Understanding Rclone's Two Caches
To fix this, we first need to understand that rclone uses two entirely different caches to speed up operations. Configuring them correctly is key:
| Feature | 1. Directory Cache (dir-cache) | 2. VFS File Cache (vfs-cache) |
|---|---|---|
| Purpose | Speeds up the listing of folder and file names. | Stores the actual contents of read/written files. |
| Data Stored | File/Folder structure, sizes, and metadata. | Actual binary file data (for playback, previews, etc.). |
| Storage Location | System Memory (RAM). | Local disk storage (e.g., SSD). |
| Volatility | Highly volatile (cleared on reboot/unmount). | Persistent (survives system reboots). |
| Key Flag | --dir-cache-time |
--vfs-cache-mode |
Step 1: Use Optimized Rclone Mount Options
To stop Dolphin from waiting on cloud APIs, we need to cache the directory structure in RAM for as long as possible, pre-load it, and cache file contents on our local disk.
Here is the optimal rclone mount command:
rclone mount gdrive: ~/GoogleDrive \
--vfs-cache-mode full \
--dir-cache-time 8760h \
--vfs-cache-max-age 24h \
--vfs-read-chunk-size 16M \
--vfs-read-chunk-size-limit 2G \
--async-read=true \
--buffer-size 32M \
--rc \
--daemon
Why these flags make a difference:
-
--vfs-cache-mode full: This handles the VFS File Cache. It ensures that any file Dolphin (or a preview generator) tries to read or write is cached on your fast local disk. Dolphin won't lock up trying to read file headers. -
--dir-cache-time 8760h: This handles the Directory Cache. Since Google Drive and OneDrive are polling remotes (they automatically notify rclone when files change in the cloud), we can safely cache the directory structure in RAM for a very long time (e.g., 1 year or 8760 hours). The cache will stay up-to-date and won't go stale. -
--rc: Enables the Remote Control link. This is required for our next step to instantly pre-load our folder structure. -
--daemon: Runs rclone in the background so you can safely close your terminal.
Step 2: Instantly Pre-Load Your Directory Cache
By default, the directory cache is built as you navigate. To get instant directory loading the moment you open Dolphin, you should trigger a cache pre-load right after mounting.
Since we enabled --rc in our mount command, we can run this command immediately after mounting (you can easily script this):
rclone rc vfs/refresh recursive=true
This command runs in the background, crawling your cloud drive and loading the entire directory structure straight into your fast system RAM. Once finished, navigating through folders in Dolphin becomes instantly responsive.
Hope this updated guide helps other Linux desktop users enjoy a smooth, freeze-free experience with rclone and Dolphin! Feel free to ask questions or share your own mount tweaks below.