fix: Mount: When the cache space is insufficient, repeated string #9062
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix: Reduce duplicate log messages when VFS cache runs out of space
Summary
When the VFS cache runs out of disk space, rclone generates excessive duplicate log messages that can rapidly fill up log files and make debugging difficult. This fix implements rate limiting and deduplication for out-of-space error messages across the VFS cache subsystem, significantly reducing log noise while preserving essential diagnostic information.
Changes Made
vfs/vfscache/cache.go
LogftoDebugfto reduce noise during normal cache cleanup operationsvfs/vfscache/downloaders/downloaders.go
lastOutOfSpaceLogfield to track when out-of-space messages were last logged_countErrorsto only log every 5th error for out-of-space conditions, reducing repetitive messages during sustained space pressurekickWaitersto log out-of-space errors at most once per 10 secondsvfs/vfscache/item.go
firstErrortracking variable inReadAtretry loopTesting
Fixes
Fixes #4998
Checklist