Strange behaviour with sappend flag set on ZFS

Kostik Belousov kostikbel at gmail.com
Fri Sep 24 07:05:20 UTC 2010


On Fri, Sep 24, 2010 at 10:42:54AM +1000, Bruce Evans wrote:
> ffs_write() is also missing the check for read-only mounts.  This is subtle.
> I think the fs cannot be mounted read-only if ffs_write() is reached --
> even if the file was opened for writing at a time when the mount was
> read-write, the file must have been dowgraded to unwriteable of the mount
> was successfully downgraded to read-only (takes a forced unmount which
> tends to break applications but shouldn't break the file system).
The files open for write are effectively closed on rw->ro downgrade.
Technically, the vnodes are reclaimed at the time of remount, and
still open file descriptors return appropriate deadfs errors on i/o ops,
typically ENXIO or EIO.

There is a known brokeness with remounts, where the writeable shared
mappings of the vnodes are not accounted for the write count of vnode.
I have lingering patch for the issue that is not committed for
some reasons.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-fs/attachments/20100924/f752a1f6/attachment.pgp


More information about the freebsd-fs mailing list