#!/bin/bash set -e set -x modprobe brd rd_nr=1 rd_size=20000000 max_part=1 bcachefs format /dev/ram0 mount -t bcachefs /dev/ram0 /mnt START=`date +%s` while [ $(( $(date +%s) - 3600 )) -lt $START ]; do OPTIONS="--filesize=1G --numjobs=16 --iodepth=256 --ioengine=libaio \ --eta=never --ramp_time=2s --runtime=1m --direct=1 --verify=0 \ --randrepeat=0 --group_reporting --directory=/mnt --unlink=1" fio --name=write --blocksize=1m --readwrite=write $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt fio --name=randwrite --blocksize=4k --readwrite=randwrite $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt fio --name=read --blocksize=1m --readwrite=read $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt fio --name=randread --blocksize=4k --readwrite=randread $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt OPTIONS="--filesize=16G --numjobs=1 --iodepth=1 --ioengine=libaio \ --eta=never --ramp_time=2s --runtime=1m --direct=1 --verify=0 \ --randrepeat=0 --group_reporting --directory=/mnt --unlink=1" fio --name=write --blocksize=1m --readwrite=write $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt fio --name=randwrite --blocksize=4k --readwrite=randwrite $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt fio --name=read --blocksize=1m --readwrite=read $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt fio --name=randread --blocksize=4k --readwrite=randread $OPTIONS ls -alh /mnt; df -h /mnt; bcachefs fs usage /mnt done umount /mnt rmmod brd