-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
rhel-9.4
-
None
-
None
-
rhel-sst-virtualization-storage
-
ssg_virtualization
-
None
-
False
-
-
None
-
None
-
None
-
None
-
-
aarch64
-
None
What were you trying to do that didn't work?
Running xfstest generic/423 on guest (virtiofs + xfs), I hit the below error.
[stdlog] PLATFORM -- Linux/aarch64 localhost 5.14.0-402.el9.aarch64+64k #1 SMP PREEMPT_DYNAMIC Thu Dec 21 18:39:14 EST 2023
[stdlog] MKFS_OPTIONS -- myfs2
[stdlog] MOUNT_OPTIONS – -o context=system_u:object_r:root_t:s0 myfs2 /mnt/myfs2
[stdlog]
[stdlog] generic/221 - output mismatch (see /home/xfstests-dev/results//generic/221.out.bad)
[stdlog] — tests/generic/221.out 2024-01-08 12:58:58.720247072 +0800
[stdlog] +++ /home/xfstests-dev/results//generic/221.out.bad 2024-01-08 12:59:44.740573870 +0800
[stdlog] @@ -1,2 +1,3 @@
[stdlog] QA output created by 221
[stdlog] Silence is golden.
[stdlog] +failed to update ctime!
[stdlog] ...
[stdlog] (Run 'diff -u /home/xfstests-dev/tests/generic/221.out /home/xfstests-dev/results//generic/221.out.bad' to see the entire diff)
[stdlog] generic/423 - output mismatch (see /home/xfstests-dev/results//generic/423.out.bad)
[stdlog] — tests/generic/423.out 2024-01-08 12:58:58.740247214 +0800
[stdlog] +++ /home/xfstests-dev/results//generic/423.out.bad 2024-01-08 12:59:44.940575291 +0800
[stdlog] @@ -6,6 +6,12 @@
[stdlog] Test statx on a file
[stdlog] 20+0 records in
[stdlog] 20+0 records out
[stdlog] +[!] mtime.sec is before ref_m.sec (1704689984 < 1704689985)
[stdlog] +Failed
[stdlog] +stat_test failed
[stdlog] Test statx on a symlink
[stdlog] ...
[stdlog] (Run 'diff -u /home/xfstests-dev/tests/generic/423.out /home/xfstests-dev/results//generic/423.out.bad' to see the entire diff)
[stdlog] Ran: generic/221 generic/423
[stdlog] Failures: generic/221 generic/423
Please provide the package NVR for which bug is seen:
hostname: ampere-mtsnow-altramax-22.khw.eng.rdu2.dc.redhat.com
RHEL-9.4.0-20240111.9
edk2-aarch64-20231122-1.el9.noarch
qemu version: qemu-kvm-8.2.0-2.el9
virtiofsd-1.7.2-1.el9.aarch64
guest kernel: 5.14.0-406.el9.aarch64+64k
host kernel: 5.14.0-406.el9.aarch64+64k
How reproducible:
20%
Steps to reproduce
/usr/libexec/virtiofsd --socket-path=/var/tmp/avocado-vt-vm1-fs1-virtiofsd.sock -o source=/tmp/virtio_fs1_test -o writeback -o cache=always --xattr --modcaps=+sys_admin
/usr/libexec/virtiofsd --socket-path=/var/tmp/avocado-vt-vm1-fs2-virtiofsd.sock -o source=/tmp/virtio_fs2_test -o writeback -o cache=always --xattr --modcaps=+sys_admin
/usr/libexec/qemu-kvm \
-name 'avocado-vt-vm1' \
-sandbox on \
-blockdev '{"node-name": "file_aavmf_code", "driver": "file", "filename": "/usr/share/edk2/aarch64/QEMU_EFI-silent-pflash.qcow2", "auto-read-only": true, "discard": "unmap"}' \
-blockdev '{"node-name": "drive_aavmf_code", "driver": "qcow2", "read-only": true, "file": "file_aavmf_code"}' \
-blockdev '{"node-name": "file_aavmf_vars", "driver": "file", "filename": "/home/kar/workspace/root/avocado/data/avocado-vt/avocado-vt-vm1_rhel940-aarch64-64k-virtio-scsi_qcow2_filesystem_VARS.qcow2", "auto-read-only": true, "discard": "unmap"}' \
-blockdev '{"node-name": "drive_aavmf_vars", "driver": "qcow2", "read-only": false, "file": "file_aavmf_vars"}' \
-machine virt,gic-version=host,pflash0=drive_aavmf_code,pflash1=drive_aavmf_vars \
-device '{"id": "pcie-root-port-0", "driver": "pcie-root-port", "multifunction": true, "bus": "pcie.0", "addr": "0x1", "chassis": 1}' \
-device '{"id": "pcie-pci-bridge-0", "driver": "pcie-pci-bridge", "addr": "0x0", "bus": "pcie-root-port-0"}' \
-nodefaults \
-device '{"id": "pcie-root-port-1", "port": 1, "driver": "pcie-root-port", "addr": "0x1.0x1", "bus": "pcie.0", "chassis": 2}' \
-device '{"driver": "virtio-gpu-pci", "bus": "pcie-root-port-1", "addr": "0x0"}' \
-m 32768 \
-object '{"size": 34359738368, "mem-path": "/dev/shm", "share": true, "id": "mem-mem1", "qom-type": "memory-backend-file"}' \
-smp 4,maxcpus=4,cores=2,threads=1,clusters=1,sockets=2 \
-numa node,memdev=mem-mem1,nodeid=0 \
-cpu 'host' \
-chardev socket,path=/var/tmp/monitor-qmpmonitor1,server=on,id=qmp_id_qmpmonitor1,wait=off \
-mon chardev=qmp_id_qmpmonitor1,mode=control \
-serial unix:'/var/tmp/serial-serial0',server=on,wait=off \
-device '{"id": "pcie-root-port-2", "port": 2, "driver": "pcie-root-port", "addr": "0x1.0x2", "bus": "pcie.0", "chassis": 3}' \
-device '{"driver": "qemu-xhci", "id": "usb1", "bus": "pcie-root-port-2", "addr": "0x0"}' \
-device '{"driver": "usb-tablet", "id": "usb-tablet1", "bus": "usb1.0", "port": "1"}' \
-device '{"id": "pcie-root-port-3", "port": 3, "driver": "pcie-root-port", "addr": "0x1.0x3", "bus": "pcie.0", "chassis": 4}' \
-device '{"id": "virtio_scsi_pci0", "driver": "virtio-scsi-pci", "bus": "pcie-root-port-3", "addr": "0x0"}' \
-blockdev '{"node-name": "file_image1", "driver": "file", "auto-read-only": true, "discard": "unmap", "aio": "threads", "filename": "/home/kvm_autotest_root/images/rhel940-aarch64-64k-virtio-scsi.qcow2", "cache": {"direct": true, "no-flush": false}}' \
-blockdev '{"node-name": "drive_image1", "driver": "qcow2", "read-only": false, "cache":
, "file": "file_image1"}' \
-device '{"driver": "scsi-hd", "id": "image1", "drive": "drive_image1", "write-cache": "on"}' \
-chardev socket,id=char_virtiofs_fs1,path=/var/tmp/avocado-vt-vm1-fs1-virtiofsd.sock \
-device '{"id": "pcie-root-port-4", "port": 4, "driver": "pcie-root-port", "addr": "0x1.0x4", "bus": "pcie.0", "chassis": 5}' \
-device '{"id": "vufs_virtiofs_fs1", "chardev": "char_virtiofs_fs1", "tag": "myfs1", "queue-size": 1024, "driver": "vhost-user-fs-pci", "bus": "pcie-root-port-4", "addr": "0x0"}' \
-chardev socket,id=char_virtiofs_fs2,path=/var/tmp/avocado-vt-vm1-fs2-virtiofsd.sock \
-device '{"id": "pcie-root-port-5", "port": 5, "driver": "pcie-root-port", "addr": "0x1.0x5", "bus": "pcie.0", "chassis": 6}' \
-device '{"id": "vufs_virtiofs_fs2", "chardev": "char_virtiofs_fs2", "tag": "myfs2", "queue-size": 1024, "driver": "vhost-user-fs-pci", "bus": "pcie-root-port-5", "addr": "0x0"}' \
-device '{"id": "pcie-root-port-6", "port": 6, "driver": "pcie-root-port", "addr": "0x1.0x6", "bus": "pcie.0", "chassis": 7}' \
-device '{"driver": "virtio-net-pci", "mac": "9a:81:4d:6e:4a:3f", "rombar": 0, "id": "idSbmzwn", "netdev": "idiLGSUL", "bus": "pcie-root-port-6", "addr": "0x0"}' \
-netdev '{"id": "idiLGSUL", "type": "tap", "vhost": true}' \
-vnc :20 \
-rtc base=utc,clock=host \
-enable-kvm
On guest:
[root@localhost home]# mkdir -p /mnt/myfs1
[root@localhost home]# mkdir -p /mnt/myfs2
[root@localhost home]# cd /home && rm -rf xfstests-dev && git clone https://git.kernel.org/pub/scm/fs/xfs/xfstests-dev.git
[root@localhost home]# yum install -y git acl attr automake bc e2fsprogs fio gawk gcc libtool lvm2 make psmisc quota sed xfsdump xfsprogs libacl-devel libattr-devel libaio-devel libuuid-devel xfsprogs-devel python3 sqlite
[root@localhost home]# cd /home/xfstests-dev/ && make -j && make install
[root@localhost xfstests-dev]# export TEST_DEV=myfs1 && export TEST_DIR=/mnt/myfs1 && export SCRATCH_DEV=myfs2 && export SCRATCH_MNT=/mnt/myfs2 && export FSTYP=virtiofs && export FSX_AVOID="-E" && echo -e 'TEST_DEV=myfs1\nTEST_DIR=/mnt/myfs1\nSCRATCH_DEV=myfs2\nSCRATCH_MNT=/mnt/myfs2\nFSTYP=virtiofs\nFSX_AVOID="-E"' > configs/localhost.config && echo -e "generic/003\ngeneric/120\ngeneric/426\ngeneric/467\ngeneric/477\ngeneric/551\ngeneric/263\ngeneric/451\n" > blacklist
[root@localhost xfstests-dev]# useradd fsgqa && useradd 123456-fsgqa && useradd fsgqa2
[root@localhost xfstests-dev]# for ((i=1; i<=1000; i++)); do ./check -virtiofs generic/423; sleep 1; done > virtiofs_test.txt
[root@localhost xfstests-dev]# cat virtiofs_test.txt | grep Failures |wc -l
436
[root@localhost xfstests-dev]# cat virtiofs_test.txt | grep Passed |wc -l
564
Expected results
pass
Other test
Without virtiofsd, boot guest, FSTYP=tmpfs:
I ran it 1000 times without hitting this issue.
[root@localhost xfstests-dev]# export TEST_DEV=myfs1 && export TEST_DIR=/mnt/myfs1 && export SCRATCH_DEV=myfs2 && export SCRATCH_MNT=/mnt/myfs2 && export FSTYP=tmpfs && export FSX_AVOID="-E" && echo -e 'TEST_DEV=myfs1\nTEST_DIR=/mnt/myfs1\nSCRATCH_DEV=myfs2\nSCRATCH_MNT=/mnt/myfs2\nFSTYP=tmpfs\nFSX_AVOID="-E"' > configs/localhost.config
[root@localhost xfstests-dev]# for ((i=1; i<=1000; i++)); do ./check -virtiofs generic/423; sleep 1; done > tmpfs.txt
[root@localhost xfstests-dev]# cat tmpfs.txt | grep Passed |wc -l
1000
[root@localhost xfstests-dev]# cat tmpfs.txt | grep Failed |wc -l
0