Monitoring CPU usage
Posted in 2005
Topics: Server Administration, Versions, Editions & End-of-Life
Dear All,
I am using IDS 7.3 on RS-6000 p-Series with AIX. I have two hardware
processors in my server machine, but in onconfig file I found :
MULTIPROCESSOR 0 # 0 for single-processor, 1 for multi-processor
NUMCPUVPS 1 # Number of user (cpu) vps
SINGLE_CPU_VP 0 # If non-zero, limit number of cpu vps to one
NOAGE 0 # Process aging
AFF_SPROC 0 # Affinity start processor
AFF_NPROCS 0 # Affinity number of processors
Before changing it to 'MULTIPROCESSOR 1' I want to confirm CPU utilization.
As I will enable MULTIPROCESSOR, I will add a CPU VP as well. To make sure
that IDS really need another CPU. I execute following command :
onstat -g glo
It gave following figures:
Informix Dynamic Server Version 7.31.FD3 -- On-Line -- Up 33 days
00:52:02 -
- 199728 Kbytes
MT global info:
sessions threads vps lngspins
71 92 16 0
sched calls thread switches yield 0 yield n yield forever
total: 3195336250 456925131 2805835830 42590908 145700814
per sec: 107 75 32 6 5
Virtual processor summary:
class vps usercpu syscpu total
cpu 1 97045.63 11157.28 108202.91
aio 10 583.66 1578.32 2161.98
lio 1 28.91 65.36 94.27
pio 1 146.55 650.22 796.77
adm 1 83.34 109.54 192.88
soc 1 1972.14 11626.22 13598.36
msc 1 43.17 13.06 56.23
total 16 99903.40 25200.00 125103.40
Individual virtual processors:
vp pid class usercpu syscpu total
1 16598 cpu 97045.63 11157.28 108202.91
2 11030 adm 83.34 109.54 192.88
3 17052 lio 28.91 65.36 94.27
4 16124 pio 146.55 650.22 796.77
5 17304 aio 133.37 373.77 507.14
6 18068 msc 43.17 13.06 56.23
7 17810 aio 103.90 328.03 431.93
8 17552 soc 1972.14 11626.22 13598.36
9 13338 aio 87.13 258.06 345.19
10 18326 aio 66.52 206.95 273.47
11 10192 aio 50.65 127.29 177.94
12 9682 aio 39.64 83.24 122.88
13 15342 aio 29.70 58.53 88.23
14 10510 aio 24.87 50.06 74.93
15 13898 aio 24.36 47.03 71.39
16 16184 aio 23.52 45.36 68.88
tot 99903.40 25200.00 125103.40
When I execute the same command after 8 minutes, it showed:
Informix Dynamic Server Version 7.31.FD3 -- On-Line -- Up 33 days
01:00:22 -
- 199728 Kbytes
MT global info:
sessions threads vps lngspins
71 92 16 0
sched calls thread switches yield 0 yield n yield forever
total: 3207093453 456990509 2817528512 42592314 145728029
per sec: 197366 487 196880 6 191
Virtual processor summary:
class vps usercpu syscpu total
cpu 1 97093.07 11158.27 108251.34
aio 10 584.38 1579.73 2164.11
lio 1 28.92 65.38 94.30
pio 1 146.59 650.35 796.94
adm 1 83.36 109.55 192.91
soc 1 1972.32 11627.18 13599.50
msc 1 43.19 13.06 56.25
total 16 99951.83 25203.52 125155.35
Individual virtual processors:
vp pid class usercpu syscpu total
1 16598 cpu 97093.07 11158.27 108251.34
2 11030 adm 83.36 109.55 192.91
3 17052 lio 28.92 65.38 94.30
4 16124 pio 146.59 650.35 796.94
5 17304 aio 133.51 373.95 507.46
6 18068 msc 43.19 13.06 56.25
7 17810 aio 104.02 328.32 432.34
8 17552 soc 1972.32 11627.18 13599.50
9 13338 aio 87.27 258.30 345.57
10 18326 aio 66.62 207.15 273.77
11 10192 aio 50.74 127.43 178.17
12 9682 aio 39.71 83.36 123.07
13 15342 aio 29.74 58.57 88.31
14 10510 aio 24.87 50.14 75.01
15 13898 aio 24.38 47.11 71.49
16 16184 aio 23.52 45.40 68.92
tot 99951.83 25203.52 125155.35
In a book, from where I found this command, it was written "IF THE
ACCUMULATED USERCPU AND SYSCPU TIMES, TAKEN TOGETHER, APPROACH 100 PERCENT
OF THE ACTUAL ELAPSED TIME FOR THE PERIOD OF THE TEST, ADD ANOTHER CPU
VIRTUAL PROCESSOR IF YOU HAVE A CPU AVAILABLE TO RUN IT." I could not
understand, how will I get the percentage from this and how to read this
command's result?
If anybody knows any other way to monitor/check CPU utilization, please
reply.
Thanks in advance.
Regards,
Navaid Arif
Software Operations Executive,
ORIX Network,
111-767-657 Ext: 223
Hi,
I would change the advice from your book a little and use the "Virtual
processor summary" times for class cpu:
time cpu-time
-------------------------
00:52:02 108202.91
01:00:22 108251.34
-------------------------
diff: 500 secs 48.43 secs
Your cpu vp uses 48.43 cpu secs out of 500 secs = 9.68%. (If you do this
calculation with n cpu vps instead of 1 devide the resulting % value by n.)
This is far below 100% and there is no need to add a second cpu vp. But
if you do, it probably wouldn't hurt either.
If you want to keep your single cpu vp, you can set "SINGLE_CPU_VP 1".
It saves some internal latching but forbids adding cpu vps dynamically.
Regards
Michael
Navaid Arif wrote:
> Dear All,
> I am using IDS 7.3 on RS-6000 p-Series with AIX. I have two hardware
> processors in my server machine, but in onconfig file I found :
>
> MULTIPROCESSOR 0 # 0 for single-processor, 1 for multi-processor
> NUMCPUVPS 1 # Number of user (cpu) vps
> SINGLE_CPU_VP 0 # If non-zero, limit number of cpu vps to one
> NOAGE 0 # Process aging
> AFF_SPROC 0 # Affinity start processor
> AFF_NPROCS 0 # Affinity number of processors>
>
> Before changing it to 'MULTIPROCESSOR 1' I want to confirm CPU utilization.
> As I will enable MULTIPROCESSOR, I will add a CPU VP as well. To make sure
> that IDS really need another CPU. I execute following command :
>
> onstat -g glo>
> It gave following figures:
>
>
> Informix Dynamic Server Version 7.31.FD3 -- On-Line -- Up 33 days
> 00:52:02 -
> - 199728 Kbytes
>
> MT global info:
> sessions threads vps lngspins
> 71 92 16 0
>
> sched calls thread switches yield 0 yield n yield forever
> total: 3195336250 456925131 2805835830 42590908 145700814
> per sec: 107 75 32 6 5
>
> Virtual processor summary:
> class vps usercpu syscpu total
> cpu 1 97045.63 11157.28 108202.91
> aio 10 583.66 1578.32 2161.98
> lio 1 28.91 65.36 94.27
> pio 1 146.55 650.22 796.77
> adm 1 83.34 109.54 192.88
> soc 1 1972.14 11626.22 13598.36
> msc 1 43.17 13.06 56.23
> total 16 99903.40 25200.00 125103.40
>
> Individual virtual processors:
> vp pid class usercpu syscpu total
> 1 16598 cpu 97045.63 11157.28 108202.91
> 2 11030 adm 83.34 109.54 192.88
> 3 17052 lio 28.91 65.36 94.27
> 4 16124 pio 146.55 650.22 796.77
> 5 17304 aio 133.37 373.77 507.14
> 6 18068 msc 43.17 13.06 56.23
> 7 17810 aio 103.90 328.03 431.93
> 8 17552 soc 1972.14 11626.22 13598.36
> 9 13338 aio 87.13 258.06 345.19
> 10 18326 aio 66.52 206.95 273.47
> 11 10192 aio 50.65 127.29 177.94
> 12 9682 aio 39.64 83.24 122.88
> 13 15342 aio 29.70 58.53 88.23
> 14 10510 aio 24.87 50.06 74.93
> 15 13898 aio 24.36 47.03 71.39
> 16 16184 aio 23.52 45.36 68.88
> tot 99903.40 25200.00 125103.40
>
>
> When I execute the same command after 8 minutes, it showed:
>
> Informix Dynamic Server Version 7.31.FD3 -- On-Line -- Up 33 days
> 01:00:22 -
> - 199728 Kbytes
>
> MT global info:
> sessions threads vps lngspins
> 71 92 16 0
>
> sched calls thread switches yield 0 yield n yield forever
> total: 3207093453 456990509 2817528512 42592314 145728029
> per sec: 197366 487 196880 6 191
>
> Virtual processor summary:
> class vps usercpu syscpu total
> cpu 1 97093.07 11158.27 108251.34
> aio 10 584.38 1579.73 2164.11
> lio 1 28.92 65.38 94.30
> pio 1 146.59 650.35 796.94
> adm 1 83.36 109.55 192.91
> soc 1 1972.32 11627.18 13599.50
> msc 1 43.19 13.06 56.25
> total 16 99951.83 25203.52 125155.35
>
> Individual virtual processors:
> vp pid class usercpu syscpu total
> 1 16598 cpu 97093.07 11158.27 108251.34
> 2 11030 adm 83.36 109.55 192.91
> 3 17052 lio 28.92 65.38 94.30
> 4 16124 pio 146.59 650.35 796.94
> 5 17304 aio 133.51 373.95 507.46
> 6 18068 msc 43.19 13.06 56.25
> 7 17810 aio 104.02 328.32 432.34
> 8 17552 soc 1972.32 11627.18 13599.50
> 9 13338 aio 87.27 258.30 345.57
> 10 18326 aio 66.62 207.15 273.77
> 11 10192 aio 50.74 127.43 178.17
> 12 9682 aio 39.71 83.36 123.07
> 13 15342 aio 29.74 58.57 88.31
> 14 10510 aio 24.87 50.14 75.01
> 15 13898 aio 24.38 47.11 71.49
> 16 16184 aio 23.52 45.40 68.92
> tot 99951.83 25203.52 125155.35
>
>
> In a book, from where I found this command, it was written "IF THE
> ACCUMULATED USERCPU AND SYSCPU TIMES, TAKEN TOGETHER, APPROACH 100 PERCENT
> OF THE ACTUAL ELAPSED TIME FOR THE PERIOD OF THE TEST, ADD ANOTHER CPU
> VIRTUAL PROCESSOR IF YOU HAVE A CPU AVAILABLE TO RUN IT." I could not
> understand, how will I get the percentage from this and how to read this
> command's result?
> If anybody knows any other way to monitor/check CPU utilization, please
> reply.
>
> Thanks in advance.
>
>
>
> Regards,
>
> Navaid Arif
> Software Operations Executive,
> ORIX Network,
> 111-767-657 Ext: 223
>
>
>
--0__=09BBE539DFC69E448f9e8a93df938690918c09BBE539DFC69E44
Content-type: multipart/alternative;
Boundary="1__=09BBE539DFC69E448f9e8a93df938690918c09BBE539DFC69E44"
--1__=09BBE539DFC69E448f9e8a93df938690918c09BBE539DFC69E44
Content-type: text/plain; charset=US-ASCII
Content-transfer-encoding: quoted-printable
I read Michael's response and think that it is valid information.
However, I get confused with numbers. ;-) So my thumb-of-rule is more
like...
If [there tend to be threads in the ready queue (onstat -g rea)]
THEN
if [I have additional processors]
THEN
Add a CPUVP
ELSE
Buy an additional processor
Add a CPUVP
ENDIF
ENDIF
onstat -g rea tends to show several threads in the ready queuethen add another CPUVP
=
"Navaid Arif" =
<navaidarif@cyber =
access.com.pk> =
To
Sent by: ids@iiug.org =
forum.subscriber@ =
cc
iiug.org =
Subj=
ect
Monitoring CPU usage [4268] =
02/16/2005 04:00 =
AM =
=
=
=
=
Dear All,
I am using IDS 7.3 on RS-6000 p-Series with AIX. I have two hardwar=
e
processors in my server machine, but in onconfig file I found :
MULTIPROCESSOR 0 # 0 for single-processor, 1 for multi-processor
NUMCPUVPS 1 # Number of user (cpu) vps
SINGLE_CPU_VP 0 # If non-zero, limit number of cpu vps to one
NOAGE 0 # Process aging
AFF_SPROC 0 # Affinity start processor
AFF_NPROCS 0 # Affinity number of processors
Before changing it to 'MULTIPROCESSOR 1' I want to confirm CPU utilizat=
ion.
As I will enable MULTIPROCESSOR, I will add a CPU VP as well. To make s=
ure
that IDS really need another CPU. I execute following command :
onstat -g glo
It gave following figures:
Informix Dynamic Server Version 7.31.FD3 -- On-Line -- Up 33 days
00:52:02 -
- 199728 Kbytes
MT global info:
sessions threads vps lngspins
71 92 16 0
sched calls thread switches yield 0 yield n yield for=
ever
total: 3195336250 456925131 2805835830 42590908 14570081=
4
per sec: 107 75 32 6 5
Virtual processor summary:
class vps usercpu syscpu total
cpu 1 97045.63 11157.28 108202.91
aio 10 583.66 1578.32 2161.98
lio 1 28.91 65.36 94.27
pio 1 146.55 650.22 796.77
adm 1 83.34 109.54 192.88
soc 1 1972.14 11626.22 13598.36
msc 1 43.17 13.06 56.23
total 16 99903.40 25200.00 125103.40
Individual virtual processors:
vp pid class usercpu syscpu total
1 16598 cpu 97045.63 11157.28 108202.91
2 11030 adm 83.34 109.54 192.88
3 17052 lio 28.91 65.36 94.27
4 16124 pio 146.55 650.22 796.77
5 17304 aio 133.37 373.77 507.14
6 18068 msc 43.17 13.06 56.23
7 17810 aio 103.90 328.03 431.93
8 17552 soc 1972.14 11626.22 13598.36
9 13338 aio 87.13 258.06 345.19
10 18326 aio 66.52 206.95 273.47
11 10192 aio 50.65 127.29 177.94
12 9682 aio 39.64 83.24 122.88
13 15342 aio 29.70 58.53 88.23
14 10510 aio 24.87 50.06 74.93
15 13898 aio 24.36 47.03 71.39
16 16184 aio 23.52 45.36 68.88
tot 99903.40 25200.00 125103.40
When I execute the same command after 8 minutes, it showed:
Informix Dynamic Server Version 7.31.FD3 -- On-Line -- Up 33 days
01:00:22 -
- 199728 Kbytes
MT global info:
sessions threads vps lngspins
71 92 16 0
sched calls thread switches yield 0 yield n yield for=
ever
total: 3207093453 456990509 2817528512 42592314 14572802=
9
per sec: 197366 487 196880 6 191
Virtual processor summary:
class vps usercpu syscpu total
cpu 1 97093.07 11158.27 108251.34
aio 10 584.38 1579.73 2164.11
lio 1 28.92 65.38 94.30
pio 1 146.59 650.35 796.94
adm 1 83.36 109.55 192.91
soc 1 1972.32 11627.18 13599.50
msc 1 43.19 13.06 56.25
total 16 99951.83 25203.52 125155.35
Individual virtual processors:
vp pid class usercpu syscpu total
1 16598 cpu 97093.07 11158.27 108251.34
2 11030 adm 83.36 109.55 192.91
3 17052 lio 28.92 65.38 94.30
4 16124 pio 146.59 650.35 796.94
5 17304 aio 133.51 373.95 507.46
6 18068 msc 43.19 13.06 56.25
7 17810 aio 104.02 328.32 432.34
8 17552 soc 1972.32 11627.18 13599.50
9 13338 aio 87.27 258.30 345.57
10 18326 aio 66.62 207.15 273.77
11 10192 aio 50.74 127.43 178.17
12 9682 aio 39.71 83.36 123.07
13 15342 aio 29.74 58.57 88.31
14 10510 aio 24.87 50.14 75.01
15 13898 aio 24.38 47.11 71.49
16 16184 aio 23.52 45.40 68.92
tot 99951.83 25203.52 125155.35
In a book, from where I found this command, it was written "IF THE
ACCUMULATED USERCPU AND SYSCPU TIMES, TAKEN TOGETHER, APPROACH 100 PERC=
ENT
OF THE ACTUAL ELAPSED TIME FOR THE PERIOD OF THE TEST, ADD ANOTHER CPU
VIRTUAL PROCESSOR IF YOU HAVE A CPU AVAILABLE TO RUN IT." I could not
understand, how will I get the percentage from this and how to read thi=
s
command's result?
If anybody knows any other way to monitor/check CPU utilization, please=
reply.
Thanks in advance.
Regards,
Navaid Arif
Software Operations Executive,
ORIX Network,
111-767-657 Ext: 223
=
--1__=09BBE539DFC69E448f9e8a93df938690918c09BBE539DFC69E44
Content-type: text/html; charset=US-ASCII
Content-Disposition: inline
Content-transfer-encoding: quoted-printable
<html><body>
<p>I read Michael's response and think that it is valid information.<br=
>
<br>
However, I get confused with numbers. ;-) So my thumb-of-rule is more =
like...<br>
<br>
If [there tend to be threads in the ready queue (onstat -g rea)]<br>
THEN <br>
if [I have additional processors]<br>
THEN <br>
Add a CPUVP<br>
ELSE<br>
Buy an additional processor<br>
Add a CPUVP<br>
ENDIF<br>
ENDIF<br>
<br>
<br>
onstat -g rea tends to show several threads in the ready queue<br>then add another CPUVP<br>
<br>
<img src=3D"cid:10__=3D09BBE539DFC69E448f9e8a93df938@us.ibm.com" width=3D=
"16" height=3D"16" alt=3D"Inactive hide details for "Navaid Arif&q=
uot; <navaidarif@cyberaccess.com.pk>">"Navaid Arif" <=
;navaidarif@cyberaccess.com.pk><br>
<br>
<br>
<table width=3D"100%" border=3D"0" cellspacing=3D"0" cellpadding=3D"0">=
<tr valign=3D"top"><td style=3D"background-image:url(cid:20__=3D09BBE53=
9DFC69E448f9e8a93df938@us.ibm.com); background-repeat: no-repeat; " wid=
th=3D"40%">
<ul>
<ul>
<ul>
<ul><b><font size=3D"2">"Navaid Arif" <navaidarif@cyberacc=
ess.com.pk></font></b><font size=3D"2"> </font><br>
<font size=3D"2">Sent by: forum.subscriber@iiug.org</font>
<p><font size=3D"2">02/16/2005 04:00 AM</font></ul>
</ul>
</ul>
</ul>
</td><td width=3D"60%">
<table width=3D"100%" border=3D"0" cellspacing=3D"0" cellpadding=3D"0">=
<tr valign=3D"top"><td width=3D"1%" valign=3D"middle"><img src=3D"cid:3=
0__=3D09BBE539DFC69E448f9e8a93df938@us.ibm.com" border=3D"0" height=3D"=
1
Related threads
- Posting from the Informix-list
- Migrating from IDS 9.40.UC6 to 11.50.UC3
- Ip for a network session
- questions onstat -g