Skip to content

[BUG] Severe typing lag with Notes on a network share (SMB over VPN) since 26.x #3587

Closed

Description

@Mr-Rayman

Expected behaviour

Typing in the note editor should remain responsive, even when the note folder is on a network share, even over a higher-latency link such as a VPN.

Actual behaviour

On QOwnNotes 26.x, typing in the editor freezes for several seconds after every 3–4 words when the note folder lives on an SMB share accessed through a VPN tunnel. The UI becomes unusable for remote editing.
A Process Monitor (Sysinternals) trace shows that a single keystroke produces ~60 file-system calls from QOwnNotes.exe, roughly two-thirds of them CreateFile / QueryOpen / ReadFile / LockFile / QueryStandardInformationFile against .md files in the note folder other than the currently edited note. On a local LAN connection these calls are imperceptible; over a VPN with ~30 ms RTT each call becomes a network round-trip, and they accumulate into multi-second freezes. The QOwnNotes log panel (debug level) is silent during the freezes — i.e. nothing in the app's own event flow is logged while the file-system traffic happens.

Steps to reproduce

Place the note folder on an SMB share reachable over a VPN tunnel.
Open a note containing some Markdown links / image links to other notes/media.
Type continuously.
Observe multi-second editor freezes recurring every few words.

Workaround / regression bisection

Downgrading to 25.12.1 fully resolves the issue over the same VPN/SMB connection — typing is fluid, autosave fires at the configured interval, no freezes.

This points to a regression introduced somewhere between 25.12.1 and current 26.x. Likely candidates from the changelog:

26.3.3 "small inline Markdown image previews … in the note text edit" (enabled by default) — would touch external files on every editor change.
26.2.10 "notes directory watcher now always schedules a deferred re-index" plus "note index rebuild also refreshes the note list when an existing note's content was updated on disk" — would explain enumeration of all .md files in the folder on save.

Environment

OS: Windows 11
QOwnNotes (broken): 26.x (latest)
QOwnNotes (working): 25.12.1
Note folder: SMB share on a Linux system, accessed via VPN
notes.sqlite: ~36 KB
Windows-side checks done and ruled out: Defender exclusions set, Offline Files / CSC service stopped, indexing on the share disabled, MTU verified, no other process touching the share during the freezes (Procmon-confirmed: only QOwnNotes.exe).

Additional notes

Given that the file-system calls during the freezes target .md files other than the note being edited, the regression appears to involve either the directory watcher's re-index path or a feature that scans linked/related notes on each editor event. The Procmon trace and the clean 25.12.1 vs broken 26.x bisection should make this reproducible without VPN if a similar high-latency filesystem (e.g. a slow USB drive, a throttled network mount, or a slowfs-style FUSE mount) is used to amplify the per-call cost.

Activity

  1. pbek commented on Apr 27, 2026

    @pbek
    Owner

    QOwnNotes was never intended to write on slow network shares over the internet. 🤔

    26.3.3 "small inline Markdown image previews … in the note text edit" (enabled by default) — would touch external files on every editor change.

    Have you tried turning that off?
    Can you turn off the preview altogether?

    Can you please post the output from the debug settings that you can copy when you get to the settings dialog in QOwnNotes and head over to the Debug section of it?
    Is there any useful log output if you enable the log panel (see Window / Panels)? Please make sure you also enable debug logging in the log panel (by right-clicking on the panel and selecting Debug in Options).

    Can you please try opening QOwnNotes in a new session, see CLI Parameters? Use a minimal one for testing.

  2. Mr-Rayman commented on Apr 28, 2026

    @Mr-Rayman
    Author

    QOwnNotes was never intended to write on slow network shares over the internet. 🤔

    I do understand that! Having the notes on a network share (using a VPN to my share) is a pretty simple and comfortable way of using my personal notes across different devices.

    Acutually the network connection is pretty fast and working with the connected network share is flawless otherwise. Also in QOwnNotes 25.1x.x it was working perfect.

    What kills QOwnNotes is the large amount of CreateFile / QueryOpen / ReadFile / LockFile / QueryStandardInformationFile on EVERY keystroke, that accumulate somehow on the network share and its file operations. This wasn't the case in 25.1x.x.

    26.3.3 "small inline Markdown image previews … in the note text edit" (enabled by default) — would touch external files on every editor change.
    Have you tried turning that off? Can you turn off the preview altogether?

    Yes, it is turned off and the problem remains.

    Can you please post the output from the debug settings

    See debug and protocol log attached.

    Can you please try opening QOwnNotes in a new session, see CLI Parameters? Use a minimal one for testing.

    It was okay in a completely new folder with only one file. Adding more files and typing into several different files accumulates the problem and QOwnNotes becomes unusable.

    QOwnNotes Debug Information.txt
    QOwnNotes Log.txt

  3. pbek commented on Apr 29, 2026

    @pbek
    Owner

    What kills QOwnNotes is the large amount of CreateFile / QueryOpen / ReadFile / LockFile / QueryStandardInformationFile on EVERY keystroke, that accumulate somehow on the network share and its file operations. This wasn't the case in 25.1x.x.

    It would really help if you would find the first release where you started to have the issues. Then I can take a closer look.

    [16:34:24] [status] 🔄 Notizverzeichnis wurde extern geändert

    It looks like something is constantly writing to your note folder externally.

  4. ipariparipa commented on May 26, 2026

    @ipariparipa

    maybe this is a different rootcause but it looks like the same symptome like my problem described in #3628 and #3617

  5. Mr-Rayman commented on May 27, 2026

    @Mr-Rayman
    Author

    It would really help if you would find the first release where you started to have the issues. Then I can take a closer look.

    I did a lot of testing and found the problematic release:

    The issue first occures in release 26.3.13 and stays in all releases up to current version.
    https://github.com/pbek/QOwnNotes/releases/tag/v26.3.13

    Release 26.3.12 and all below are fine. Everything works as expected there.

    This is what the AI says: Two candidate causes were introduced or activated in this release window:

    #3499 — the new Files tab and the changed visibility checks for the optional "Files" and "Backlinks" tabs in the Navigation panel. Backlink detection inherently requires reading other notes in the folder, which matches the observed access pattern.
    #3467 — the Markdown LSP integration (Marksman / Rumdl). LSP servers like Marksman index the entire note folder as their workspace, and prior to v26.4.25 the client sent the full note text on every keystroke.

    The series of per-keystroke performance fixes shipped after v26.3.13 — #3467 in v26.4.25 (LSP no longer does O(n) toPlainText() on every keystroke; "zero additional work on the text-change hot path when LSP is disabled"), #3617 in v26.5.13 (Botan encryption moved to a worker thread), and #3627 in v26.5.16 (no longer re-fetching the full decrypted note text from the in-memory database on every keystroke) — indicates that the editor's text-change hot path accumulated several expensive operations in this period. These are invisible on local SSD but catastrophic over a network share with non-trivial latency.

  6. pbek commented on May 28, 2026

    @pbek
    Owner

    I tested again on a cheap laptop. What is the hardware you are testing on?

    Note folder: SMB share on a Linux system, accessed via VPN

    Do you have the same issue writing on local disk? If your IO is very bad you will have issues.

    It looks like something is constantly writing to your note folder externally.

    And this certainly will cause issues, because your note folder will constantly reload.

  7. pbek commented on May 28, 2026

    @pbek
    Owner

    What happens when you turn off the navigation panel?

  8. Mr-Rayman commented on May 28, 2026

    @Mr-Rayman
    Author

    I do have a state-of-the art laptop (ThinkPad i5, 16 GB RAM, 512 GB SSD). There are no problems with reading/writing in local LAN and with SSD.

    It looks like something is constantly writing to your note folder externally.

    QOwnNotes is the only process that is accessing my note folder on a network drive.

    How is QOwnNotes watching the note folder for external changes? By timer every x milliseconds or after every keystroke? (I do have the settings enabled: 'ignore all external changes on note and folder').

    Turning off the navigation panel does not have any effect, off or on - the typing lag issue is the same.

  9. pbek commented on May 28, 2026

    @pbek
    Owner

    QOwnNotes has a watcher on the directory and on the note files directly to watch for external changes (e.g. by file sync software). If a file watcher hits, that file will be reloaded. But if another file gets updated that is not watched directly, the directory watcher gets an inotify event and it will reload the note folder. Your log file is littered with 🔄 Notizverzeichnis wurde extern geändert messages, which means exactly that happened.

  10. Mr-Rayman commented on May 29, 2026

    @Mr-Rayman
    Author

    Thanks for the explaination, I will research further in this direction.

    Why do the settings 'ignore all external changes on note and folder' don't have any effect on this? Should'nt this exactly be the option to (not) handle this?

  11. pbek commented on May 29, 2026

    @pbek
    Owner

    Do you mean Ignore all external note folder changes?

    That's how it's supposed to work: External note-folder and note-file changes are ignored by QOwnNotes’ reaction logic. It will not rebuild/reload the note index, reload externally changed notes, show the usual external modification status message, or run the deferred re-index logic from those watcher events.

    Is that not the case for you?

  12. pbek commented on May 29, 2026

    @pbek
    Owner

    Did you get the 🔄 Notizverzeichnis wurde extern geändert messages with ignoreAllExternalNoteFolderChanges on?

    Ok, the logs alone should be ok anyway... But no note folder reloading should get on. 🤔

  13. pbek commented on May 29, 2026

    @pbek
    Owner

    I'll try a blind fix...

  14. added a commit that references this issue on May 29, 2026
  15. pbek commented on May 29, 2026

    @pbek
    Owner

    26.5.17

    • Fixed the Ignore all external note folder changes setting still allowing
      note folder watcher paths and delayed external-change re-indexes to trigger
      repeated note folder reloads while notes were stored, especially on Windows
      network drives (for #3587)
  16. pbek commented on May 29, 2026

    @pbek
    Owner

    There now is a new release, could you please test it and report if it works for you?

  17. pbek commented on Jun 3, 2026

    @pbek
    Owner

    I will close this issue until there is more information.

  18. Mr-Rayman commented on Jun 4, 2026

    @Mr-Rayman
    Author

    There now is a new release, could you please test it and report if it works for you?

    I have tested release 26.6.3. There are less File Operations in the debug log, but the editor is not useable, after 4-5 typed characters it freezes and is extremly lagging. It seems there is something else going on in the background.

    [09:21:56] [debug] updatePanelMenu - 'updatePanelMenu'
    [09:22:15] [debug] storing note file: "ToDo.md"
    [09:22:16] [debug] stored note: Note: <id>4 <name>"ToDo" <fileName>"ToDo.md" <noteSubFolderId>1 <relativePath>"center" <hasDirtyData>false
    [09:22:16] [debug] storeUpdatedNotesToDisk - 'count': 1
    [09:22:16] [status] 💾 1 Notiz auf Festplatte gespeichert
    [09:22:27] [debug] storing note file: "ToDo.md"
    [09:22:28] [debug] stored note: Note: <id>4 <name>"ToDo" <fileName>"ToDo.md" <noteSubFolderId>1 <relativePath>"center" <hasDirtyData>false
    [09:22:28] [debug] storeUpdatedNotesToDisk - 'count': 1
    [09:22:28] [status] 💾 1 Notiz auf Festplatte gespeichert
    [09:22:43] [debug] focusInEvent - Registering as active editor: QOwnNotesMarkdownTextEdit(0x12c2812b620, name="noteTextEdit") "noteTextEdit"
    [09:22:43] [debug] registerAsActiveEditor - Registering editor: QOwnNotesMarkdownTextEdit(0x12c2812b620, name="noteTextEdit") "noteTextEdit"
    [09:23:02] [debug] storing note file: "ToDo.md"
    [09:23:03] [debug] stored note: Note: <id>4 <name>"ToDo" <fileName>"ToDo.md" <noteSubFolderId>1 <relativePath>"center" <hasDirtyData>false
    [09:23:03] [debug] storeUpdatedNotesToDisk - 'count': 1
    [09:23:03] [status] 💾 1 Notiz auf Festplatte gespeichert
    [09:23:18] [debug] storing note file: "ToDo.md"
    [09:23:19] [debug] stored note: Note: <id>4 <name>"ToDo" <fileName>"ToDo.md" <noteSubFolderId>1 <relativePath>"center" <hasDirtyData>false
    [09:23:19] [debug] storeUpdatedNotesToDisk - 'count': 1
    [09:23:19] [status] 💾 1 Notiz auf Festplatte gespeichert
    [09:23:23] [debug] focusInEvent - Registering as active editor: QOwnNotesMarkdownTextEdit(0x12c2812b620, name="noteTextEdit") "noteTextEdit"
    [09:23:23] [debug] registerAsActiveEditor - Registering editor: QOwnNotesMarkdownTextEdit(0x12c2812b620, name="noteTextEdit") "noteTextEdit"
    [09:23:55] [debug] storing note file: "ToDo.md"
    [09:23:56] [debug] stored note: Note: <id>4 <name>"ToDo" <fileName>"ToDo.md" <noteSubFolderId>1 <relativePath>"center" <hasDirtyData>false
    [09:23:56] [debug] storeUpdatedNotesToDisk - 'count': 1
    [09:23:56] [status] 💾 1 Notiz auf Festplatte gespeichert
    [09:24:17] [debug] storing note file: "ToDo.md"
    [09:24:18] [debug] stored note: Note: <id>4 <name>"ToDo" <fileName>"ToDo.md" <noteSubFolderId>1 <relativePath>"center" <hasDirtyData>false
    [09:24:18] [debug] storeUpdatedNotesToDisk - 'count': 1
    [09:24:18] [status] 💾 1 Notiz auf Festplatte gespeichert
    [09:24:27] [debug] storing note file: "ToDo.md"
    [09:24:28] [debug] stored note: Note: <id>4 <name>"ToDo" <fileName>"ToDo.md" <noteSubFolderId>1 <relativePath>"center" <hasDirtyData>false
    [09:24:28] [debug] storeUpdatedNotesToDisk - 'count': 1
    [09:24:28] [status] 💾 1 Notiz auf Festplatte gespeichert
    

    Going back to 26.3.12 and everything is perfect again.

  19. pbek commented on Jun 4, 2026

    @pbek
    Owner

    Another quick fix could be increasing your store interval if your IO is that slow...

    Image

    26.3.13 is the first bad release for you, right?

    I think the only relevant changes are:

    • Added a new "Files" tab to the Navigation panel that lists linked media files
      and attachments under separate root items, jumps to the selected link in the
      current note, and offers a context menu action to open the file externally
      (for #3499)
    • Changed the Navigation panel to only show the optional "Files" and
      "Backlinks" tabs when the current note actually has file links or backlinks
      to display (for #3499)
    • Changed Navigation panel tab visibility checks for the optional "Files" and
      "Backlinks" tabs to run in the background so the UI stays responsive
      (for #3499)

    Do you get the same issue in an empty note folder (where there are no backlinks to check because there are no other notes)?

  20. pbek commented on Jun 5, 2026

    @pbek
    Owner

    I tried to reproduce this with a mounted WebDAV share on the internet (DSL) and didn't have any sever problems...

  21. added a commit that references this issue on Jun 5, 2026
  22. pbek commented on Jun 5, 2026

    @pbek
    Owner

    I tried a blind fix:

    26.6.4

    • Try to fix typing lag with Notes on a network share by avoiding repeated backlink
      scans while typing when the backlink inputs did not change, and by computing
      backlink-relative note paths without touching every note file on disk
      (for #3587)
  23. pbek commented on Jun 5, 2026

    @pbek
    Owner

    There now is a new release, could you please test it and report if it works for you?

  24. Mr-Rayman commented on Jun 10, 2026

    @Mr-Rayman
    Author

    I've tested Version 26.6.5 and the typing lag is gone. Everything works okay now!
    Thank you very much for your efforts!

  25. pbek commented on Jun 10, 2026

    @pbek
    Owner

    Awesome, thank you for testing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions