guoqingzhu wrote:
> Hi, can anyone help tell me about this?
> I want to test my raw disk IO performance using 'dd' or other tools like 
> vdbench. But I don't know which device file should be correct, or both OK. 
> What about the difference between these two file when I do dd to them? 
> In my opinion I think when using /dev/rdsk/xxx, read/write requests are 
> directly sent to device driver. Otherwise when using /dev/dsk/xxx, read/write 
> requests will be processed first by high level file system interface(such as 
> vfs) then sent to device driver. So the /dev/rdsk/xxx is more suitable to 
> test raw disk IO performance. Is this thought correct?
> Thanks
> Guoqing
>   

Your conclusion is correct: you should use "character special" (aka 
"raw") devices (e.g. /dev/rdsk/*) to benchmark raw disk I/O performance.

The term "character special" is something of a historical anomaly when 
talking about raw disk devices, because these devices require I/O to be 
block aligned.

The "block special" devices (e.g. /dev/dsk/*) use mapped I/O interfaces 
as used by filesystems such as UFS (but not ZFS). As such, they use the 
system's page cache, so reads may be cached and writes will be 
asynchronous (unless synchronous writes are explicitly requested).

However, both "character special" and "block special" devices are 
implemented using a virtual filesystem called "specfs" (in Solaris, the 
term "filesystem" is used to cover many things other than the likes of 
UFS, TMPFS, PCFS and ZFS).

On the issue of buffering, I am quite often invited to comment on 
benchmarks and their results. I was recently shown sum stats from a test 
called "iozone". The results showed a sustained read performance in 
excess of 2GB/sec. However, when I asked about the storage configuration 
I was told that the storage was connected via two 4Gb/sec HBAs. The 
customer had not noticed that two 4Gb/sec HBAs are incapable of 
delivering 2GB/sec!

I am not a great fan of dd for serious I/O benchmarking (although it 
does have its uses). You might like to check out Filebench, available 
via the OpenSolaris website.

Hope this helps,

Phil

p.s. Merry Christmas from the UK!
_______________________________________________
perf-discuss mailing list
perf-discuss@opensolaris.org

Reply via email to