2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2000-2004 Silicon Graphics, Inc. All Rights Reserved.
7 # Test upgrading the XFS log to v2
10 _begin_fstest log v2log auto
12 # Import common functions.
16 # real QA test starts here
18 # Modify as appropriate.
23 if [ "$(blockdev --getss $SCRATCH_DEV)" != "512" ]; then
24 _notrun "need 512b sector size"
27 export MOUNT_OPTIONS="-o logbsize=64k"
29 # try and mount a v1 log with a v2 LRsize
31 _mkfs_log "-l version=1 -m crc=0 -d sectsize=512"
32 _scratch_xfs_db -c 'version' | tr ',' '\n' | grep LOGV2
35 # now make the fs a v2 fs and try to mount again
36 # it should succeed this time
37 _scratch_xfs_db -x -c 'version log2' | tr ',' '\n' | grep LOGV2