Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to get Reads per sec and writes per sec data in AIX

Status
Not open for further replies.

santhoshtauro

Programmer
Nov 27, 2004
3
US
We need to get the number of reads/sec and writes/sec data from the AIX kernal for each of the disks. We are able to get the number of io/sec for each of the disks by reading data into dkstat (dk_xfers field of this structure gives io's/sec data) from the kernal. Can anyone help me out to break this data into number of reads and writes? or how to get this data from kernal memory

 
you can either use the libperfstat and make your own program to get the fields you want or use program like netpmon, filemon or curt.
 
What about standard iostat command? It can gove detailed output on per disk, per MPIO device, or even per adapter basis in AiX 5

--Trifo
 
Thanks for the information needed.

The netpmon, filemon and curt, i think doesnot come with the minimal AIX installation. They need to be installed as additional package, so i cannot use those.

------------------------
iostat o/p
# iostat -d 2 2

Disks: % tm_act Kbps tps Kb_read Kb_wrtn
hdisk0 0.0 0.0 0.0 0 0
hdisk2 0.0 0.0 0.0 0 0
hdisk1 0.0 0.0 0.0 0 0
cd0 0.0 0.0 0.0 0 0
hdisk0 0.0 0.0 0.0 0 0
hdisk2 0.0 0.0 0.0 0 0
hdisk1 0.0 0.0 0.0 0 0
cd0 0.0 0.0 0.0 0 0

also gives the total transfers per sec. But not the reads/sec and writes/sec data.

-----------------------------------
Even libperfstat.h contains this structure which has the disk data
typedef struct { /* disk information */
char name[IDENTIFIER_LENGTH]; /* name of the disk */
char description[IDENTIFIER_LENGTH]; /* disk description (from ODM) */
char vgname[IDENTIFIER_LENGTH]; /* volume group name (from ODM) */
u_longlong_t size; /* size of the disk (in MB) */
u_longlong_t free; /* free portion of the disk (in MB)
*/
u_longlong_t bsize; /* disk block size (in bytes) */
u_longlong_t xrate; /* kbytes/sec xfer rate capability
*/
u_longlong_t xfers; /* number of transfers to/from disk
*/
u_longlong_t wblks; /* number of blocks written to disk
*/
u_longlong_t rblks; /* number of blocks read from disk
*/
u_longlong_t qdepth; /* queue depth */
u_longlong_t time; /* amount of time disk is active */
char adapter[IDENTIFIER_LENGTH]; /* disk adapter name (from ODM) */
uint paths_count; /* number of paths defined to the d
isk */
} perfstat_disk_t;

again here xfers gives the total number transfer.

-----------------------------
Can somebody provide information how to read the number reads/sec and writes/sec data for each of the devices from the kernal. It would be of great help to us.
 
Filemon gives the expected out i.e reads/sec and writes/sec for each of the physical devices. Cannot use filemon as it is an additional package that need to be separetly installed on AIX. Any other ways of getting this data from the kernal ?
 
filemon is part of bos.perf.tools that comes with aix. so what is the problem to install it???
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top