Search issue – Error 508 'Resource Limit Is Reached'

Posted in: Newsmag
Post count: 8

Hello,

I get a 508 Error (Resource Limit Is Reached) almost every time I run a search on the website using the search bar in header (site/?s=<term>).
When analyzing my cpanel data (I have a shared hosting) I noticed that at the time when I click on search, more than 5 (Entry) Processes are created – and that exceeds my hosting package limit.

Can you please tell me more about the php code that runs on search so that I can investigate further? Also, do you have any suggestion on how I can work some optimizations here without upgrading my hosting pacakge?

Thank you!

Post count: 6535

Hi

Try do deactivate all plugins except Visual Composer, clear all caches and test again. Also try using a plugin like WP Super Cache for cache. Also check the values from system status: http://screencast.com/t/s2MbwfIV
max_execution_time should be at 300 and max_input_vars should be above 2000.

Let us know how it goes.
Thanks!

Post count: 208

Sorry to jump in here and be a bother but if anyone that uses free hosting with share hosting is limited badly. Not saying you are using free hosting but even the cheapest hosting is limited with resources and you even spend a lot of time in the dashboard with in an hour changing stuff on the website and then shortly after that visiting your website and then hoping other visitors visit the site end up seeing that resource limit or cpu limit error. Been there and done that with free hosting and really cheap hosting. Free hosting you get 5% resources and cheap hosting you get a max 15% resources. When you hit the limits, no matter what you change to the max_execution_time should be at 300 and max_input_vars should be above 2000. You will still see the errors with those low end hosting companies.

Not saying you are on that kind of hosting but if you are, then that will be more likely a big problem even changing those settings. That kind of hosting probably won’t even give you access to change the php.ini. Just a warning from someone that used to use free hosting and really cheap hosting.

Post count: 8

Thank you doucare1971 for the tips, indeed, it’s a cheap hosting…

Andrei L., the php.ini variables are green.
After I had deactivated the N-1 plugins (the performance was the same even with only 1 active plugin) I found that the main problem is the autocomplete feature of the #td-header-search input in the search form. Every time I type in something, an ajax request is sent to server. Do you know how I can disable that autocomplete feature in order to reduce the server load?

Thanks!

Post count: 6535

Hi

To deactivate the autocomplete feature you need to edit tagdiv_theme.js file and comment the indicated code like here: http://screencast.com/t/ftiZXtx1aiq4 If your using Speed Booster plugin the changes must be done in tagdiv_theme.min.js file: http://screencast.com/t/Z7DkfGPlwxht

Thanks!

Post count: 49

Hi Andrei,
I have a similar resource issue. Can you please advise on how to edit the min.js file correctly, to turn OFF autocomplete?
Thanks in advance.

Post count: 6535

Hi

Replace the code from tagdiv_theme.min.js file with this one: http://pastebin.com/iCbJb38p
Before making any changes please make sure that you do a full backup of your current theme installation and WordPress: http://codex.wordpress.org/WordPress_Backups

Thanks!

Viewing 7 posts - 1 through 7 (of 7 total)
The forum ‘Newsmag’ is closed to new topics and replies.