-
Notifications
You must be signed in to change notification settings - Fork 263
Description
We tested host managed SMR drives using the FIO utility. When testing 2 drives at the same time, the file system switches to read-only mode.
Please note that we could reproduce this error ONLY with a minimum of two drives. For one HDD only we could not reproduce it.
We used the script:
bs=64m
jobs=16
rw="read"
size=50G
mkdir -p /root/fio_infinite_testing_BTRFS
for disk in {a..b}; do
dd if=/dev/zero of=/dev/sd${disk} bs=1 count=1000000
mkfs.btrfs /dev/sd${disk} -d single -m single
mkdir -p /mnt/sd${disk}
mount -t btrfs /dev/sd${disk} /mnt/sd${disk}
done
for disk in {a..b}; do
echo 3 >/proc/sys/vm/drop_caches
fio --directory /mnt/sd${disk} --name fio.md_${disk}.${size}.test.file --rw ${rw} -bs ${bs} --size ${size} --numjobs ${jobs} --time_based --ramp_time 5 --runtime 480 |& tee /root/fio_infinite_testing_BTRFS/sd${disk}_${size}_${bs}_${r
w}_${jobs}_${dir}.fio.log &
echo 3 >/proc/sys/vm/drop_caches
done
wait
mount | grep /dev/sd
/dev/sda on /mnt/sda type btrfs (ro,relatime,seclabel,nospace_cache,subvolid=5,subvol=/)
/dev/sdb on /mnt/sdb type btrfs (rw,relatime,seclabel,nospace_cache,subvolid=5,subvol=/)
FIO output:
fio: pid=0, err=30/file:filesetup.c:150, func=unlink, error=Read-only file system
uname -a
Linux fs 5.14.10-300.fc35.x86_64 #1 SMP Thu Oct 7 20:48:44 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
btrfs --version
btrfs-progs v5.14.1
btrfs fi show
Label: none uuid: 132f3ec1-5ff3-4c7c-bf50-da53378c8bde
Total devices 1 FS bytes used 650.76GiB
devid 1 size 18.19TiB used 652.50GiB path /dev/sda
Label: none uuid: aca81f46-0c4c-4a1f-a47e-5058953ac790
Total devices 1 FS bytes used 800.94GiB
devid 1 size 18.19TiB used 802.25GiB path /dev/sdb
btrfs fi df /mnt/sda
Data, single: total=651.00GiB, used=650.00GiB
System, single: total=256.00MiB, used=288.00KiB
Metadata, single: total=1.25GiB, used=774.00MiB
GlobalReserve, single: total=512.00MiB, used=0.00B
btrfs fi df /mnt/sdb
Data, single: total=800.75GiB, used=800.00GiB
System, single: total=256.00MiB, used=352.00KiB
Metadata, single: total=1.25GiB, used=962.27MiB
GlobalReserve, single: total=512.00MiB, used=0.00B
Attached is the output of dmesg, smartctl and fio.
Tests were conducted on Fedora Release 35 and Fedora Release 34.
Please advise.
sda_50G_64m_read_16_.fio.log
smartctl_sdb.log
smartctl_sda.log
dmesg.log
sdb_50G_64m_read_16_.fio.log