You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Filesystem watching (kqueue) is enabled … with a lot of files #9183
bugA problem with current functionality, as opposed to missing functionality (enhancement)frozen-due-to-ageIssues closed and untouched for a long time, together with being locked for discussion
I see the "usual" warning, but on folders with very little files:
2023-10-25 09:23:57: Filesystem watching (kqueue) is enabled on "Default Folder" (default) with a lot of files/directories, and that requires a lot of resources and might slow down your system significantly
2023-10-25 09:23:57: Filesystem watching (kqueue) is enabled on "Documenti privati" (lapo-documenti) with a lot of files/directories, and that requires a lot of resources and might slow down your system significantly
If you're running with -verbose you should get an occasional line with Summary for folder ... (at least, when something has changed in the folder and you have the GUI up). That line contains the numbers that are the basis for triggering the warning in question, so would be interesting to see.
l.Warnf("Filesystem watching (kqueue) is enabled on %v with a lot of files/directories, and that requires a lot of resources and might slow down your system significantly", f.Description())
}
The values are in your log lines; it's nowhere near
Interesting. I tried to reproduce it, successfully. Here it seems to be caused by the un-watched folder's periodic scan handling a change (a folder with >10k files). As soon as that happens, a summary containing >10k local files is tossed and the óther folder (only a handful files, with the watcher enabled) triggers the error.
Seems like we don't verify if the summary actually belongs to the folder we watch it for and/or that the folder it's about actually has the watcher enabled?
bugA problem with current functionality, as opposed to missing functionality (enhancement)frozen-due-to-ageIssues closed and untouched for a long time, together with being locked for discussion
Activity
calmh commentedon Oct 25, 2023
If you're running with
-verboseyou should get an occasional line withSummary for folder ...(at least, when something has changed in the folder and you have the GUI up). That line contains the numbers that are the basis for triggering the warning in question, so would be interesting to see.lapo-luchini commentedon Dec 12, 2023
Those two shares gave the following summary:
calmh commentedon Dec 12, 2023
Fascinating. I have no idea how that could trigger the warning. I mean, the code is here:
syncthing/lib/model/folder.go
Lines 1068 to 1073 in 935a28c
The values are in your log lines; it's nowhere near
syncthing/lib/model/folder.go
Lines 36 to 37 in 935a28c
lapo-luchini commentedon Dec 12, 2023
Thanks for the pointer… I know no Go myself, but I should be able to add some "more verbose" debug to it.
lapo-luchini commentedon Dec 12, 2023
gives this:
… so I guess that's a global total, not a folder-specific total.
(yes, I have some 10k files, in other folders with kqueue already disabled)
er-pa commentedon Dec 12, 2023
Interesting. I tried to reproduce it, successfully. Here it seems to be caused by the un-watched folder's periodic scan handling a change (a folder with >10k files). As soon as that happens, a summary containing >10k local files is tossed and the óther folder (only a handful files, with the watcher enabled) triggers the error.
Seems like we don't verify if the summary actually belongs to the folder we watch it for and/or that the folder it's about actually has the watcher enabled?
lib/model: Only handle relevant folder summaries (kqueue) (fixes sync…
Merge branch 'main' into fs/add-encoder
Merge branch 'main' into tokensdb
Merge branch 'main' into cli_completion
lib/model: Only handle relevant folder summaries (kqueue) (fixes sync…