Title: WordPress using high CPU Usage
Last modified: August 22, 2016

---

# WordPress using high CPU Usage

 *  [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/)
 * Hello,
 * I have a problem with WordPress and Server and it is driving me crazy, **hope
   some experts like you cal help me 🙂**.
 * I was on a Shared Hosting and one night (Like 5 days ago) the server started 
   to use CPU 80%+ and it make server go down. The sites I have on that server are
   new (No more than 250 total visitors per day) so the Hosting Company (**BanaHosting.
   com**) told me it was because a lot of PHP process was running.
 * I decided to move everything to **A Small Orange** (Cloud VPS) and it was OK 
   but just yesterday it started again.
 * Its important to mention that all of that sites have a lot of backlinks (50K+)
   so a lot of bots come to comment (50+ spam comments everyday) so this maybe is
   the problem cause (I am not sure).
 * Its very strange, also its important to mention that I only use the following
   plugins on the websites:
 * **WordPress SEO by Yoast
    Akismet Contact Form 7 Jetpack by WordPress Pretty 
   Link Lite Useful Banner Manager
 * Sites are using Genesis Framework Themes, so theme must not be a problem.
 * This problem is driving me crazy, one of the sites is currently off because if
   I turn it on in less than 2 minutes, it makes the VPS crash (Other sites use 
   a lot of CPU too, 25%-50%)
 * **Do any of you have any ideas about this?** Its very very strange, also I have
   a friend with the same VPS and similar sites and they work perfectly.
 * **Thank you very much to all 🙂**

Viewing 15 replies - 1 through 15 (of 25 total)

1 [2](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/page/2/?output_format=md)

 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181917)
 * When this happens, it’s usually plugins or theme functions causing conflicts 
   or loops.
 * Try deactivating all plugins. If that resolves the issue, reactivate each one
   individually until you find the cause.
 * If that does not resolve the issue, try switching to the Twenty Fourteen theme
   to rule-out a theme-specific issue (theme functions can interfere like plugins).
 *  Thread Starter [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181919)
 * I have tried that, but it keeps working bad :S
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181920)
 * Have you left your site with only Akismet and the Twenty Fourteen theme active
   for a few hours to see if load goes down? Keep in mind that most load stats aren’t
   realtime, so you’ll need to leave it for a while to see any difference.
 * Also, is this a WordPress Multisite installation?
 *  Thread Starter [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181922)
 * Do you mean multisite that I have multiple wordpress in same domain? Ifs that
   then no.
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181924)
 * No, Multisite as in [http://codex.wordpress.org/Create_A_Network](http://codex.wordpress.org/Create_A_Network)
 * Also, have you left your site with only Akismet and the Twenty Fourteen theme
   active for a few hours to see if load goes down? Keep in mind that most load 
   stats aren’t realtime, so you’ll need to leave it for a while to see any difference.
 *  Thread Starter [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181928)
 * I just tried what you said to me, keep it only with Akismet and Twenty Fourteen
   plugin and in just 1 minute, it was like this:
 * [http://i.gyazo.com/433b5614acead1ebdd423ca6097f1aae.png](http://i.gyazo.com/433b5614acead1ebdd423ca6097f1aae.png)
 * If I let it more time, it will crash my VPS instantly :S
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181929)
 * Ok, try switching off Akismet too.
 * If you get the same problem, it’s time to get in touch with A Small Orange again
   and press the issue. If their VPS can’t handle WordPress with no plugins running
   the default theme (in other words something most shared hosting provides can 
   handle, and some for free), then there has to be a problem with the server itself.
 *  Thread Starter [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181930)
 * I dont think so, because I friend of mine run similar sites with same plugins
   and theme and it work stunning fast and perfectly.
 * Also, the same problem happened on the previus hosting company.
 * Any other ideas?
 * Thanks!
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181932)
 * Not really, no. WordPress as-is, with no plugins, and an unmodified default theme(
   Twenty Fourteen, in this case), is really incapable of driving up the resource
   usage numbers you’re displaying.
 * You might want to take a good look at your server logs, look for excessive processes
   or loops, and especially check the error log for repeated errors. If you don’t
   see anything which points to a specific problem, get in touch with your hosting
   provider’s support for a more in-depth look.
 *  Thread Starter [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181933)
 * Dont you think maybe theres a error in some PHP file that is causing so much 
   lag? I had already created a ticket and they are looking into it, but they suggest
   its maybe bots trying to comment, etc.
 *  [catacaustic](https://wordpress.org/support/users/catacaustic/)
 * (@catacaustic)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181934)
 * Check your logs and see if the `xmlrpc.php` file is being requested a lot of 
   times. If it is, your site is being hit with a DOS attack that’s been pretty 
   prevelant for a while now. I’ve had the same symptoms as you on 5 sites so far,
   and that’s the reason why.
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181935)
 * > Dont you think maybe theres a error in some PHP file that is causing so much
   > lag?
 * No, otherwise every WordPress site would suffer from the same problem. Did you
   modify any of your core files?
 * Just in case, try [downloading WordPress](http://wordpress.org/download/) again
   and delete then replace your copies of everything **except** the `wp-config.php`
   file and the `/wp-content/` directory with fresh copies from the download. This
   will effectively replace all of your core files without damaging your content
   and settings. Some uploaders tend to be unreliable when overwriting files, so
   don’t forget to delete the original files before replacing them.
 * > they suggest its maybe bots trying to comment, etc.
 * Add this to your .htaccess file:
 *     ```
       # Stop spam attack logins and comments
       <IfModule mod_rewrite.c>
       	RewriteEngine On
       	RewriteCond %{REQUEST_METHOD} POST
       	RewriteCond %{REQUEST_URI} .(wp-comments-post|wp-login)\.php*
       	RewriteCond %{HTTP_REFERER} !.*(example.com|jetpack.wordpress.com).* [OR]
       	RewriteCond %{HTTP_USER_AGENT} ^$
       	RewriteRule (.*) http://%{REMOTE_ADDR}/$ [R=301,L]
       </ifModule>
       ```
   
 * In the above, replace `example.com` with your domain, add the domains of your
   other sites, and remove `jetpack.wordpress.com` if you are not using Jetpack 
   Comments.
 * This will stop bots attempting to comment (and login) directly via the comment
   and login files, before they even hit PHP/MySQL. If it really is comment bots,
   that will greatly limit their impact on your server.
 * Via [http://halfelf.org/2013/wp-login-protection-htaccess/](http://halfelf.org/2013/wp-login-protection-htaccess/)
 * Edit: And please do check your logs for an insane amount of xmlrpc.php hits as
   mentioned above.
 *  Thread Starter [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181937)
 * > Check your logs and see if the xmlrpc.php file is being requested a lot of 
   > times. If it is, your site is being hit with a DOS attack that’s been pretty
   > prevelant for a while now. I’ve had the same symptoms as you on 5 sites so 
   > far, and that’s the reason why
 * Yes, some of the sites show that file with a lot of CPU Load.
 * If its a DDoS attack, what do you recommend me to do?
 * Thanks!
 *  [catacaustic](https://wordpress.org/support/users/catacaustic/)
 * (@catacaustic)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181940)
 * The only thing that I was able to do (as the sites that I managed were on shared
   hosting…) was alert the hosting company, and just wait for it to pass. It took
   somwewhere from 1 to 4 days depending on how popular the sites were.
 * As you’re on a VPS you should also be able to block access to the `xmlrpc.php`
   file at the firewall temporarily, and this will remove all of that load from 
   the Apache server.
 *  Thread Starter [T4kuyax](https://wordpress.org/support/users/t4kuyax/)
 * (@t4kuyax)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/#post-5181950)
 * It seems to be the plugin “**Pretty Link Lite**”

Viewing 15 replies - 1 through 15 (of 25 total)

1 [2](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/page/2/?output_format=md)

The topic ‘WordPress using high CPU Usage’ is closed to new replies.

## Tags

 * [cpu-usage](https://wordpress.org/support/topic-tag/cpu-usage/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 25 replies
 * 7 participants
 * Last reply from: [Volunteer Nimda](https://wordpress.org/support/users/volunteer-nimda/)
 * Last activity: [11 years, 2 months ago](https://wordpress.org/support/topic/wordpress-using-high-cpu-usage/page/2/#post-5182245)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
