Last active
November 8, 2017 00:08
-
-
Save davidjb/8777451 to your computer and use it in GitHub Desktop.
I/O Performance tests with fio
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
#Run like this: | |
# wget -O - https://gist.githubusercontent.com/davidjb/8777451/raw/test-io.sh | sudo sh | |
# or | |
# curl https://gist.githubusercontent.com/davidjb/8777451/raw/test-io.sh | sudo sh | |
if command -v yum > /dev/null 2>&1; then | |
sudo rpm -ihv http://mirrors.kernel.org/fedora-epel/6/x86_64/epel-release-6-8.noarch.rpm | |
sudo yum install -y fio git | |
elif command -v apt-get > /dev/null 2>&1; then | |
sudo apt-get install -y fio git | |
fi | |
git clone https://gist.github.com/8777451.git test-io | |
cd test-io | |
# Run the tests | |
echo "********************SEQUENTIAL READ*********************" | |
fio test-read.fio | |
sleep 3 | |
echo "********************SEQUENTIAL WRITE********************" | |
fio test-write.fio | |
sleep 3 | |
echo "***********************RANDOM READ**********************" | |
fio test-random-read.fio | |
sleep 3 | |
echo "********************RANDOM READ/WRITE*******************" | |
fio test-random-readwrite.fio | |
sleep 3 | |
echo "*************SIMULTANEOUS RANDOM READ/WRITE*************" | |
fio test-random-io.fio | |
sleep 3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[global] | |
rw=randread | |
size=128m | |
ioengine=libaio | |
iodepth=4 | |
invalidate=1 | |
direct=1 | |
[bgwriter] | |
rw=randwrite | |
iodepth=32 | |
[queryA] | |
iodepth=1 | |
ioengine=mmap | |
direct=0 | |
thinktime=3 | |
[queryB] | |
iodepth=1 | |
ioengine=mmap | |
direct=0 | |
thinktime=5 | |
[bgupdater] | |
rw=randrw | |
iodepth=16 | |
thinktime=40 | |
size=32m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[random-read] | |
rw=randread | |
size=128m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[readwrite] | |
rw=readwrite | |
size=256m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[read] | |
rw=read | |
size=512m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[write] | |
rw=write | |
size=512m |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment