Bug 9005 - [Anolis23.1 GA][Beta][ANCK-6.6.25-2][x86_64][xfstests]xfstests测试套ext4-2-overlay执行overlay/035项Fail:mount: /fs/nvme1n1p2/ovl-mnt: mount point not mounted or bad option
Summary: [Anolis23.1 GA][Beta][ANCK-6.6.25-2][x86_64][xfstests]xfstests测试套ext4-2-overl...
Status: NEW
Alias: None
Product: Antest
Classification: Infrastructures
Component: 测试用例 (show other bugs) 测试用例
Version: unspecified
Hardware: All Linux
: P3-Medium S3-normal
Target Milestone: ---
Assignee: yunmeng365524
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-05-11 14:41 UTC by Banana
Modified: 2024-05-11 14:41 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Banana alibaba_cloud_group 2024-05-11 14:41:05 UTC
[问题描述]:
xfstests测试套ext4-2-overlay执行overlay/035测试项FAIL:mount: /fs/nvme1n1p2/ovl-mnt: mount point not mounted or bad option

[root@iZbp1c9jzchxjqive233ufZ xfstests]# ./check -overlay tests/overlay/035
FSTYP         -- overlay
PLATFORM      -- Linux/x86_64 iZbp1c9jzchxjqive233ufZ 6.6.25-2_rc1.an23.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Apr 11 15:05:18 CST 2024
MKFS_OPTIONS  -- /fs/nvme1n1p2
MOUNT_OPTIONS -- -o context=system_u:object_r:root_t:s0 /fs/nvme1n1p2 /fs/nvme1n1p2/ovl-mnt

overlay/035       - output mismatch (see /root/tone/run/xfstests/results//overlay/035.out.bad)
    --- tests/overlay/035.out   2024-05-07 14:36:15.276431964 +0800
    +++ /root/tone/run/xfstests/results//overlay/035.out.bad    2024-05-11 14:36:35.983806317 +0800
    @@ -1,5 +1,5 @@
     QA output created by 035
     touch: cannot touch 'SCRATCH_MNT/foo': Read-only file system
    -mount: cannot remount device read-write, is write-protected
    +mount: /fs/nvme1n1p2/ovl-mnt: mount point not mounted or bad option
     touch: cannot touch 'SCRATCH_MNT/bar': Read-only file system
    -mount: cannot remount device read-write, is write-protected
    +mount: /fs/nvme1n1p2/ovl-mnt: mount point not mounted or bad option
    ...
    (Run 'diff -u /root/tone/run/xfstests/tests/overlay/035.out /root/tone/run/xfstests/results//overlay/035.out.bad'  to see the entire diff)
Ran: overlay/035
Failures: overlay/035
Failed 1 of 1 tests

------实际输出------
[root@iZbp1c9jzchxjqive233ufZ xfstests]# cat /root/tone/run/xfstests/results//overlay/035.out.bad
QA output created by 035
touch: cannot touch 'SCRATCH_MNT/foo': Read-only file system
mount: /fs/nvme1n1p2/ovl-mnt: mount point not mounted or bad option
touch: cannot touch 'SCRATCH_MNT/bar': Read-only file system
mount: /fs/nvme1n1p2/ovl-mnt: mount point not mounted or bad option

------预期输出------
[root@iZbp1c9jzchxjqive233ufZ xfstests]# cat /root/tone/run/xfstests/tests/overlay/035.out
QA output created by 035
touch: cannot touch 'SCRATCH_MNT/foo': Read-only file system
mount: cannot remount device read-write, is write-protected
touch: cannot touch 'SCRATCH_MNT/bar': Read-only file system
mount: cannot remount device read-write, is write-protected

-----dmesg日志------
[345957.993097] run fstests overlay/035 at 2024-05-11 14:36:35
[345958.333110] EXT4-fs (nvme1n1p2): mounted filesystem ae981fb4-c702-4c37-a524-9f132d4072c4 r/w with ordered data mode. Quota mode: none.
[345958.359966] overlayfs: failed to create directory /fs/nvme1n1p2/workdir/work (errno: 1); mounting read-only
[345958.371697] overlayfs: failed to create directory /fs/nvme1n1p2/workdir/work (errno: 1); mounting read-only
[345958.387709] EXT4-fs (nvme1n1p1): unmounting filesystem 5aad5f1b-0632-4fbc-993b-fb2591b1a6e1.
[345958.403498] EXT4-fs (nvme1n1p2): unmounting filesystem ae981fb4-c702-4c37-a524-9f132d4072c4.

[环境信息]:
机器类型:ECS

[内核信息]:
[root@iZbp1c9jzchxjqive233ufZ xfstests]# uname -r
6.6.25-2_rc1.an23.x86_64

[操作系统信息]:
[root@iZbp1c9jzchxjqive233ufZ xfstests]# cat /etc/os-release
NAME="Anolis OS"
VERSION="23"
ID="anolis"
VERSION_ID="23"
PLATFORM_ID="platform:an23"
PRETTY_NAME="Anolis OS 23"
ANSI_COLOR="0;31"
HOME_URL="https://openanolis.cn/"
BUG_REPORT_URL="https://bugzilla.openanolis.cn/"


[文件系统]
[root@iZbp1c9jzchxjqive233ufZ xfstests]# df -Th
Filesystem     Type      Size  Used Avail Use% Mounted on
devtmpfs       devtmpfs  4.0M     0  4.0M   0% /dev
tmpfs          tmpfs     7.6G     0  7.6G   0% /dev/shm
tmpfs          tmpfs     3.1G  592K  3.1G   1% /run
/dev/nvme0n1p2 xfs        40G  5.1G   35G  13% /
tmpfs          tmpfs     7.6G   26M  7.6G   1% /tmp
tmpfs          tmpfs     1.6G     0  1.6G   0% /run/user/0
/dev/nvme1n1p2 ext4       19G  2.1M   18G   1% /fs/nvme1n1p2
/dev/nvme1n1p1 ext4       17G  2.1M   16G   1% /fs/nvme1n1p1

[问题发生概率]:
必现

[复现步骤]:
1、部署xfstests环境
2、部署测试环境
wipefs -a -f /dev/nvme1n1
wipefs -a -f /dev/nvme1n1
partprobe /dev/nvme1n1
parted -s /dev/nvme1n1 mklabel gpt mkpart primary 2048 20480
partprobe /dev/nvme1n1
parted -s /dev/nvme1n1 mkpart primary 20480 40960
mkfs -t ext4 -E lazy_itable_init=0,lazy_journal_init=0 -L OStest -q -F  -q -F /dev/nvme1n1p2
mount  /dev/nvme1n1p2 /fs/nvme1n1p2
mkfs -t ext4 -E lazy_itable_init=0,lazy_journal_init=0 -L OStest -q -F  -q -F /dev/nvme1n1p1
mount  /dev/nvme1n1p1 /fs/nvme1n1p1
export FSTYP=ext4
export TEST_DEV=/dev/nvme1n1p1
export SCRATCH_DEV=/dev/nvme1n1p2
export TEST_DIR=/fs/nvme1n1p1
export SCRATCH_MNT=/fs/nvme1n1p2
3、执行./check -overlay tests/overlay/035命令