[Bug 218636] [fuse] [bug] kernel_cache is enabled by default

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Apr 13 16:55:27 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=218636

            Bug ID: 218636
           Summary: [fuse] [bug] kernel_cache is enabled by default
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: kern
          Assignee: freebsd-bugs at FreeBSD.org
          Reporter: ben.rubson at gmail.com

Hello,

>From MOUNT_FUSEFS(8) :
     kernel_cache
             By default cached buffers of a given file are flushed at each
             open(2).  This option disables this behaviour

>From sys/fs/fuse/fuse_kernel.h :
FOPEN_KEEP_CACHE: don't invalidate the data cache on open

However, looking at sys/fs/fuse/fuse_node.c, FOPEN_KEEP_CACHE is never used !

Adding the following in the else{} of fuse_vnode_open() corrected the issue :
if (!(fuse_open_flags & FOPEN_KEEP_CACHE)) {
        fuse_io_invalbuf(vp, td);
}

Issue found investigating this bug :
https://github.com/vgough/encfs/issues/315

Many thanks !

Ben

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list