Count the LScache folder in the account's total disk space
Hello,
After searching for large files/folders through scripts we came up to the following case:
Client with 7GB of disk space usage is having a 31GB LScache folder and his account is not suspended even though its limit is 20GB.
This happens because the /home/username/lscache folder is assigned to user "nobody" and as such cPanel does not count it into the total account's disk space.
That could easily be translated to this:
If a lscache folder is 10 GB on average, then for a server with 100 websites we will need 1TB of extra disk space which customers do not see just for their cache...
Also, if we go ahead and change the user of the lscache folder and assign it to "username", LiteSpeed will automatically revert it back to "nobody".
Because this situation can easily get out of hand, we would like the following:
As a Web Hosting Provider, when i go to the "Disk Usage" on a cPanel account, i would like it to measure the total disk space of all folders and files of that user, including the lscache folder. This will not allow clients to use more disk space than the assigned and will suspend their account when they reach the disk space limit. In return it will force the clients to use smaller TTLs for the caching or move to larger plans with more disk space.
As a Web Hosting Provider i want the customer to use only the assigned disk space amount, not more.
Replies have been locked on this page!