![]() |
Wordpress Site shutdown for cpu usage, need help Ive had many wordpress sets and most if not all use the same plug ins. Ive even had ones with more disk usage and 5X more traffic but for some reason this one keeps getting shut down for cpu usage. ( main index page ) Anyone have any ideas of what I can try or look for to correct the problem? ( Im using reseller hosting from hostgator ) |
Re: Wordpress Site shutdown for cpu usage, need help Are you using a caching plugin? That will help a lot with your CPU usage. HostGator recommends this one: WordPress › W3 Total Cache « WordPress Plugins I've used WP-Super Cache too, but W-3 Total Cache is not as resource intensive. |
Re: Wordpress Site shutdown for cpu usage, need help Are you using THAT MUCH plugins? Cause thats a weird case, I have hundreds of WP sites and never had a problem. Have you looked into your theme files carefully? |
Re: Wordpress Site shutdown for cpu usage, need help Either upgrade your account or get another account and off load the website onto its own account. Or you could get a virtual/dedicated server which should also eliminate the problem. How these hosting providers work is that they run a ton of sites on a single computer. When one sites uses to many resources they limit/shut down the site. |
Re: Wordpress Site shutdown for cpu usage, need help The reason it's sucking up CPU power is because every pageview on a wordpress blog takes 10-15 mysql queries. If you are getting say 1000 page views/day, that's 10,000 - 15,000 mysql queries throughout the day. That actually puts a lot of strain on a shared box. Even if the blog in question gets less traffic, maybe you're running some kind of plugins on it that cause even more database queries to be run on every pageview. I have a blog running that does about 40 queries/page view for example. The best thing you can do is look at one of the caching plugins, ideally one that will create static .html files and will force your blog to serve those instead. That way mysql is only touched when you update the site somehow. This will take you huge CPU usage down to practically nothing and fix your problem :) |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
|
Re: Wordpress Site shutdown for cpu usage, need help I use godaddy and I have never had a problem, sounds like you need to change hosts |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
EDIT: It's also worth pointing out that when I was using HostGator and a blog started using too many resources, this is the plugin they suggested. Given how overloaded their servers are, it's probably one of the better options if they're telling people to use it. Here's the link: WordPress Optimization | W3 Total Cache | W3 EDGE | Boston, MA |
Re: Wordpress Site shutdown for cpu usage, need help WP is so under-optimized if you don't install the right plugins. There is no built in caching, no js and css compression, and no js and css combining, none of the themes I have seen use any sprites, very poor top to bottom. |
Re: Wordpress Site shutdown for cpu usage, need help I have the W3 cache plugin installed and they have stated that I have it properly set up as well. One email response I got said something about 404 errors, I did have about 30 links to pages that I hadnt created yet, would that really cause the problem? I have since corrected that situation by pointing them all to a coming soon page but hostgator has yet to unsuspend my site for me to see if it has helped. They also recommended cloudflare and I have installed/used it now too but have yet to see if it helped due to them still not unsuspending my site. They take 8 hrs to respond to my emails and then its always a different person and instead of listening to what I said I did to try to correct the problem and unsuspending the account to see if it worked, they tell me they need my ip so they can unblock me so I can fix the problem. Its a never ending cycle that has been going on for 2 days now. Any other suggestions of what may be the cause/fix besides using W3 cache ( that was already there and didnt help ) |
Re: Wordpress Site shutdown for cpu usage, need help ErnieB - how much traffic does this site get? Seems to be a lot of hoops they're making you jump through to fix this. Are you able to access you files and everything right now? Can you login to cPanel? If so, do a complete backup of EVERYTHING. HG may just close you account down and you want to make sure you are backed up and can move easily. |
Re: Wordpress Site shutdown for cpu usage, need help I can access the wp-admin and the site itself ( including forum ) but cannot access cpanel or webmail. I could probably send another email and tell them this and they would grant access but then not release my site, lol. I also have ftp access through filezilla. I really want to see if the latest changes I made fix/help solve the problem. |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
|
Re: Wordpress Site shutdown for cpu usage, need help Plugins installed are ... Akismet Contact Form 7 Easy Privacy Policy Exec-Php Google Analytics for Wordpress Google XML Sitemaps Gregs High Performance Seo MaxBlogPress Ping Optimizer Onlywire for wordpress phpbay lite W3 Cache |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
|
Re: Wordpress Site shutdown for cpu usage, need help its needed for the phpbay lite to work ( at least it was a year or 2 ago when I learned about it ) Its used so ebay auctions can be displayed on my pages/posts |
Re: Wordpress Site shutdown for cpu usage, need help Hi ErnieB, We have had similar trouble in the past with HostGator's reseller hosting as well as SEO Hosting(by HostGator). Here's some plugins to use and some to avoid or delete: Use:
Delete:
To use GD Press Tools Lite to check how many queries your plugins are running on your homepage: Go to GD Press Tools > Settings > Debug and in SQL Queries select Enable logging of SQL queries and Add SQL queries at the end of the blog pages. Then clear your browser cache and load your homepage. Scroll down the bottom and you will see how many queries were run and by which plugins. Deactivate any unnecessary plugins that run too many queries. When you talk to HostGator support, tell them everything you have done and why you think this should have resolved the load on their cpu. Also tell them you are happy to do anything else they suggest and they should reactivate your account. Hope that helps. :) Shane |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
Amount of web space File type and size limitations Bandwidth allotment Reliability and speed of access Data Transfer (Traffic/Bandwidth) Technical support FTP, PHP, Perl, SSI, .htaccess, telnet, SSH, MySQL, crontabs SSL (secure server), Shopping Cart Email, Autoresponders, POP3, Mail Forwarding Control Panel Multiple Domain Hosting and Subdomains |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
|
Re: Wordpress Site shutdown for cpu usage, need help Quote:
My guess is the number of queries goes down when you refresh because your browser is loading from it's cache. Always delete the browser cache when you reload the page. Deactivate any plugins you suspect one at a time and reload a page to see if the number of queries drops a lot. I think 118 queries is high, I get about 30 to 50 with sites that have a good number of plugins running. Shane |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
100-150 queries per pageload is obscene, there's gotta be something fishy going on there. Can you list off which plugins you have installed and running right now? What theme are you using? |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
100-150 is obscene. You really want < 5 per page. If you have the caching plugins, something isn't right at all. |
Re: Wordpress Site shutdown for cpu usage, need help Get a professional to optimize it, or else get a virtual private server so you can dedicate more resources to it. This is often what happens when you try to solve all your problems by just adding more plugins. Without solving at least SOME of your problems in a custom manner, you're always going to be creating the "splinter effect", in which layers and layers of unnecessary bloat code are added to solve only a limited set of problems. My vote/guess also goes to the exec-php in combination with the ebay plugin |
Re: Wordpress Site shutdown for cpu usage, need help I have multiple queries like this will just the bolded number changed. 35 of the 56 queries were this code below ( just number changed ) # Call originated from: require, require_once, include, get_header, locate_template, load_template, require_once, wp_nav_menu, wp_get_nav_menu_items, get_post_meta, get_metadata, update_meta_cache, W3_Db->query Execution time: 0.000116109848022 SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (285) I dont recognize any plugin names on almost zero queries. One query looks to be maxblogpingoptimizer cause it references ping but the rest are all wp and meta keyword related |
Re: Wordpress Site shutdown for cpu usage, need help One thing that I've not seen addressed here is the theme you're using - a poorly-written theme can add a LOT of overhead in terms of db calls and resources used. If you want to do a quick and dirty check, load the old Classic theme and check the number of queries. |
Re: Wordpress Site shutdown for cpu usage, need help whats the page in question? im willing to bet its throttle time that is getting your site shut down. throttle time is usually caused by a bad JavaScript or missing JavaScript that is trying to load. open your site in ie, and see if there are any errors on the page ( it will say "done but with errors") or something along them lines in the corner, click the error and it will tell you what script is causing the issue. i cannot see it being based on database calls. frig most dynamic sites ( including this one) have multiple calls to the database on every page load. I really doubt thats the issue. youi still should really consider optimizing your pages, as 150 queries is TOO much , but not anywhere near what would get your site shut down. |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
A sitemap is only useful if parts of your site are not linked to, or you need to tell search engines about new content. Wordpress's ping solves both of these problems. |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
If you have the WP cache (whichever one) running correctly, these pages should not be running ANY php at all. What should be happening is the caching plugin creates an HTML file, and adds it to the .htaccess rewrites to hit the HTML file directly. Any sitemap plugin or cacher will update the cache on new posts or new plugin updates and installs. *** If this is not happening on your site you have something configured wrong ** |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
After the xml file is updated it's complete. Schedule a cron to post your updates at night/early morning if you can. |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
|
Re: Wordpress Site shutdown for cpu usage, need help Ive got rid of the sitemaps plugin and the theme I am using is called "Graphene". Ive looked at the site with internet explorer and do not notice it saying any errors. As for the query I posted above, it is from a page and not a post or front page so there should be no reference to any posts in my mind? It seems that there is quite a few queries at first, but then the cache kicks in and on future page views it is down to a more managable. Isnt that suppose to be how it works? I am using the W3 cache plugin and have all the boxes checked to enable all the different cahce and have selected "disk" as the method. No clue really on how to set it up properly With the GD tools, will it display the queries for all visitors at bottom of page or just me? I dont have it currently set to display them but anyone can view the site ( and I can turn it on if you want ) spartanbloks.com |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
I haven't looked into how each one works at the code level. JavaScript has nothing to do with this, JavaScript is run at the client's computer. What plugins do you have creating/updating meta tags? |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
|
Re: Wordpress Site shutdown for cpu usage, need help Quote:
|
Re: Wordpress Site shutdown for cpu usage, need help What is the Onlywire plugin your using for sharing? its horrific on the client side page load, disable it for faster load times or pick only 3-4 "shares". It's blocking the page loading significantly, and will mess up your analytics (analytics is loaded last and these images are blocking the page load by 1s per image). That has nothing to do with CPU usage, just an observation. |
Re: Wordpress Site shutdown for cpu usage, need help I have no clue, these are the current plug ins. At the advice of the tech support I signed my site up for cloudflare and its running through it ( I think ) I also moved all images to Amazon S3. Akismet Contact Form 7 Cloudflare Easy Privacy Policy Exec-Php Google Analytics for Wordpress GD PressTools Gregs High Performance Seo MaxBlogPress Ping Optimizer No Right Click Images plugin Onlywire for wordpress EDITE: Just saw above post and deactivated this phpbay lite W3 Cache |
Re: Wordpress Site shutdown for cpu usage, need help I've heard that your permalink structure can cause problems, as well. If you use a very short structure -- such as postname alone -- it works the database hard and slows it down if you have a lot of content. John |
Re: Wordpress Site shutdown for cpu usage, need help I also just restored the listing of queries so it probably will show at the bottom of the page if you view it again to see it all |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
btw. the right click image plugin http://s3.amazonaws.com/media.sparta...Images/Arbitor Fig.jpg (link doesn't work cause of space in filename) Useless if somebody really wants your images.... |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
i was able to grab a image in 3 seconds, if you inspect elements, it will show the link for each image in the code, that is click-able and can right click/save, adds about 3 seconds to the stealing process lol. http://website-design-firm.com/saveas.jpg |
Re: Wordpress Site shutdown for cpu usage, need help I know but kids are either not that smart or too lazy to waste those precious 3 seconds, lol The gregs plug in was recommended by them to replace my all in one seo pack. The W3 was also recommended by them but I already had it installed ( no clue on configuring tho ). Really no clue of the maxblogpress ping plug in, I just remember it being recommended a long time ago so I keep installing it on all my sites. BTW just wanted to say thanks to all of those that have taken time to comment and try to help me. I really appreciate it. EDIT: anyone seeing the queries listed at the bottom of the page/s? |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
http://perishablepress.com/wpseo-vs-aioseo/ you would also be amazed what kids will do when you tell them you can't lol. when i was a kid i would have stole your images just because i knew you didn't want me to lol. |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
No, we don't see the Queries, probably only admin logins can see. **Edit: which page do you see 150 queries? ** |
Re: Wordpress Site shutdown for cpu usage, need help everything seems to be at about 20 or less queries... At least the site hasnt been suspended yet, lol. Guess I will just have to wait and see. I did deactivate the gregs but didnt notice any real changes so I reactivated it. |
Re: Wordpress Site shutdown for cpu usage, need help ErnieB, I'm in the same boat you are. I'm trying to find the culprit, and here's what I've been doing that seems to be helping: I copied the site to a beta site so I could tear it apart. Installed GD Press Tools DEactivated W3 Total cache (so I could see real numbers - since cache doesn't always optimize a page load & makes it so the numbers aren't consistent) Then, I'm looking at my homepage. Everytime I hit refresh, I look at this line (from GD Press Tools) at the bottom of my page: "Total number of queries: 89" I'll deactivate something & see how many queries it saves. Here's my grid: Function - How many queries it uses -------------------------------------------------------- all plugins - 16 queries Top Navigation menu - 8 bottom nav menu - 7 Blog list of 20 latest posts (homepage) - 59 !! Just start tearing your BACKUP site apart, to see what decreases the queries. I deactivated/deleted: All plugins All widgets All menus Sidebars (facebook boxes) Footer (comments/tag cloud) Then (I have a little php knowledge), I was still getting 89 queries on homepage (I started at 298!), I started deleting lines from my template's index.php file. It turns out, there's a php function called: the_post_thumbnail() that uses 3 queries for each post (20 posts * 3 = 60 queries on homepage!) That's where I'm at. Still looking for more... |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
Time to invest in some better programming, not more exp monthly costs, just for a sitemap! |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
Seems this is the case across the board as I am starting with a fresh install .. Ernie, How many queries run on this page? Playsets » Spartan Bloks |
Re: Wordpress Site shutdown for cpu usage, need help Quote:
I mean unless your doing MILLIONS of visitors a day, and you are already on a VPS. With WP caching setup correctly, and a FULLLY optimized page (compressed files -gzip, compressed js and css, and COMBINED, and icons made to sprites, and js on bottom of page, etc etc) at that point you should be serving at most 1 html file (no php ran), 1 css file, 1-2 js files (analytics) , 1 icon sprite, and possibly 1-2 images (optimized!) per post. Seriously I look at what some of these sites load up in Firebug, 134 requests for the site we are looking at here, that's 134 different objects the browser has to load up to show the page. Most browsers by DEFAULT only load 4 objects at a time per domain. Now, most of you don't even take advantage of your amazon CDN's by CODING them correctly. What's the point of having amazon hosted images when they are still being blocked from all the other garbage being loaded? All those images are blocking anyways, why not mix it up too? some hosted on amazon, some on the domain. Are you specifying the width and height of each image? if not, the browser has to spend time to re-render the page. There are TONS of things you can do to optimize your site, going to the cloud is not one of them for wordpress .. |
Re: Wordpress Site shutdown for cpu usage, need help I agree with the above statement 101%! I say it and see it all the time. Along with avoid plug-ins unless it is essential to the functionality of the site. Then if you use such a plug-in, check the code(is it properly coded), if you can't read code, read comments about it ect... Find out if it functions correctly or has issues, most have issues, including loading extra files, multiple queries, etc.... A lot of themes out there are awful as far as code also. Optimise the site itself first, theme, files, plug-ins, scripts, http requests... Recent functions from WP such as the_post_thumbnail() can have heavy loads as they are new and not optimal yet. Be careful when using them. The menu system is another feature that I benchmarked and is high on queries. Fine if you have one menu, but some themes use this everywhere and it can get heavy quick. Widgets can also have some high queries. It doesn't take long to over load a site when not paying attention to what it is doing on the backend. |
Re: Wordpress Site shutdown for cpu usage, need help When I clicked the link to my page from your post i ended up with 17 queries. As for your mentioning not needing cloud stuff or images on amazon. I got no clue about any of that stuff, I just signed up for them cause it was mentioned as a possible solution. I dont know how to do anything your suggesting, lol. I know just enough to get myself into trouble as you see. I have no clue if what I signed up for is set up/working properly or not. And i dont understand any of the technical mumbo jumbo of optimizing my js this php that. I do understand image size but dont know how to incorporate it like you say to "optimize it" or make it so it isnt "blocked" Quote:
|
| All times are GMT -6. The time now is 09:27 PM. |