Description of problem: xfs文件系统,xfstests下generic/569用例Text file busy x86和arm均存在该问题 失败几率:50% 有时候连续几次失败,有时候连续几次成功 测试日志: # ./check tests/generic/569 FSTYP -- ext4 PLATFORM -- Linux/x86_64 iZ2ze6n8cezigzjqlcfjadZ 4.19.91-26_rc1.an7.x86_64 #1 SMP Mon Apr 25 17:24:24 CST 2022 MKFS_OPTIONS -- /dev/vdb2 MOUNT_OPTIONS -- -o acl,user_xattr /dev/vdb2 /fs/scratch generic/569 - output mismatch (see /tmp/tone/run/xfstests/results//generic/569.out.bad) --- tests/generic/569.out 2022-04-27 21:06:24.791729811 +0800 +++ /tmp/tone/run/xfstests/results//generic/569.out.bad 2022-05-05 14:51:16.809639203 +0800 @@ -1,14 +1,11 @@ QA output created by 569 verb 1 -pwrite: Text file busy verb 2 -mmap: Text file busy verb 3 -Caught signal 7, terminating... ... (Run 'diff -u /tmp/tone/run/xfstests/tests/generic/569.out /tmp/tone/run/xfstests/results//generic/569.out.bad' to see the entire diff) Ran: generic/569 Failures: generic/569 Failed 1 of 1 tests Version-Release number of selected component (if applicable): # uname -a Linux iZ2ze6n8cezigzjqlcfjadZ 4.19.91-26_rc1.an7.x86_64 #1 SMP Mon Apr 25 17:24:24 CST 2022 x86_64 x86_64 x86_64 GNU/Linux # uname -a Linux iZ2zebfu2pfe96wy4xb5lsZ 4.19.91-26_rc1.an7.aarch64 #1 SMP Mon Apr 25 17:30:58 CST 2022 aarch64 aarch64 aarch64 GNU/Linux # cat /etc/os-release NAME="Anolis OS" VERSION="7.7" ID="anolis" ID_LIKE="rhel fedora centos" VERSION_ID="7.7" PRETTY_NAME="Anolis OS 7.7" ANSI_COLOR="0;31" HOME_URL="https://openanolis.cn/" BUG_REPORT_URL="https://bugs.openanolis.cn/" CENTOS_MANTISBT_PROJECT="CentOS-7" CENTOS_MANTISBT_PROJECT_VERSION="7" REDHAT_SUPPORT_PRODUCT="centos" REDHAT_SUPPORT_PRODUCT_VERSION="7" How reproducible: 1. 准备环境 #准备disk1 disk2测试盘 disk1=vdb1 disk2=vdb2 dmsetup remove_all wipefs -a --force /dev/$disk1 wipefs -a --force /dev/$disk2 mkfs -t ext4 -q -F /dev/$disk1 mkfs -t ext4 -q -F /dev/$disk2 export TEST_DIR=/fs/$disk1 export TEST_DEV=/dev/$disk1 export FSTYP=ext4 export SCRATCH_MNT=/fs/scratch mkdir /fs/$disk1 -p mkdir /fs/scratch -p export SCRATCH_DEV=/dev/$disk2 2. 下载xfstests测试代码 3. 编译测试源码 cd xfstests-dev export CFLAGS="-fcommon" make make install 4.执行测试用例 ./check tests/generic/569 Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info: xfsprogs-4.5.0-22.an7.x86_64
an8无此用例
(In reply to kangjiangbo from comment #1) > an8无此用例 更新下 xfstests
https://github.com/kdave/xfstests/commit/db8feee94964c23742ce503986531f58e35a5ea7 generic: check that we can't write to swap files While active, the media backing a swap file is leased to the kernel. Userspace has no business writing to it. Make sure we can't do this. The two kernel patches titled as below should fix the bug: mm: set S_SWAPFILE on blockdev swap devices vfs: don't allow writes to swap files 该测试用例用于测试是否禁止写入swap file。对应的两个内核补丁并没有引入到4.19内核。 https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=1638045c36772b47a0765f7dca07cb90267e4942 https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=dc617f29dbe5ef0c8ced65ce62c464af1daaab3d
merged at: https://gitee.com/anolis/cloud-kernel/pulls/340
RC3版本验证通过