Re: Questions about XFS

Emmanuel Florac
2013-06-11T13:11:06Z

Le Tue, 11 Jun 2013 09:56:38 +0000 (UTC)
Steve Bergman <sbergman27@gmail.com> écrivait:

> Hi all,
>
> I have a few questions about XFS that didn't make the XFS FAQ. I'm
> trying to get a feel for where I might want to use it on my servers
> (or at home). A mix of ext3 & ext4 has worked well for me. But I'd
> like to get to know XFS a bit better. The target OS would be RHEL6.
>
> 1. I don't have "lots and large". Why should I run XFS?

Because it performs well and reliably.

> 2. I don't have "lots and large". Why shouldn't I run XFS?

Because ext4 is more common and won't uncover unexpected bugs in badly
written applications.

> 3. Why doesn't RHEL6 support XFS on root, when the XFS FAQ says XFS
> on root is fine? Is there some issue I should be aware of?

Not that I know of. I've used XFS as root back in the RedHat 7.x times,
13 years ago. I've used XFS as root on Irix years before that.
However nowadays I use XFS extensively but usually not as root.

> 4. From the time I write() a bit of data, what's the maximum time
> before the data is actually committed to disk?

On the distributions I'm using (Debian, Slackware), no significant
delay that I know of. Even extremely mistreated systems (pulling the
plug while working shouldn't do any harm, should it?)

> 5. Ext4 provides some automatic fsync'ing to avoid the zero-length
> file issue for some common cases via the auto_da_alloc feature added
> in kernel 2.6.30. Does XFS have similar behavior?

I don't know. I keep hearing of this "xfs bug" but never actually
encountered it, ever, though I've set up about 3000 servers with XFS
filesystems, many to work under very harsh conditions.

> 6. RHEL6 Anaconda sets a RAID10 chunk size of 512K by default XFS
> complains and sets its log stripe down to 32k. Should I accept
> Anaconda's default? It knows I've requested XFS formatting before it
> sets the chunk size, after all.

512k seems insanely large to me. Something like 64 or 256k seems more
common, and reasonable. BTW, 256k is a perfectly valid size for xfs log
stripe. My advice: unless you plan on working only with big files,
create a 64k stripe RAID-10. Your performance will be much better, and
XFS will be happy.

> 8. Eric (and the XFS FAQ) have recommended just using the defaults for
> mkfs.xfs and mount. But I've also heard Dave say "Increase logbsize
> and use inode64; everybody does that, but we just haven't made it the
> default". I'm guessing it doesn't matter if one doesn't have large
> and lots?

Actually inode64 is default on recent kernels. Of course this doesn't
apply to RH which for some reason uses only positively jurassic
kernels :)
Increasing logbsize is probably unnecessary except on highly
performance sensitive workloads; currently the 32k default should be
enough.

--
------------------------------------------------------------------------
Emmanuel Florac | Direction technique
| Intellique
| <eflorac@intellique.com>
| +33 1 78 94 84 02
------------------------------------------------------------------------