You are not logged in.
Yep, I'm back... Long story. I'll explain later.
Anyway, I'm using XFS, with barriers disabled for performance reasons (write performance is abominable with them enabled). But I want better data integrity... I'm not interested in completely disabling the write cache, because that would also kill performance; instead I'd like to have the buffers flushed every few seconds as ext3 does. (IIRC ext3 flushes its buffers every five seconds, which seems to work pretty well; I've never lost data with it.)
So I'm wondering, how can I change XFS' maximum write delay so it does that?
Offline
Offline
I have no answer to the particular question but IIRC XFS behaves like ext4(kernel>=2.6.30) which is considered safe!
English is not my native language .
Offline
Hmm. Something changed about how ext4 works? I thought that also had problems with the write barrier slowing things down?
Offline
Hmm , quote from the end of this blog post :
ext2: No robustness guarantees on system crash at all.
ext3: In the default data=ordered mode it is safe, because data is written before metadata. If you crash before the data is written (5 seconds by default) you get the old data. With data=writeback mode it is unsafe.
ext4: Currently unsafe, with a quite long window where you risk data loss. With the patches queued for 2.6.30 it is safe.
btrfs: Currently unsafe, the maintainer claims that patches are queued for 2.6.30 to make it safe
XFS: Currently unsafe (as far as i can tell), however the truncate and overwrite method is safe.
However , I recall the XFS devs mentioning many times that their FS was safe for the last year or two . The discussion usually went like this :
<Whining user/dev/blogger> Why would you break things that worked with ext3 .
<Theodore Ts'o> Performance gains . It's not just me . XFS did this long time ago & BTRFS are doing it too .
<XFS dev> Stop bringing up XFS everywhere . We fixed our sh** long time ago. We haven't had this issue for ages .
Last edited by Nezmer (2009-07-31 11:53:16)
English is not my native language .
Offline
instead I'd like to have the buffers flushed every few seconds as ext3 does.
simply use sysctl
I have no answer to the particular question but IIRC XFS behaves like ext4(kernel>=2.6.30) which is considered safe!
hmm.. this is the other way around: after much criticizing xfs, someone just have made ext4 copying xfs features (and still falling behind in some aspects).
this is not the first instance like this
Offline
instead I'd like to have the buffers flushed every few seconds as ext3 does.
simply use sysctl
I have no answer to the particular question but IIRC XFS behaves like ext4(kernel>=2.6.30) which is considered safe!
hmm.. this is the other way around: after much criticizing xfs, someone just have made ext4 copying xfs features (and still falling behind in some aspects).
this is not the first instance like this
You missed my second reply .
English is not my native language .
Offline
Okay, 'nother question... Is setting hdparm -W0 on my hard drive functionally the same as mounting all my filesystems with the sync options? Or do they have different effects? Which would be worse for performance?
(Right now I'm using XFS + nobarrer + "hdparm -W0 /dev/sda" in /etc/rc.local, but I'm not quite satisfied with that...)
Offline
hdparm -W0 /dev/sda
might improve system performance
another thing would be optimized formatting (you can further optimize xfs for small files), but I assume this is too late
Offline
http://everything2.com/title/Filesystem … S+on+Linux
This might be interesting to the OP.
EDIT: This is what I was told on the XFS mailing list today about turning off a drive's cache:
When drive write caches lose power it may lead to inconsistencies in a journaling filesystem like xfs, which relies on data hitting the disk in a certain order, more or less. By default xfs issues barriers to enforce this ordering; this has the effect of flushing the write cache to make it safe. In some cases disabling barriers and also disabling write cache may be a good choice.
If you "never" lose power (good ups?) then write caching is safe even w/o barriers.
Last edited by RagePie (2009-08-20 16:36:21)
Offline
Okay one more question... What do I put in sysctl to get the same effect as "hdparm -W0" for all drives? Putting "hdparm -W0 /dev/sda" in /etc/rc.local works, but it's kind of kludgy. I know that on FreeBSD you can use hw.ata.wc=0, is there an equivalent for Linux?
Offline
ZFS ... Now that is a file system to get excited about
Dam licensing problems Doesn't mesh with GNU.
But really I have nothing of use for you. I messed around with XFS and stuff but in the end I learned that when it comes to your file system what matters is... Stability, stability, stability, and vary last performance. EXT4 is to beta for me.
I got an OCZ Vertex SSD instead.
Last edited by hunterthomson (2009-08-27 03:58:51)
OpenBSD-current Thinkpad X230, i7-3520M, 16GB CL9 Kingston, Samsung 830 256GB
Contributor: linux-grsec
Offline