Simpler Navigation for Servers and Operating Systems - Please Update Your Bookmarks
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
If you have bookmarked forums or discussion boards in Servers and Operating Systems, we suggest you check and update them as needed.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to get CCISS disk stats

Marek Podmaka
Frequent Advisor

How to get CCISS disk stats

Hello,
is there a way to get blocks read/written per second to disk when using HP SmartArray 532 (cciss driver in kernel)?
For IDE disks, this data is for example in /proc/diskstats, but for cciss, some numbers are simply zero.

For example:
104 0 cciss/c0d0 6068090 140796 0 59423472 6910399 7410784 0 756416616 0 57831244 815849076
104 1 cciss/c0d0p1 262104 3240564 1733149 3466298
104 2 cciss/c0d0p2 9311 74488 11293 90344
3 0 hda 1222417 14770 20531014 4574328 282550 2276383 20471632 31887560 0 5363868 36461880
3 1 hda1 17678 1631178 110626 884984
3 2 hda2 10937 130738 328066 2624472

Is there a way how to get this info? Or the cciss driver does not provide it?
2 REPLIES
Ulf Zimmermann
Frequent Advisor

Re: How to get CCISS disk stats

iostat will show you stats:

iostat -d -x /dev/cciss/c0d0 1

Device: rrqm/s wrqm/s r/s w/s rsec/s wsec/s rkB/s wkB/s avgrq-sz avgqu-sz await svctm %util
cciss/c0d0 0.06 26.38 14.14 17.84 706.67 353.84 353.34 176.92 33.16 0.19 5.82 0.58 1.85

Device: rrqm/s wrqm/s r/s w/s rsec/s wsec/s rkB/s wkB/s avgrq-sz avgqu-sz await svctm %util
cciss/c0d0 0.00 0.00 0.00 3.96 0.00 31.68 0.00 15.84 8.00 0.01 3.50 1.50 0.59

Device: rrqm/s wrqm/s r/s w/s rsec/s wsec/s rkB/s wkB/s avgrq-sz avgqu-sz await svctm %util
cciss/c0d0 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00

This command will print out the stats once a second.
Marek Podmaka
Frequent Advisor

Re: How to get CCISS disk stats

Thanks for your reply, but unfortunately the "iostat" command just takes the info from the /proc/diskstats file (see manpage for the -x option). So still I don't get some of the fields (the rsec/s or rkB/s are always zero).

Device: rrqm/s wrqm/s r/s w/s rsec/s wsec/s rkB/s wkB/s avgrq-sz avgqu-sz await svctm %util
cciss/c0d0 0.46 23.54 19.28 22.59 0.00 0.00 0.00 0.00 0.00 0.56 13.36 4.44 18.60

But it is strange as in your output I see every field is non-zero. I have official kernel 2.6.16.18 and this is information about the controller and cciss driver:

cartman:~:# cat /proc/driver/cciss/cciss0
cciss0: HP Smart Array 532 Controller
Board ID: 0x40820e11
Firmware Version: 2.62
IRQ: 169
Logical drives: 2
Current Q depth: 0
Current # commands on controller: 0
Max Q depth since init: 192
Max # commands on controller since init: 305
Max SG entries since init: 31

cciss/c0d0: 72.83GB RAID 1(1+0)
cciss/c0d1: 18.20GB RAID 1(1+0)