Understanding the Error
If you’ve encountered this WordPress error:
“Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 86016 bytes) in /home/devrumman/public_html/wp-includes/class-wpdb.php on line 2351” — don’t worry, it’s a common issue.
This means your WordPress site has run out of allocated PHP memory.
Why It Happens
By default, your hosting server allows a specific amount of memory for running PHP processes. When your website tries to use more than that limit, you get the “allowed memory size exhausted” error.
It can happen when:
-
You install a heavy theme or plugin.
-
You import large content.
-
You have multiple plugins running simultaneously.
Step-by-Step Solution Using cPanel
You can easily increase PHP memory allocation to fix this problem. Here’s how:
-
Log in to your cPanel account.
-
Find and click on “MultiPHP INI Editor.”
-
Choose your domain name (e.g.,
devrumman.com). -
Under Basic Mode, look for the
memory_limitsetting. -
Change the value from
128Mto256M. -
Click Save to apply changes.
This adjustment gives WordPress more memory to handle complex scripts, preventing similar errors from occurring again.
Additional Tips
-
Keep your plugins and themes updated.
-
Deactivate unused plugins.
-
If the issue persists, contact your hosting provider for a higher PHP memory allocation or server upgrade.
Conclusion
The “Allowed memory size exhausted” error might look intimidating, but it’s easy to fix using cPanel. By increasing the memory limit to 256M, you ensure smoother site performance and fewer PHP-related issues.

