Thread View: muc.lists.freebsd.bugs
2 messages
2 total messages
Started by bugzilla-noreply
Tue, 17 Nov 2026 23:35
[Bug 300857] [fusefs] Requests to a slow fuse daemon can snowball, leading to extreme memory usage in fuse_msgbuf
Author: bugzilla-noreply
Date: Tue, 17 Nov 2026 23:35
Date: Tue, 17 Nov 2026 23:35
78 lines
4669 bytes
4669 bytes
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=300857
Bug ID: 300857
Summary: [fusefs] Requests to a slow fuse daemon can snowball,
leading to extreme memory usage in fuse_msgbuf
Product: Base System
Version: 15.1-RELEASE
Hardware: Any
OS: Any
Status: New
Severity: Affects Only Me
Priority: ---
Component: kern
Assignee: bugs@FreeBSD.org
Reporter: asomers@FreeBSD.org
BUG
===
If a fuse daemon cannot answer requests as fast as a process can make them,
they might start to time out, leading to a snowball situation where millions of
requests get queued and eventually all RAM is exhausted.
DIAGNOSTICS
===========
* A large value for the vfs.fusefs.stats.ticket_count sysctl. Normally this
should be in the dozens. If it's in the millions, that's a problem.
* A large amount of memory in the fuse_msgbuf zone, as shown by "vmstat -m",
approaching all of the system's RAM.
WORKAROUND
==========
Killing the userspace process that's accessing the fuse file system is not
sufficient. The file system must be forcibly unmounted with "umount -f".
Doing that will successfully deallocate the memory.
ANALYSIS
========
The fusefs file system has a timeout that defaults to 60s. If the daemon fails
to respond to a request in that time, the request will fail with ETIMEDOUT.
However, fusefs doesn't actually remove that request from the request queue.
So the daemon still has the burden of processing it, even though the client
process will never get the answer. That can lead to poor performance. It
could even be a correctness issue; for example, the daemon might complete a
write that the client thinks failed. Worse, the client might retry the
request. Our own `namei` function for example will retry VOP_LOOKUP in
response to ETIMEDOUT. Combined with the lack-of-removal-from-the-queue that
creates positive feedback: if the daemon is too slow to respond to all of its
requests in timely fashion then it gets even more work to do, causing it to
fall even further behind. It can snowball badly.
STEPS TO REPRODUCE
==================
I have seen this bug triggered multiple times by running a command like `find .
-ls` on a slow ntfs-3g file system (from filesystems/ntfs) in ports. I don't
yet have a minimal reproducer.
--
You are receiving this mail because:
You are the assignee for the bug.
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-admin@muc.de
[Bug 300857] [fusefs] Requests to a slow fuse daemon can snowball, leading to extreme memory usage in fuse_msgbuf
Author: bugzilla-noreply
Date: Tue, 17 Nov 2026 23:35
Date: Tue, 17 Nov 2026 23:35
17 lines
2633 bytes
2633 bytes
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=300857
Alan Somers <asomers@FreeBSD.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|New |Open
Assignee|bugs@FreeBSD.org |asomers@FreeBSD.org
--
You are receiving this mail because:
You are the assignee for the bug.
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-admin@muc.de
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads