memory and cpu unit
Forum
  1. Forums
  2. General
  3. General Discussion
  1. tincboy tincboy
  2. Thursday, 14 July 2011
  3.  Subscribe via email
I\'m curious what is the unit of memory usage and CPU usage in /proc/lve/list file?
And how I can translate these numbers to Megabyte and Mega Hz?

Any help will be much appreciated.
Rate this post:
  1. 14.07.2011 11:07:48
  2. # 1
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
For CPU is Hz (in CL6/lve0.9 we plan to switch to nano-seconds)

For memory: 4k pages
  1. 09.08.2012 07:08:47
  2. # 2
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Have you moved to nanoseconds ?

If so then does this mean we can set less than 1% for CPU limits ?

Our next server will be running CloudLinux 6 and the configuration we are currently looking at has got 32 threads of 3.1 GHz, this makes 99.2 Ghz which means we have got to choose between 1.98 and 2.97 Ghz to remplace our current 2GHz limit per account.

If we could set a decimal after the percentage it would be great ! (or at least half a percent…)

2.1% would be 2.08 GHz which would be perfect for our 2GHz accounts !
  1. 09.08.2012 08:08:43
  2. # 3
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
Richard, yes we moved to nanoseconds in /proc/lve/list for lve1.x kernels.
Yet, the way to setup CPU limits is still the same.
No way to represent decimal points yet :(
  1. 09.08.2012 08:08:23
  2. # 4
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Thanks for the info,

Do you plan to try and integrate decimal points this year ? Do you have even an aproximate idea of if and when this might be integrated into the current system ?
  1. 09.08.2012 08:08:34
  2. # 5
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
Richard, 

We plan to let admin setup % as relative to individual core (which should be enough I believe) -- but we will not support decimal points.
I think this is something that might happen before the end of this year. This is mostly for sanity in setting limits, as so far you are the only one who requested better granularity.
  1. 09.08.2012 08:08:36
  2. # 6
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
A percetage per core would be great, it would actually be better then 0.1 decimal points…

With this setting I could get 2.02GHz which is closer than 2.08 GHz :)

I presume that we would be able to set 1 core + 65% of a core… Would this be represented as 165% ?
  1. 09.08.2012 08:08:49
  2. # 7
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
No, you would just set: 165% - which would mean 1 core + 65% of another core.
  1. 09.08.2012 10:08:43
  2. # 8
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Thanks that will be perfect :)
  1. 29.11.2012 12:11:17
  2. # 9
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Hello,

Do you have an update on this CPU limit per core instead of per server ?

Our latest server has got 32 * 3.1Ghz threads and the charts in the statistics don\'t show much detail when only 2 or 3% CPU is allowed and 1% equals 0.99 GHz of virtual CPU (threaded).
  1. 29.11.2012 12:11:07
  2. # 10
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
This is something I plan for Q1 2013. It is a small change, but given that so many customers would need to change their settings -- we want to plan it carefully.
  1. 29.11.2012 13:11:42
  2. # 11
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Great, thank you :)
  1. 01.12.2012 06:12:39
  2. # 12
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
I the mean time, is there something that could be done for the details in the statistics ?

With 3% allowed CPU

I see only the following percentages in the CPU usage :

0% => 0% total CPU usage
33% => 1% total CPU usage
66% => 2% total CPU usage
100% => 3% total CPU usage

I would like to have at least 10 different values so the users can get a more precise idea of what they are using.

Would it be possible to process the stats on less than 1% total CPU usage increments before implementing the ability to set more precise settings ?

Does this impact on the actuel limitations ? or just on the stats generation ?
Thanks
  1. 01.12.2012 08:12:51
  2. # 13
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
The exact CPU accounting info is in /proc/lve/list

It is in nanoseconds (for CL6), and in ticks for CL5
You can try accumulating it/using it instead, but it is quite a lot of work.
  1. 01.12.2012 08:12:01
  2. # 14
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Thanks for the info.

Can we hope to have this used in the stats in the future ?

I don't need the increments used in nano seconds but would like to have no more than 5% increments…

When you allow 25%CPU the stats look fine, even with 10% CPU but if you allow 1% CPU (about 1GHz in my case) the stats would always be 0% or 100% with nothing inbetween…)

Thanks
  1. 01.12.2012 08:12:51
  2. # 15
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
I presume to work out the stats you currently work out total percent of CPU usage for each minute rounded the the closes percent, then convert it to a percentage out of 100. Would it be possible to allow a few digits after the dot and only round to the closest integer when you get the final percentage ?
  1. 23.06.2013 06:06:01
  2. # 16
Richard Hordern Accepted Answer
Posts: 219
Joined: 19.03.2011
0
Votes
Undo
Is moving to 100% = 1 CPU instead of 100% = ALL CPU\'s still planned ? Do you have a new ETA ? Thanks :)
  1. 23.06.2013 13:06:41
  2. # 17
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
Yes, this is still planned. No ETA, but probably by mid fall it will be done.
  • 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.
By submitting the response, you agree with Cloudlinux Privacy Policy