On Fri, Aug 16, 2013 at 04:52:13PM +0100, Peter Pichler wrote:
> I am trying to measure the I/O speed programmatically from our application. 
> I've tried the naïve approach of periodically getting the file size and 
> calculating the growth like this (simplified):
> 
> speed = (H5File::getFileSize() - H5File::getFreeSpace()) / time_period;

Are you interested in the speed of your storage system, or are you
interested in how fast your application can move data?  

What you have done will measure the former, kind of.

What you really want to do is
- compute how much data application passes to or receives from  HDF5 routine
- time how long routine takes to finish

Maybe you get really fancy and include open and close time in addition
to data transfer time.

Now you've got a metric that actually relates to application behavior.  

==rob

> 
> This produces good clean results on Windows but running the same program on 
> Linux produces very "jerky" results.
> The file size jumps by about 300MB every minute or so, but the reported free 
> space is always constant (and very small, about 2 KB), resulting in the 
> reported I/O speed of 0 most of the time, jumping to over 100MB/s once a 
> minute or so.
> 
> I could understand that there may be some caching going on and the cache is 
> dumped from time to time. However running iotop on the same machine proves 
> that our application writes to the file all the time at a steady rate, 
> suggesting that the file size increase jump should be reflected as free space.
> 
> So why does getFreeSpace() keep returning a constant value?
> Is there a better way of measuring the I/O speed?

> _______________________________________________
> Hdf-forum is for HDF software users discussion.
> [email protected]
> http://mail.lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org


-- 
Rob Latham
Mathematics and Computer Science Division
Argonne National Lab, IL USA

_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://mail.lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org

Reply via email to