On Tue, Feb 04, 2025 at 01:27:15PM -0800, Darrick J. Wong wrote: > From: Darrick J. Wong <djwong@xxxxxxxxxx> > > Commit 000813899afb46 hardcoded a log size of 256MB into xfs/501, > xfs/502, and generic/530. This seems to be an attempt to reduce test > run times by increasing the log size so that more background threads can > run in parallel. Unfortunately, this breaks a couple of my test > configurations: > > - External logs smaller than 256MB > - Internal logs where the AG size is less than 256MB > > For example, here's seqres.full from a failed xfs/501 invocation: > > ** mkfs failed with extra mkfs options added to " -m metadir=2,autofsck=1,uquota,gquota,pquota, -d rtinherit=1," by test 501 ** > ** attempting to mkfs using only test 501 options: -l size=256m ** > size 256m specified for log subvolume is too large, maximum is 32768 blocks > <snip> > mount -ortdev=/dev/sdb4 -ologdev=/dev/sdb2 /dev/sda4 /opt failed > umount: /dev/sda4: not mounted. > > Note that there's some formatting error here, so we jettison the entire > rt configuration to force the log size option, but then mount fails > because we didn't edit out the rtdev option there too. > > Fortunately, mkfs.xfs already /has/ a few options to try to improve > parallelism in the filesystem by avoiding contention on the log grant > heads by scaling up the log size. These options are aware of log and AG > size constraints so they won't conflict with other geometry options. > > Use them. Good solution to the problem. Reviewed-by: Dave Chinner <dchinner@xxxxxxxxxx> -- Dave Chinner david@xxxxxxxxxxxxx