]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit
mkfs: default log size for small filesystems too large
authorDave Chinner <dchinner@redhat.com>
Fri, 28 Feb 2014 01:04:12 +0000 (12:04 +1100)
committerDave Chinner <david@fromorbit.com>
Fri, 28 Feb 2014 01:04:12 +0000 (12:04 +1100)
commit9718fa2061800fffc037918a0c1baf87fc1c0998
treebf7e9f96285ec535ff585cdfcc0a2b922f68449f
parentda2b3c099e398d0cc5d342c0827beccd52937f30
mkfs: default log size for small filesystems too large

Recent changes to the log size scaling have resulted in using the
default size multiplier for the log size even on small filesystems.
Commit 88cd79b ("xfs: Add xfs_log_rlimit.c") changed the calculation
of the maximum transaction size that the kernel would issues and
that significantly increased the minimum size of the default log.
As such the size of the log on small filesystems was typically
larger than the prefious default, even though the previous default
was still larger than the minimum needed.

Rework the default log size calculation such that it will use the
original log size default if it is larger than the minimum log size
required, and only use a larger log if the configuration of the
filesystem requires it.

This is especially obvious in xfs/216, where the default log size is
10MB all the way up to 16GB filesystems. The current mkfs selects a
log size of 50MB for the same size filesystems and this is
unnecessarily large.

Return the scaling of the log size for small filesystems to
something similar to what xfs/216 expects.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
mkfs/xfs_mkfs.c