]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: account for large extents with enospc
authorJosef Bacik <jbacik@fb.com>
Wed, 11 Feb 2015 20:08:59 +0000 (15:08 -0500)
committerChris Mason <clm@fb.com>
Sat, 14 Feb 2015 16:22:48 +0000 (08:22 -0800)
commitce1bed24c77331726b1a93d488ef00f9c5e07f15
tree4aa9951e7ab997702f90aec9882f305e1885fc40
parenta71e701ffb26aa95a9084dee3b8de258da7830ea
Btrfs: account for large extents with enospc

On our gluster boxes we stream large tar balls of backups onto our fses.  With
160gb of ram this means we get really large contiguous ranges of dirty data, but
the way our ENOSPC stuff works is that as long as it's contiguous we only hold
metadata reservation for one extent.  The problem is we limit our extents to
128mb, so we'll end up with at least 800 extents so our enospc accounting is
quite a bit lower than what we need.  To keep track of this make sure we
increase outstanding_extents for every multiple of the max extent size so we can
be sure to have enough reserved metadata space.  Thanks,

Signed-off-by: Josef Bacik <jbacik@fb.com>
Signed-off-by: Chris Mason <clm@fb.com>
fs/btrfs/ctree.h
fs/btrfs/extent-tree.c
fs/btrfs/extent_io.c
fs/btrfs/inode.c