What WP-Optimize does on every single request
WP-Optimize hooks into WordPress's init action and runs loader(). This method does pre-scan housekeeping: it checks for cache directories, verifies log paths, probes for stale files, looks for its own drop-ins. It does this by calling file_exists() — repeatedly, sometimes in loops, against the filesystem.
init fires on every WordPress request. Frontend page views. Admin dashboard. AJAX calls. REST API endpoints. Anonymous bot traffic. Everything.
On a virtualized block device — Linode's virtio-backed Ceph storage — a single stat() syscall completes in microseconds under idle conditions. But dozens of file_exists() calls per request, multiplied by concurrent PHP workers, multiplied by bot traffic, creates I/O contention. The virtual disk queue backs up. Requests that normally complete in 50–200 ms suddenly block for 10+ seconds, all waiting for their turn at the filesystem.
The Googlebot crawl at 6 AM didn't cause the spike. WP-Optimize's loader() running on every bot request caused the spike. Without the plugin, those same requests would have completed in milliseconds. The 1-minute load average would have stayed at 0.5.
There were 880+ PHP requests in that two-hour window. The slowlog only captured the two that crossed the 10-second threshold, but the plugin added filesystem overhead to every single one of them. And because the server hosts multiple WordPress sites, up to 6 PHP-FPM children could be simultaneously stuck in I/O wait — each one blocking the disk queue for the others.
The bot was polite — too slow for rate limits, too valid-looking for fail2ban jails — but persistent enough that every request cost 10–50× more CPU than it should have. That's the multiplier effect. The bot was never the problem; the per-request tax was.
Why caching plugins are unnecessary on a VPS
This incident made me audit what WP-Optimize was actually doing that I couldn't do better at the server layer. The answer: nothing.
WordPress performance plugins exist because shared hosting locks you out of the server configuration. You can't tweak nginx. You can't configure PHP-FPM. You can't set up a CDN at the edge. A plugin is the only lever you have. On a VPS, that constraint disappears — and in most cases, the plugin becomes the bottleneck.
expires max, open_file_cache, sendfileopen_file_cache keeps file descriptors warm, avoiding repeated stat() calls. expires max on hashed assets means return visitors never re-request the same file. A PHP plugin doing the same thing boots WordPress first, then reads the file in userspace — orders of magnitude slower, and it gets worse under concurrency.wp db optimize via weekly crongzip_static on, gzip on