Context
A large Persian software download store, about 30 million unique visitors a month, running Easy Digital Downloads rather than WooCommerce, on shared cPanel hosting with LiteSpeed and PHP 8.3. The database sits on a separate server, which means the host's own backups do not cover it.
The problem
The account hit its CloudLinux CPU ceiling every morning from 08:00 onward. Most of the 503s landed on admin-ajax.php. A resource upgrade raised the disk and MySQL quotas but left the CPU limit untouched, so the outages continued. At one point during the incident the host suspended terminal access.
Constraints
Shared hosting with a hard CPU ceiling and no root. A 4.4GB database outside the host's backup coverage. Live revenue traffic that could not be paused. And a theme and plugin set the client did not want replaced.
What I did
The second finding took the access logs. Search requests were roughly 21% of all traffic, arriving from a widely distributed set of IP addresses, and each one ran a LIKE scan across 757,000 rows in the posts table, occupying a worker for about twenty seconds. Third, a page-view counter plugin was firing an admin-ajax POST on every front-end view, which bypassed the page cache entirely.
Around those, a set of smaller fixes. An orphaned cache block left in .htaccess was forcing a four-minute max-age over the LiteSpeed TTL, so I rewrote the file. The editor heartbeat went from 10 seconds to 120 through a must-use plugin. Redis object caching was enabled. A security plugin option had grown to 33MB and was cleared.
Finally I traced the row count itself: 615,750 of those posts were legacy log entries left behind by the Easy Digital Downloads 3.0 migration, along with 3.6 million rows of their metadata. Legacy logging had stopped in 2022 while the replacement table had been running since 2019, which made the old rows safe to purge.
Result
The sustained 503s stopped the same day OPcache was enabled. CPU faults fell from between 100 and 183 per hour to near zero outside the search bursts. The client received a full written report in Persian documenting every change and every file that should not be edited without care.