Skip to content

Commit

Permalink
Let fio deal with the IO file removal
Browse files Browse the repository at this point in the history
Use the ` --unlink=1` parameter to remove the IO file.
  • Loading branch information
pablomh authored Jan 15, 2024
1 parent 0a9f32a commit 0859cab
Showing 1 changed file with 3 additions and 12 deletions.
15 changes: 3 additions & 12 deletions storage-benchmark
Original file line number Diff line number Diff line change
Expand Up @@ -38,22 +38,13 @@ testlocation(){
echo ""
echo "************* Running READ test via fio:"
echo ""
fio --name=read-test --rw=read --size="$FILEGB"G --directory=$TESTDIRECTORY
echo ""
echo "************* Removing test files."
rm -f "$TESTDIRECTORY"/*
fio --name=read-test --rw=read --size="$FILEGB"G --directory=$TESTDIRECTORY --unlink=1
echo ""
echo "************* Running WRITE test via fio:"
fio --name=write-test --rw=write --size="$FILEGB"G --directory=$TESTDIRECTORY
echo ""
echo "************* Removing test files."
rm -f "$TESTDIRECTORY"/*
fio --name=write-test --rw=write --size="$FILEGB"G --directory=$TESTDIRECTORY --unlink=1
echo ""
echo "************* Running Random READ/WRITE test via fio:"
fio --name=randrw-test --rw=randrw --size="$FILEGB"G --directory=$TESTDIRECTORY --rwmixread=80
echo ""
echo "************* Removing test files."
rm -f "$TESTDIRECTORY"/*
fio --name=randrw-test --rw=randrw --size="$FILEGB"G --directory=$TESTDIRECTORY --rwmixread=80 --unlink=1
echo ""
echo "Test complete! There is still a directory located : $TESTDIRECTORY that you"
echo "will need to remove to run this test again."
Expand Down

0 comments on commit 0859cab

Please sign in to comment.