Sometimes we are asked "why is my site running slow" or "why am I getting kicked out of my site" or "why are my visitors seeing a 503 error".
It can be frustrating and complicated to diagnose but with the CloudLinux x LVE usage stats with Cpanel it will be become apparent what's happening.
On all our servers, we employ the use of CloudLinux LVE which stands for Lightweight Virtual Environment which is a kernel technology developed by CloudLinux.
The purpose of the LVE system is to provide a certain level of quality control on shared hosting environments so that one "abusive" account does not affect the other accounts on the system. LVE in effect provides a VPS environment within a shared hosting platform.
Before we start, please run through the glossary of LVE terms so you know what you are looking at in the screenshots below.
|CPU Usage||How much CPU Power you are using. When you've reached the maximum new processes will have to wait for old process to complete.|
|Virtual Memory Usage||Virtual memory corresponds to the amount of memory processes can allocate for an account. Hitting your memory limit will cause "out of memory" errors.|
|Physical Memory Usage||Physical memory corresponds to the amount of real memory actually used by your processes. Same thing, once you've hit the maximum physical limit memory errors will persist.|
|Input/output Usage||I/O to the disk subsystem caused by large operations such as backups and database dumps could be the cause of slowdowns if they reach their maximum.|
|Entry Processes||These are the number of processes allowed to run at one time. When the maximum is hit other processes will have to wait causing slowdowns for all active processes.|
|Processes||The total number of processes allowed. Additional processor needs will be ignored and the page delivery will likely result in 503 error.|
|Faults||This is the number of times your account has given a fault due to hitting one of the above limits. You want zero (0) faults. Any faults are a pretty bad sign and it means that you're not providing your account with the resources necessary for it to operate properly.|
Accessing the LVE Stats
Login to cpanel and in the search bar, type CPU and you will see an icon for CPU usage. Click on that to get to your stats for your account.
You see that the CPU Usage never goes above 75 percent.
The Virtual Memory Usage and Physical Memory Usage are both well below the maximum of 512 MB.
The Input/Output Usage never goes over about half of its allowance.
The Entry Process and Processes are both well below the limits, this is largely due to the fact that a process may last only a fraction of a second.
Finally, there are no Faults.
This website would not have any problems as it's well within its resource boundaries.
Here we can see that the account is almost always using 100% of its available CPU. Hitting this maximum slows down other processes that are waiting to be processed.
The last 24 hours view looks good for Virtual Memory Usage and Physical Memory Usage, but the graphs for the last 7 days show clear signs of using all available memory on multiple occasions (resulting in memory errors to website visitors).
The Input/Output Usage hits the maximum allowance several times a day, impacting the speed of all operations on the account.
The number of Entry Processes and Processes are fine, no problems here.
Finally, we see the Faults in the weekly view: 15,946 vMem (Virtual Memory) errors.
Clearly this site suffers from a lack of CPU and RAM and could use more I/O for those high use periods.
If you are experiencing speed issues with your site, as in it appears to be running slow, then if you check the LVE stats and determine where the issues are and either resolve them or upgrade your account to higher resource limits.