lveinfo and lvestats2
Forum
  1. Forums
  2. CloudLinux and Control Panels
  3. CloudLinux and cPanel
  1. Kevin Brooks
  2. Monday, 19 December 2016
  3.  Subscribe via email
Understanding the granularity of uCPU
Rate this post:
  1. 19.12.2016 19:12:50
  2. # 1
Kevin Brooks Accepted Answer
Posts: 14
Joined: 10.08.2010
0
Votes
Undo
The new data available fr om lvestats2 is excellent. Thank you. 

The data allows me to better analyze the over-all resource utilization for the server and for a specific site. For example, to find any faults over the last 24 hours I might run:
# lveinfo --period 24h --by-fault any --show-columns id from to iopsf iof cpuf epf pmemf mcpu ucpu uep upmem
(this would make a nice format for the summary email, the current format is too long)

+----+-----------+-----------+-----+---+----+---+-----+----+----+----+-----+
| ID |    From   |     To    |IOPSf|IOf|CPUf|EPf|PMemF|mCPU|uCPU|uEP |uPMem|
+----+-----------+-----------+-----+---+----+---+-----+----+----+----+-----+
|1094|12-18 16:15|12-19 16:15|0    |1  |0   |0  |0    |30  |0.0%|0.0%|0.0% |
|1095|12-18 16:15|12-19 16:15|0    |0  |1   |0  |0    |100 |0.0%|0.0%|0.1% |
+----+-----------+-----------+-----+---+----+---+-----+----+----+----+-----+

To drill down into the CPU usage for LVE 1095 I might use:
# lveinfo --period 24h --id 1095 --show-columns id from to cpuf mcpu ucpu | more

|1095|12-19 13:18|12-19 13:19|0   |87  |87.0%|
|1095|12-19 13:19|12-19 13:20|1   |100 |20.4%|
|1095|12-19 13:21|12-19 13:22|0   |8   |8.4% |

You'll notice the uCPU field is only 20.4% when the fault occurred. Unless lvestats2 is doing sub-minute granularity shouldn't the value of uCPU be 100% when the LVE hit the CPU lim it? Other than during this fault period the uCPU seems to match the value of mCPU (as a percentage).
  1. 19.12.2016 21:12:02
  2. # 2
Kevin Brooks Accepted Answer
Posts: 14
Joined: 10.08.2010
0
Votes
Undo
Here I see the opposite. I display the entry proc stats for LVE1004 for the last 5 minutes:
# lveinfo --period 5m --id 1004 --show-columns id from to epf mep uep 

+----+-----------+-----------+---+---+----+
| ID |    From   |     To    |EPf|mEP|uEP |
+----+-----------+-----------+---+---+----+
|1004|12-19 17:58|12-19 17:59|0  |0  |0.3%|
|1004|12-19 17:59|12-19 18:00|0  |0  |0.4%|
|1004|12-19 18:00|12-19 18:01|0  |0  |0.0%|
|1004|12-19 18:01|12-19 18:02|0  |0  |0.0%|
|1004|12-19 18:02|12-19 18:03|0  |0  |0.3%|
+----+-----------+-----------+---+---+----+

mEP = 0 when there has been 1 or 2 lsphp process running as that user over that same period of time. It looks like the uEP stats reflect that yet mEP doesn't.
  1. 29.12.2016 05:12:17
  2. # 3
Alexander Grynchuk Accepted Answer
Posts: 3
Joined: 19.12.2016
0
Votes
Undo
mEP = 0 when there has been 1 or 2 lsphp process running as that user over that same period of time. It looks like the uEP stats reflect that yet mEP doesn't.
The values of mEP and mEP  is rounded to a whole. The values of "uEP" fractional. But we chek why mEP=0.
You'll notice the uCPU field is only 20.4% when the fault occurred. Unless lvestats2 is doing sub-minute granularity shouldn't the value of uCPU be 100% when the LVE hit the CPU lim it?
uCPU = aCPU/lCPU
Data is collected every minute. And at this minute possible peak loads that cause faults, but at the same time, the average value may be less than 100%
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!
Guest
Submit Your Response
Upload files or images for this discussion by clicking on the upload button below. Supports gif,jpg,png,zip,rar,pdf
• Insert • Remove Upload Files (Maximum File Size: 2 MB)
Captcha
To protect the site from bots and unauthorized scripts, we require that you enter the captcha codes below before posting your question.