1753359 Members
6568 Online
108792 Solutions
New Discussion

how to generate HDD I/O?

 
SOLVED
Go to solution
mpugach
Occasional Visitor

how to generate HDD I/O?

Hello,

 

I need a tool to generate HDD workload and monitor errors.

 

The main task is to test high availability schemes with SAN switches.

 

Can anyone help me?

8 REPLIES 8
Torsten.
Acclaimed Contributor
Solution

Re: how to generate HDD I/O?

You could read with "dd" from the disk device.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Turgay Cavdar
Honored Contributor

Re: how to generate HDD I/O?

If there is a file system, you can also use prealloc command:

 

# prealloc file_name 5000000000

George_Dodds
Honored Contributor

Re: how to generate HDD I/O?

dd would do it

 

dd if=/dev/rdsk/c1t0d0 of=/dev/null bs=1024k

Steven E. Protter
Exalted Contributor

Re: how to generate HDD I/O?

Shalom,

 

I'd run a couple of dd commands varying block sizes. That will be fine for testing hd performance.

 

SEP

Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Dennis Handly
Acclaimed Contributor

Re: how to generate HDD I/O?

>I'd run a couple of dd commands varying block sizes.

 

These would be testing sequential I/O.  I suppose if you did more than one at the same time, that may be random enough?

mpugach
Occasional Visitor

Re: how to generate HDD I/O?

Thank you all. 

dd is fine.

Bill Hassell
Honored Contributor

Re: how to generate HDD I/O?

Attached is diskperf which is a wrapper for dd to make it easier to specify dd parameters. Here are the options:

 

 # diskperf

Requires MB and at least one DSF
================================

   Usage:  [ -l log ] [ -r KB ] <MB> <DSF> [ more <DSF> ]

   where: MB  = megabytes to read
          DSF = filename (CTD, persistent with partial/full path)

   optional:
         -l log file (fullpath or just device name)
         -r KB (min 1, max 16384)

   Will run a dd read test on the device
   and write the results to the logfile.

Here is a sample output:

 

# diskperf 300 c8t11d0 c2t2d0
20110723.215130 /dev/rdsk/c8t11d0 (vgbig): 300MB in 5.6 secs (300 recs @ 1024KB) = 53.5MB/sec
20110723.215138 /dev/rdsk/c2t2d0 (vg00): 300MB in 8.2 secs (300 recs @ 1024KB) = 36.5MB/sec

 

You can start multiple copies of different disks and LUNs for a load generator.



Bill Hassell, sysadmin
VK2COT
Honored Contributor

Re: how to generate HDD I/O?

Hello,

 

Other already gave you some good advice. May I add more (it is always good to have choices in your life):

 

a) Bonnie+

 

http://www.coker.com.au/bonnie++/

 

b) IOzone

 

http://www.iozone.org/

 

c) IOstone

 

http://www.acnc.com/benchmarks/iostone.zip

 

d) IObench

 

http://www.acnc.com/benchmarks/iobench.tar.Z

 

e) Bonnie

 

http://www.acnc.com/benchmarks/bonnie.tar.gz

 

f) nbench

 

http://www.tux.org/~mayer/linux/bmark.html

 

g) Diskbench

 

http://www.hp.com/go/dspp

 

h) You could even use Linux Test Project Suite (LTP) and extract various scripts that suit you for HP-UX:

 

http://ltp.sourceforge.net/

 

The LTP has over 3,000 tests.

 

i) If you want a vendor-based tool, and you run HP-UX 11.23 or newer (11.31), then HP offers it as long as you sign an ETD Test Tool Non Disclosure Agreement. It is called Meatgrinder.

j) Also:

 

http://www.opensourcetesting.org/performance.php

 

You could do it through many ways, including primitive but efficient scripts.

 

Finally, a not-so-known tool that is very nice. Some time ago, I was involved in investigating the installation of

GPLv2 workload generator to HP-UX. The source code is here:

 

http://weather.ou.edu/~apw/projects/stress/

 

It is designed for POSIX systems, and mostly used on Linux distributions, OpenBSD, and FreeBSD.

 

Here is how it worked on HP-UX 11.31...

 

1. Install the following depots (for example, go to Porting and Archiving Centre for HP-UX):

 

http://hpux.connect.org.uk/

 

gettext-0.18.1.1-ia64-11.31.depot

libiconv-1.13.1-ia64-11.31.depot

make-3.82-ia64-11.31.depot

texinfo-4.13a-ia64-11.31.depot

zlib-1.2.5-ia64-11.31.depot

gcc-4.2.3-ia64-11.31.depot

 

2. Set up environment variable CC (I use Posix Shell on my machine, which is HP-UX standard):

 

# CC=/usr/local/bin/gcc; export CC

 

No need to change the PATH variable.

 

3. Run the compilation:

 

# cd /var/tmp/stress-1.0.4

# ./configure

 

In any case, you have plenty of choices.

 

Regards,

 

VK2COT

VK2COT - Dusan Baljevic