[ILUG] I/O benchmarking tools
P at draigBrady.com
Wed Feb 16 11:18:38 GMT 2011
On 16/02/11 10:18, stephen mulcahy wrote:
> On 15/02/11 14:12, Conor Wynne wrote:
>> What tools do you guys recommend for doing some I/O benchmarking.
>> I've been using iozone with 20 threads, but the figures I'm getting back
>> are just mental. Like more than the array should be capable of....
>> The is the comand line I've been testing with:
>> /opt/iozone/bin/iozone -R -l 20 -u 20 -r 4k -s
>> 100m -F file1 file2 file3 file4 file5 file6 file7 file8 file9 file10
>> file11 file12 file13 file14 file15 file16 file17 file18 file19 file20
>> |tee -a /root/Test_20-threads_Iozone.txt
> iozone has a pretty good reputation.
> I like bonnie++ because it has a simpler interface but afaik iozone is
> more accurate and more powerful.
> if you're doing any filesystem testing, the first thing you need to be
> careful of is testing the performance of your os caches rather than the
> actual filesystem. So to be sure to be sure, you should use a test-file
> size that is a multiple of your system's memory size (this is certainly
> the case with bonnie++ and I assume the same with iozone).
> Try that and see if it gives any improvement.
Re caching, since Linux 2.6.16 one can drop all cache with:
echo 1 > /proc/sys/vm/drop_caches # free pagecache
echo 2 > /proc/sys/vm/drop_caches # free dentries and inodes
echo 3 > /proc/sys/vm/drop_caches # free all of the above
Note, "dirty" stuff is not freed, so one should run `sync` first.
Coincidentally I was adding a per file cache drop to `dd` last night.
It will look something like:
dd if=file iflag=nocache count=0 # drop all of file from cache
dd if=file iflag=nocache skip=10 count=0 # drop end of file from cache
dd if=file iflag=nocache skip=10 count=10 # drop part of file from cache
dd if=file iflag=nocache of=copy oflag=nocache # copy just using readahead cache
I'm wondering if I need to imply fdatasync with nocache.
Also perhaps conv=stream would be a useful shortcut
(for the last example at least).
More information about the ILUG