--
To post to this group, send email to zfs-...@googlegroups.com
To visit our Web site, click on http://zfs-fuse.net/
While I have been wrong in the past, I was under the impression that one of the primary purposes of using zfs is to secure the data at all costs. Now speed is a huge detriment to the current usability of the zfs-fuse, but if we compromise on integrity for speed, is it really zfs anymore? Power failures happen, as do hard crashes. I can see this as a great mount option, but I don't know if I would want it as standard for my own build. Just a thought.
While I have been wrong in the past, I was under the impression that one of the primary purposes of using zfs is to secure the data at all costs. Now speed is a huge detriment to the current usability of the zfs-fuse, but if we compromise on integrity for speed, is it really zfs anymore? Power failures happen, as do hard crashes. I can see this as a great mount option, but I don't know if I would want it as standard for my own build. Just a thought.
--
To post to this group, send email to zfs-...@googlegroups.com
To visit our Web site, click on http://zfs-fuse.net/
Don't worry it's easy to turn this into an option. But anyway you would not loose much at max 128k worth of updates per opened file which can happen even without this. The fs can't be compromised it's at the file level only.
Now get me right: I think your patch does all the above, so it should be
safe, but it is a valid worry, because things (not the fs, but still
important) can get corrupted if not.
Seth
--
To post to this group, send email to zfs-...@googlegroups.com
To visit our Web site, click on http://zfs-fuse.net/
> This is the only problem I found so far, and I am quite surprised by
> the very big number of programs which used these buffers actually
> (just start an x session with your home on zfs and the buffers are
> already used very much !).
I was still intending to compare with ntfs-3g, allthough with the
current thoughts/info I'm starting to expect that ntfs has no such
buffering optimization. Much could also be learned by running the posix
compliance test again with the optimization on, I suppose. But I have
never before ran that beast
Seth
On 02/22/2011 12:27 AM, Emmanuel Anne wrote:I don't suggest you post anything like this near git devs. Linus and his
>
> And it's quite stupid, I don't see any reason why git checks the file
> size before closing it ?
friend tend to be quite strong opinioned about tech stuff like that. And
the sad truth is that they are usually horribly right. :)
I was still intending to compare with ntfs-3g, allthough with the
> This is the only problem I found so far, and I am quite surprised by
> the very big number of programs which used these buffers actually
> (just start an x session with your home on zfs and the buffers are
> already used very much !).
current thoughts/info I'm starting to expect that ntfs has no such
buffering optimization. Much could also be learned by running the posix
compliance test again with the optimization on, I suppose. But I have
never before ran that beast
Seth
--
To post to this group, send email to zfs-...@googlegroups.com
To visit our Web site, click on http://zfs-fuse.net/
> I didn't bother with threads because if a program accessed getattr on
> 1 thread while the other were doing operations on the same file, the
> results would be unpredictable, so it's probably no use to add locks
> here.
Agreed. However, let's make sure that we must return either A (before)
or B (after), but not any random racy value :)
>
> git commit works again here, but it's too late to commit, I'll wait
> until tomorrow, and run this posix compliance test suite again (you
> should try it one day, a nice piece of software, you learn quite a few
> things just by looking at how it works !).
Ok, I'll start by remembering where to ofind i. On the ntfs-3g project
page, wasn't it?
>
> I also added a command line parameter to disable it (--no-buffers),
> and something to detect when a file is opened with FSYNC flag (or
> OSYNC), and disable buffers in this case.
That's brilliant!
--
To post to this group, send email to zfs-...@googlegroups.com
To visit our Web site, click on http://zfs-fuse.net/
http://www.tuxera.com/community/posix-test-suite/
The 2009 version was never finished, so the one to use is still the 2008 one.
2009 has some tests about xattrs.
I was right not to commit last night. After some thought I decided to change the way it works : at 1st I had just adapted the size returned by _getattr if it had some buffers, but it might be wrong if the process writes in the middle of the file instead of at the end.
So now if _getattr is called for a file which has a buffer, the buffer is flushed 1st.
It created a ton of problems with threads, I won't give the details of all I had but it was messy.
So finally I have a lock for this new struct too.
It's way too much for something which is supposed to be so simple, so if one day fuse passes the right parameter to _getattr it should be removed.
I'll try to send a mail to them later about that.
Now I have something quite big to commit in 1 time, sorry !
I ran the pjd tests and all tests succeeded. Could not reproduce any problem, I think it's good for a commit now...
Ok, let's see it :)
Now I have something quite big to commit in 1 time, sorry !
I ran the pjd tests and all tests succeeded. Could not reproduce any problem, I think it's good for a commit now...
0001-filtering-for-pid-_does_-hurt.patchIn part these are just reformatting the patch so it was easier for me to see what did _not_ change. However these could be serious:
0002-unshuffle-zfs_operations.c-so-we-can-see-what-change.patch
0003-no-need-to-redefine-int_zfs_enter.patch
0004-sanity-check-to-avoid-leaving-the-lock-hanging.patch
0005-review-and-simplify-free_fi.patch
0006-good-custom-on-reallocations-is-to-grow-by-a-factor-.patch
0007-inverted-error-code-not-by-design.patch
0008-being-anal-about-potential-integer-overflows-and-sig.patch
0009-sanity-checks-on-storing-fi-records.patch
0010-avoid-unrelated-changes.patch
0011-fuse-and-zfs-inodes-were-mixed-up-misplaced-FUSE2ZFS.patch
0012-centralized-buffer-flushing-logic-and-make-errors-go.patch
0001-filtering-for-pid-_does_-hurt.patch
I strongly believe that all processes should know about file changes (e.g. size) exactly like in the unbuffered world. This is as it has been. (Think of it this way, if git decides to use forks to check for the filestat changes, it should still work).
0007-inverted-error-code-not-by-design.patchPS.: If a client follows a small write (<4096) by a very large one (say, 512Mb) then your allocation algorithm will resize to the exisiting buffer before flushing. The buffer is never downsized until the file is closed, so this could lead to problems. Unlikely though, so I left it for now.
ok, mild, but could be confusing0011-fuse-and-zfs-inodes-were-mixed-up-misplaced-FUSE2ZFS.patch
this is really the most interesting one0012-centralized-buffer-flushing-logic-and-make-errors-go.patch
this should make Brian (and me) a lot happier. Let's not forget any errors, just because they were buffered. My policy has been to try to follow as many commands as possible (e.g. _do_ fsync the disks even though there was an error flushing the buffer) _but_ never swallow an error. Syslog is our friend, and where posisble, fuse will get the error condition as well, even though belated because of the buffering.
In cases where the 'later' operation (that triggered the flush) resulted in an error, the 'old' error might not be reported to fuse, which is why I also croak to syslog.
PS. disclaimer: this entire review was done in an editor. I haven't
actually ran any tests
--
To post to this group, send email to zfs-...@googlegroups.com
To visit our Web site, click on http://zfs-fuse.net/
> But I'll look again at the pid problem, there might be something there.
There isn't a big problem, except that it is arbitrary to up-and-decide
that other processes do not need up to date information. I don't know
what you decide that for, but it seems a bit unexpected to me.
The comment (paranoid?) seemed to suggest you were doing this as some
kind of security measure, which seemed a bit off-track to me.
--
To post to this group, send email to zfs-...@googlegroups.com
To visit our Web site, click on http://zfs-fuse.net/
To visit our Web site, click on http://zfs-fuse.net/