-
Notifications
You must be signed in to change notification settings - Fork 99
/
Copy pathconfig-io-fio-randread-sync-heavywrite
71 lines (63 loc) · 1.71 KB
/
config-io-fio-randread-sync-heavywrite
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
###
### Measure latency of reads in presence of heavy sync writes
###
### Run 4 writer threads doing 1m of random writes & fsync
### Run 1 reader thread doing random 4k reads from 20 different files
###
### This fio workload simulates application startup by reading randomly 4k
### chunks from 20 different files. We also run 4 writer threads doing random
### 4k writes and calling fdatasync() once in a while. This is to see how
### much reads are starved by a presence of heavy independent synchronous
### writes.
###
export MMTESTS="fio"
# Test disk to setup (optional)
#export TESTDISK_RAID_DEVICES=
#export TESTDISK_RAID_MD_DEVICE=/dev/md0
#export TESTDISK_RAID_OFFSET=63
#export TESTDISK_RAID_SIZE=250019532
#export TESTDISK_RAID_TYPE=raid0
#export TESTDISK_PARTITION=/dev/sda6
#export TESTDISK_FILESYSTEM=xfs
#export TESTDISK_MKFS_PARAM="-f -d agcount=8"
#export TESTDISK_MOUNT_ARGS=inode64,delaylog,logbsize=262144,nobarrier
#export TESTDISK_NOMOUNT=false
#export FIO_TEST_TYPE=jobfile
# List of monitors
export RUN_MONITOR=yes
export MONITORS_ALWAYS=
export MONITORS_GZIP="proc-vmstat top iotop"
export MONITORS_WITH_LATENCY="vmstat iostat"
export MONITOR_UPDATE_FREQUENCY=10
# fio
JOBFILE="/tmp/fio-jobfile-$$"
export FIO_CMD_OPTIONS="$JOBFILE"
cat >$JOBFILE <<END
[global]
direct=0
ioengine=sync
invalidate=1
blocksize=4096
log_avg_msec=10
group_reporting=1
[writer]
nrfiles=1
filesize=1g
fdatasync=256
readwrite=randwrite
numjobs=4
runtime=300
time_based
exitall
exit_what=all
[reader]
# Simulate random reading from different files, switching to different file
# after 16 ios. This somewhat simulates application startup.
new_group
filesize=100m
nrfiles=20
file_service_type=random:16
readwrite=randread
exitall
exit_what=all
END