#!/bin/sh #testfile size. At least 3 times the amount of RAM (hint: use 'mem=1G' Linux kernel boot parameter) and 10 times the amount of (cache in disk controler + cache integrated to disks) TSTFILE_SIZE='4g' #run this at least one time to create the testfile and obtain a first set of results. Read 'iozone -h' #sorting the results: #grep '4194304 ' *result|perl -e 'while (<>) { ($name,undef,undef,$r,$w)=split(); print "$name est $r read, $w write\n"; $score{$name}=($r*10)+$w;} foreach $key (sort { $score{$a} <=> $score{$b} } (keys(%score))) { print "$score{$key}\t$key\n";}'|less # ^^^^^^^ replace this your TSTFILE_SIZE expressed in bytes docat() { echo -en "$CAT":\ cat $CAT | tr --delete '\n' echo } doCATMULT() { for i in `find "$CATMULT" -type f` ; do CAT=$i docat done } echo -n Read-ahead getra:\ sudo /sbin/blockdev --getra /dev/sda echo -n Sector size getss:\ sudo /sbin/blockdev --getss /dev/sda echo -n Block size getbsz:\ sudo /sbin/blockdev --getbsz /dev/sda CATMULT=/sys/block/sda doCATMULT CATMULT=/proc/sys/vm doCATMULT CAT=/sys/block/sda/device/queue_depth docat cd /mnt/xfs echo 3 > /proc/sys/vm/drop_caches time ~/tmp/iozone3_283/src/current/iozone -f iozone.tmp -w -i2 -p -e -o -r64k -m -T -s $TSTFILE_SIZE -O -S 2048