Skip to content

Which cPanel account is causing high server load — a ten-minute WHM triage

Load average is 40 on a WHM box with 200 accounts and the phone is ringing. Classify the load first — CPU, I/O wait, or memory — then attribute it through processes, HTTP, MySQL, disk and mail until you have a name.

Load average is a queue length, not a diagnosis, and it will never tell you who to call. The triage that reliably ends in a name has a fixed order. First classify the load — CPU, I/O wait, or memory — because each one sends you to a different command and reading the wrong one wastes the ten minutes you have. Second, attribute processes to Linux users, which on a cPanel box are cPanel accounts. Third, attribute HTTP load through the web server’s live status and the domain logs. Fourth, attribute MySQL load through the process list, mapping database names back to accounts through their prefix. Fifth, check disk and mail, because a mail spike and a traffic spike look identical from load average alone. Then, and only then, act on the name — and accept that sometimes the honest answer is that the server is oversubscribed and no single account is at fault.

What you’ll accomplish

  • Classify a load spike as CPU, I/O or memory in under a minute, so the next command is the right one.
  • Attribute running processes to cPanel accounts on both CloudLinux and plain CentOS-family hosts.
  • Turn a busy vhost or a busy database into the account that owns it.
  • Rule out mail and backups before you accuse a customer’s website.
  • Walk away with a named account and the evidence to show its owner.

Prerequisites

Root SSH on the WHM server. Everything below runs from the root shell; the WHM interfaces that mirror these views (Server Status, Process Manager, Apache Status) are fine but slower under load, and a box at load 40 often renders WHM at a crawl.

Know two things about the host before you start. First, whether CloudLinux is installed, because it gives you per-account accounting that plain Linux does not:

rpm -q lve-utils && uname -r
lve-utils-6.4.2-1.el8.cloudlinux.x86_64
4.18.0-513.24.1.lve.el8.x86_64

A missing package or a kernel without lve in the release string means every CloudLinux command below is unavailable and you take the fallback. Second, which web server is running, since the live-status mechanism differs:

/usr/local/cpanel/bin/rebuild_phpconf --current | head -n 2; ps -eo comm | grep -Em1 'httpd|litespeed'

Examples assume EasyApache 4 with accounts under /home. Core utilities are assumed present; iotop and sysstat may need installing (dnf install -y iotop sysstat), which is worth doing before the next incident rather than during this one.

How it works

Load average counts tasks that are runnable plus tasks in uninterruptible sleep — mostly disk waits. That second half is why load 40 can mean forty processes burning CPU, or one storage device so slow that forty processes are queued behind it, or a machine thrashing swap. Those three situations share a number and share nothing else, so the number alone cannot start an investigation.

What makes a cPanel server tractable is that account isolation is real at the operating-system level. Each cPanel account is a Linux user, its files live under /home/<user>, its PHP processes run as that user, and its cron jobs run as that user. So any tool that reports a Linux username is already reporting a cPanel account. The layers that do not report a username — Apache workers, the MySQL server, Exim — each keep their own identifier that maps back through a file on disk.

Table of four attribution layers: processes, HTTP, MySQL, and disk and mail, each with the command to run and the lookup that turns its output into a cPanel account name

Two of those mappings are worth memorising now. /etc/userdomains maps every domain and subdomain on the box to its owning account, one domain: user pair per line. And cPanel database names carry the account as a prefix — the database shopco_wp01 belongs to the account shopco — which is what lets a MySQL process list resolve to a customer.

Decision tree from a load average of 40, branching into CPU-bound, I/O wait and memory pressure, each with its attribution command, all converging on a named cPanel account

Step-by-step

1. Classify the load before running anything else. One snapshot of top answers the question.

top -bn1 | head -n 5
top - 14:22:07 up 96 days,  3:11,  2 users,  load average: 39.84, 31.02, 18.55
Tasks: 812 total,  38 running, 774 sleeping,   0 stopped,   0 zombie
%Cpu(s): 91.4 us,  5.1 sy,  0.0 ni,  2.9 id,  0.4 wa,  0.0 hi,  0.2 si
MiB Mem :  64268.5 total,   2011.3 free,  48122.7 used,  14134.5 buff/cache
MiB Swap:   8192.0 total,   8180.0 free,     12.0 used

Read the %Cpu(s) line. High us with low wa, as above, is CPU-bound — go to step 2. High wa means the disk is the bottleneck; skip to step 6. If free memory is near zero and swap is being used, confirm the direction with vmstat 1 5 and read the si and so columns: sustained non-zero values mean the machine is thrashing and memory is the story.

2. Aggregate CPU by user. The raw top display shows individual processes; you want totals per account, because forty small PHP workers beat one large one.

ps -eo user,pcpu --no-headers | awk '{c[$1]+=$2} END {for (u in c) printf "%7.1f  %s\n", c[u], u}' | sort -rn | head -n 8
  742.6  shopco
  188.3  mysql
   61.4  nobody
   22.7  brightpk
    9.1  root
    4.2  mailnull

shopco is your candidate. Note that mysql and nobody are shared identities — MySQL runs every account’s queries, and nobody is what Apache workers run as when a request has not yet been handed to a per-user PHP process. Neither can be blamed without going a layer deeper, which is steps 4 and 5.

Confirm what that user is actually doing:

ps -u shopco -o pid,pcpu,rss,etimes,args --sort=-pcpu | head -n 6
  PID %CPU   RSS ETIMES COMMAND
31284 99.4 214560   1841 lsphp: /home/shopco/public_html/wp-cron.php
31410 98.1 209884   1802 lsphp: /home/shopco/public_html/wp-cron.php
31533 97.6 211200   1774 lsphp: /home/shopco/public_html/index.php

ETIMES is elapsed seconds. Thirty-minute PHP processes that should finish in under a second are the shape of a runaway, and repeated wp-cron.php entries mean cron overlap rather than visitor traffic.

3. Use per-account accounting where CloudLinux provides it. On a CloudLinux host, lvetop ranks accounts by their live consumption against their own limits, which is a better ranking than raw CPU because it shows who is being throttled.

lvetop
   ID    EP  PNO   TNO   CPU   MEM     I/O  IOPS
shopco   19   58   211  398%  1.9G   4.1MB  1840
brightpk  3    9    31   14%  312M   0.2MB    28

For the recent past rather than this instant, lveinfo reads the accounting database:

lveinfo --period=1h --display-username --order-by=cpu | head -n 8

Accounts pegged at their CPU ceiling with rising fault counts are the ones generating 508 errors for their own visitors — see which CloudLinux limit an account hit for reading that from the account’s side. Without CloudLinux, step 2 is your only process-level ranking; there is no equivalent per-account accounting, and you compensate by leaning harder on the HTTP and MySQL layers below.

4. Attribute HTTP load. cPanel exposes Apache’s status handler on localhost, so no browser or WHM login is needed.

curl -s "http://127.0.0.1/whm-server-status?auto" | head -n 8
Total Accesses: 4128993
BusyWorkers: 246
IdleWorkers: 4
ReqPerSec: 88.2

BusyWorkers near the MaxRequestWorkers ceiling with almost no idle workers is a saturated pool. To see which vhost is consuming it, drop the ?auto and strip the markup:

curl -s http://127.0.0.1/whm-server-status | sed -e 's/<[^>]*>/ /g' | awk '/GET|POST/ {print $(NF-3)}' | sort | uniq -c | sort -rn | head

On LiteSpeed or OpenLiteSpeed, the equivalent live view is the real-time report file:

grep -E '^(REQ_RATE|EXTAPP)' /tmp/lshttpd/.rtreport | head

Either way, cross-check against request counts on disk. cPanel writes domain logs to /etc/apache2/logs/domlogs, with a per-user subdirectory on current versions:

cd /etc/apache2/logs/domlogs && \
find . -type f ! -name '*-ssl_log-*' ! -name '*.gz' ! -name '*-bytes_log' -mmin -5 \
  -exec sh -c 'printf "%6s  %s\n" "$(tail -n 3000 "$1" | grep -c "$(date -d "1 min ago" +%d/%b/%Y:%H:%M)")" "$1"' _ {} \; \
  | sort -rn | head -n 6
  4471  ./shopco/shopco.example
    88  ./brightpk/brightpk.example

Then turn the domain into an account:

grep -i '^shopco\.example:' /etc/userdomains
shopco.example: shopco

5. Attribute MySQL load. The mysql user in step 2 is a proxy for every account at once, so open the process list.

mysql -e "SELECT user, db, COUNT(*) AS threads, MAX(time) AS longest FROM information_schema.processlist WHERE command <> 'Sleep' GROUP BY user, db ORDER BY threads DESC LIMIT 8;"
+----------------+---------------+---------+---------+
| user           | db            | threads | longest |
+----------------+---------------+---------+---------+
| shopco_wp      | shopco_wp01   |     143 |     418 |
| brightpk_admin | brightpk_main |       2 |       1 |

The database name’s prefix is the account, so shopco_wp01 is shopco. Verify rather than assume, because long usernames and imported databases can break the pattern:

grep -rl 'shopco_wp01' /var/cpanel/databases/ | head
/var/cpanel/databases/shopco.json

The filename is the account. Read the actual statements with SHOW FULL PROCESSLIST when you need to know whether this is one bad query multiplied, or genuine volume; reading the slow query log on a cPanel host covers what to do with what you find.

6. Attribute disk and mail. When step 1 pointed at wa, or when the CPU picture was inconclusive, find the process actually touching the disk.

iotop -bon 2 -d 2 | head -n 12
  TID  PRIO  USER    DISK READ  DISK WRITE  COMMAND
20114  be/4  shopco   0.00 B/s   48.21 M/s  tar -czf /home/shopco/backup-2026-08-24.tar.gz
 8842  be/4  mysql   12.03 M/s    2.11 M/s  mysqld

A customer-run backup writing into their own home directory is a common and entirely legitimate cause of a load spike, and it is not a website problem. Check mail in the same breath, because a compromised account sending spam produces the same load signature as a traffic surge:

exim -bpc
exim -bp | exiqsumm | tail -n 12
18422
Count  Volume  Oldest  Newest  Domain
 9821    142M     14h     0m   gmail.com

A queue in the thousands is a spam incident until proven otherwise. Name the sending account from the mail log:

grep -o 'cwd=/home/[^ ]*' /var/log/exim_mainlog | sort | uniq -c | sort -rn | head -n 5
  9744 cwd=/home/shopco/public_html/wp-content/uploads

That path names the account and often the compromised directory in one line.

7. Act on the name. With CloudLinux, throttle before you suspend — it keeps the site up while you talk to the owner:

lvectl set-user shopco --speed=100 --pmem=1G
lvectl apply-all

Without CloudLinux the blunt instruments are what you have: kill the specific runaway processes, or suspend the account if the server is at risk.

whmapi1 suspendacct user=shopco reason='Sustained server load, contacted owner 14:31'

Validate it works

The attribution holds only if the load tracks the account. Apply the constraint, then watch for two to three minutes:

for i in $(seq 1 12); do cut -d' ' -f1-3 /proc/loadavg; sleep 15; done
39.84 31.02 18.55
28.11 29.60 18.71
14.02 24.83 18.33
5.61 18.44 17.55

The one-minute figure falling while the fifteen-minute figure stays high is exactly right: the fifteen-minute average is slow to forget. If the one-minute average does not move within three minutes of constraining that account, your attribution was wrong. Go back to step 1 and reclassify, since the most frequent cause of a wrong answer is treating an I/O problem as a CPU problem.

Re-run step 2’s aggregation to confirm the account has dropped out of the top of the list, and confirm the other sites on the box respond normally again.

Troubleshooting

The load is I/O and top misleads you. A process blocked on disk shows near-zero CPU, so a CPU ranking puts the real cause at the bottom. If wa is high or vmstat’s b column is consistently non-zero, ignore the CPU ranking entirely and start at iotop. On shared storage, also check whether the host itself is throttling you — iostat -x 2 3 with high await and low throughput on the device is a storage-side limit, not an account.

The busiest account is a backup job, not a customer. Check ETIMES and the command line before you contact anyone. cPanel’s own backup transport, a customer’s tar, and a third-party plugin’s scheduled export all look like abuse and none of them are. The fix is scheduling, not throttling. grep -i backup /etc/cron.d/* /var/spool/cron/* usually finds the schedule in one pass.

The mail queue is masquerading as web load. Exim delivery, spam scanning and the local mailbox writes together can push load into the double digits with no HTTP involvement whatsoever. If exim -bpc is high and your HTTP request counts are normal, you have a mail incident. Suspending the account’s outbound mail is faster and less disruptive than suspending the account.

The account is compromised, not busy. A cwd= path inside wp-content/uploads, PHP processes running from a temp directory, or a spike that started at an odd hour with no traffic to match are all signs. Once you suspect this, stop tuning limits — throttling a compromised account slows the attack without stopping it, and the account needs cleaning before it comes back online.

There is no single culprit. If your top-of-list account accounts for fifteen percent of CPU and the next nine accounts are all similar, you have found the truth: nothing is wrong with any one account, and the box is simply carrying more than it can. Say so plainly rather than picking the largest name on the list, because throttling an innocent account produces a support ticket and no improvement.

When this is the wrong approach

This triage is an incident procedure, and running it repeatedly on the same server is a signal you should stop running it. If load spikes are weekly, the question is no longer which account is responsible but why the box has no headroom — and that is a capacity decision, not a diagnostic one. A server routinely at load 40 needs fewer accounts, more cores, or faster storage.

It is also the wrong tool when the account is already known and the question is what to change inside it. Server-wide triage names an account; it does not tell that account’s owner which plugin, query or cron job to fix. Hand off to account-scoped work at that point.

Finally, if the pattern is that one account can degrade every other account on the box, the structural answer is isolation rather than faster detection. That means per-account resource limits applied as deliberate policy, with the choice between hard and soft ceilings made in advance rather than during an incident, or moving the noisiest tenants to their own instances. Detection that gets faster every year is still detection; it does not stop the outage.

Worth keeping open while you work: the cPanel and WHM documentation for server-level tooling, and the Apache mod_status documentation for reading the scoreboard fields properly.

If this is the kind of work you’d rather never own again, it’s the daily job of Managed Cloud Ops — book an infrastructure review.