how much ram used each account holder.

KostonConsulting

Well-Known Member
Verifed Vendor
Jun 17, 2010
255
1
68
San Francisco, CA
cPanel Access Level
Root Administrator
cPanel doesn't provide per user memory usage information via API (or non-API unless I'm mistaken). If you're on CentOS, I'd recommend installing smem:

Code:
#yum install smem
You can get per user memory usage with the -u flag like so:

Code:
# smem -u
User     Count     Swap      USS      PSS      RSS 
haldaemon     1     1612        4       14      112 
dbus         1      320        4       23      136 
xfs          1      396       60       69      164 
cpanel       1        0      136      281     1092 
mailnull     1      328      324      331      808 
postgres     5     1960      596      785     2748 
named        1     1788     2600     2611     3112 
tomcat       1    36136    20468    20491    21092 
mysql        1    47316    29516    29551    30204 
mailman      9      628    49676    50298    62484 
root        55    13484   126880   151425   210068 
nobody      10     6476   172896   179761   252260
However, to get this information remotely (or via WHM addon), you will need an interface for that. You can create a custom API module for this. Here's an example where I created a custom module to get the main domain for an account. You can use the sample principles but instead parse and return the output from #smem -u | grep $user (or something similar).

http://forums.cpanel.net/f42/cant-get-accounts-primary-main-domain-name-350881.html