The query which is slow is this one:
SELECT wp_comments.comment_ID FROM wp_comments JOIN wp_posts ON wp_posts.ID = wp_comments.comment_post_ID WHERE ( comment_approved = ‘1’ ) AND wp_posts.post_status IN (‘publish’) AND comment_type != ‘pingback’ AND comment_type != ‘trackback’ ORDER BY wp_comments.comment_date_gmt DESC, wp_comments.comment_ID DESC LIMIT 0,10 ;
The problem possibly looks to be with the “order by” clause. Removing one or other of the “order by” elements speeds things up so there may be an issue compounded with the 2 fields specified together?
I’ve created various single-field indexes in the past to workaround some problems but, before I look at creating another index to speed this query up, I just want to ask whether whether it may be better to modify the query in the plugin? I can imagine a number of sites with a lot of comments may suddenly start to see issues.
I’m using Mysql 5.7.40, so the latest version of 5.7 by the looks of it (yes I should upgrade one day…!).
I checked other plugins too but I am fully sure its cause by this plugin.
Thank You
I have a bit of a strange issue. Running this site several years now, but never encountered anything like this. Two weeks ago (according to Google Search Console excluded noindex pages and me manually checking mysql processes), more and more hits to the database started to occur. All very similar:
SELECT COUNT(*) FROM xx_posts WHERE 1=1 AND (((xx_posts.post_title LIKE '%google=662496898\\_session/feed/rss2/<a_href/page/3//page/1/&usg=AOvVaw1w32-jX45qQEhTH-iBghzF
The part after rss2 tends to change. No idea where this is coming from, but it seems to be increasing and causing the server load to increase as well.
Has anyone seen this before? Or hints to find where this is coming from? No new plugins or themes were installed in the past few months. Everything is up to date.
Thank you in advance.
Jonas.
SELECT post_id, meta_value FROM wp_postmeta WHERE meta_key = '_wp_attached_file' AND meta_value = '?'
queries to the point it hit my connection limit.Is there any way to update for me? Can I disable lazy indexing (I guess that’s the issue) and just index through CLI(probably bad idea anyway because it will take ages)?
]]>We are investigating a load issue where every time we update a WordPress blog comment (e.g. flagging it as spam), it causes our server load to extremely high to a point it becomes inaccessible.
We checked the MySQL logs and we identified 2 possible culprits.
One is Autoptmize but we have already ruled that out after further tests.
We are also looking into Yoast SEO as whenever we do a comments update, it fires a hugh chunk of SQL update below:
UPDATE wp_usermeta
SET meta_value
= ‘a:2:{i:0;a:2:{s:7:\”message\”;O:61:\”Yoast\\WP\\SEO\\Presenters\\Admin\\Indexing_Notification_Presenter\”:3:{s:18:\”\0*\0total_unindexed\”;i:19806;s:9:\”\0*\0reason\”;s:13:\”first_install\”;s:20:\”\0*\0short_link_helper\”;O:38:\”Yoast\\WP\\SEO\\Helpers\\Short_Link_Helper\”:2:{s:17:\”\0*\0options_helper\”;O:35:\”Yoast\\WP\\SEO\\Helpers\\Options_Helper\”:0:{}s:17:\”\0*\0product_helper\”;O:35:\”Yoast\\WP\\SEO\\Helpers\\Product_Helper\”:0:{}}}s:7: …………
Just wondering why is this always firing and can this be a cause of consuming huge server resource?
Thanks!
]]>I traced the process and found /public_html/index.php
(wordpress home) cause of this high CPU load.
I didn’t see single.php
or any other page taking such high loads.
I disabled all the plugins and tested, but same result as before.
Also my server has several wordpress installations, only this site (other sites has different themes) has this type of issue due to the boldr-lite theme.
Please check and issue an update to reduce the server load.
]]>Thus I was wondering whether disabling autoload would cripple the plugin. Obviously, I want to remain compliant with the GDPR directives, so I need the ability to submit the deletion etc requests to work, I just don’t think it’s necessary for the plugin to draw 2.7MB of data out of the database with each click. I get maybe 2 or 3 GDPR requests a month so the plugin is one of the least busy ones, but puts more strain on the server than any other.
Please let me know whether it’s safe to turn autoload to NO in the database. Thank you.
]]>After dissabling plugin, load returns to normal.
any help with that?
]]>Print: https://prntscr.com/f90uwp
What uses so much RAM and CPU? i have 16GB of RAM and i76700k on my server.
]]>