[Bug 107301] system hang during ext4 xattr operation

bugzilla-daemon
2015-11-11T02:38:06Z

--- Comment #14 from Theodore Tso <tytso@mit.edu> ---
In response to Jan's concerns in comment #11, I wonder if we can use some
hueristics to decide when to use mbcache and when to skip it. So if there are
ways that we can identify certain xattr's by name or type as being almost
always unique, then if there are any of those xattrs in the external xattr
block, there's no point using the mbcache. If we had such a function, we
could also use it to bias putting the unique xattrs in the extended inode
space, which might increase the chance that the external xattr block is more
likely to be shareable.

The final thing I'll note is that because of the mbcache locking, it can turn
into a real scalability bottlencheck for ext4, and it's not clear this is a
soluble problem. So if you are running on a high-CPU count machine, and you
are using xattrs, and (for example) the SELinux xattr is so piggy that it won't
fit in your 256-byte inodes, things can get pretty painful.