I know that there are many similar threads like this in StackOverflow - but the only reason I'm creating this is because though the question title is similar but the question is different.
READ THE WHOLE QUESTION BEFORE MAKING IT DUPLICATE!
I was using the latest cPanel update and one thing that intrigued me was the CPU/RAM usage.
Now one of the great thing about this section saw - it shows the meter depending upon the available resources in your account.
So if you are using a cloudlinux based system and you are allocated certain CPU/RAM the meter will work on that. On the other hand if you are in a simple linux environment - it will account the whole system resource.
I know that most of cPanel code was written in perl, but I was wondering if it is possible to retrieve these same data to develop a similar meter like it in PHP.
Any help will be highly appreciated.
EDIT: I already created an web app to retrieve the load average from the server. But I hope after reading the question above you guys already understood that I'm not looking for the load average. :)
EDIT 2 : I know how to retrieve the load average in php - but it is not going to help me here as first of all load avg is not just about the cpu (it includes many other variables) on the other hand there is no way to get the maximum load avg value so that I can create an percentage. So, please don't share the link of load average
thread in the comment.