Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 25 Dec 2015 04:03:13 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-fs@FreeBSD.org
Subject:   [Bug 194293] FUSE program freezes when seeking pos > file size
Message-ID:  <bug-194293-3630-hgzeVHIr3s@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-194293-3630@https.bugs.freebsd.org/bugzilla/>
References:  <bug-194293-3630@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=194293

Rick Macklem <rmacklem@FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rmacklem@FreeBSD.org

--- Comment #4 from Rick Macklem <rmacklem@FreeBSD.org> ---
I think I know what causes the hang for the small write
(test.c).
Could you try the program, but change "w" to "rw" in the
fopen().

- I think the problem happens when a file is opened "write only"
  and then a partial block is written. The write of the partial
  buffer cache block requires that the block first be read from
  the file, but "write only" doesn't allow that to happen and
  it gets stuck.

If test.c works ok when opening "rw", then I think this is what
is happening.

--> I am thinking that fuse_vnop_open(..O_WRONLY..) should actually
    do a O_RDWR open. It means that files that only give the user
    write access won't be able to be opened, but that seems to be
    preferred to a hang?

Please let us know if you get to try this, rick.

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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-194293-3630-hgzeVHIr3s>