Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fio ci buildomat #690

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
99 changes: 99 additions & 0 deletions .github/buildomat/jobs/test-perf-fio.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
#!/bin/bash
#:
#: name = "test-perf-fio"
#: variety = "basic"
#: target = "lab"
#: rust_toolchain = "1.66"
#: output_rules = [
#: "/tmp/test_perf_fio.txt",
#: "%/tmp/debug/*.txt",
#: ]
#: skip_clone = true

# it would be nice to re-use the binaries from rbuild. to do that we need a way
# to tell the fio rig to use those binaries instead of building its own.

set -o errexit
set -o pipefail
set -o xtrace

banner setup
pfexec plimit -n 9123456 $$

echo "Setup debug logging"
mkdir /tmp/debug
psrinfo -v > /tmp/debug/psrinfo.txt
df -h > /tmp/debug/df.txt
prstat -d d -mLc 1 > /tmp/debug/prstat.txt 2>&1 &
iostat -T d -xn 1 > /tmp/debug/iostat.txt 2>&1 &
mpstat -T d 1 > /tmp/debug/mpstat.txt 2>&1 &
vmstat -T d -p 1 < /dev/null > /tmp/debug/paging.txt 2>&1 &

echo "Clone fio rig"
# maybe this should clone a specific hash?
git clone https://github.com/oxidecomputer/crucible-fio-rig.git
cd crucible-fio-rig

echo "Build fio rig"
cargo build --release

echo "Add fio job"

printf '%s' '
[global]
iodepth=25
ioengine=aio
time_based
runtime=120
numjobs=1
direct=1
stonewall=1

[randread-4K]
bs=4K
rw=randread

[randread-16K]
bs=16K
rw=randread

[randread-4M]
bs=4M
rw=randread

[randwrite-4K]
bs=4K
rw=randwrite

[randwrite-16K]
bs=16K
rw=randwrite

[randwrite-4M]
bs=4M
rw=randwrite

[randwr-4K]
bs=4K
rw=randrw

[randrw-16K]
bs=16K
rw=randrw

[randrw-4M]
bs=4M
rw=randrw
' > iops.fio

banner start
pfexec ./target/release/run_crucible_fio_test \
--crucible-commit HEAD \
--propolis-commit 28be85642e85afd1f47be861f920458beb3514f0 \
--output-file /tmp/test_perf_fio.txt \
./iops.fio

echo "$? was our result"
echo "Test finished"
sleep 5
ps -ef