OpenVZ Forum


Home » Mailing lists » Users » Measuring and Adjusting CPU utilization
Measuring and Adjusting CPU utilization [message #3602] Tue, 06 June 2006 18:03 Go to previous message
Pradeep Padala is currently offline  Pradeep Padala
Messages: 18
Registered: June 2006
Junior Member
Hi,

I am trying to measure the CPU utlilization of the VZ containers, and change
the cpu share dynamically. I have poured over most of the documentation, and
looked at the code as well, and it seems like there's no utility that can
directly show the current CPU utilization of a container (some thing like
30% of CPU). A search on the user list got me a message, where someone
suggested using loadavg. However, It seems like the loadavg is not showing
the proper utilization (or showing the total CPU utilization). This is what
I am doing.

I setup a container with 1000 units limit (total CPU units: ~10000). I wrote
a small do {; }while(1); loop and ran it in the container, now I do cat
/proc/loadavg in both the container and on the host node. Since, the
container is only using 1000 units, I should see something like 100% loadavg
in the container, and 10% loadavg in the hostnode. But, I see 100% at both
places. Am I doing something wrong? How do I get the current cpu utilization
of a container?

Thanks,
--
Pradeep Padala
http://ppadala.blogspot.com
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Noob questions
Next Topic: Live migration and SAN
Goto Forum:
  


Current Time: Sat Apr 27 19:02:06 GMT 2024

Total time taken to generate the page: 0.02473 seconds