Hi @markbignell,
The good news here is that as you maintain the web server we may be able to get to the bottom of this with the help of the Wordfence development team.
As the error is timestamped, appropriate MySQL/PHP/server log excerpts or files from around the 30-Nov-2020 14:20:39 UTC issue time would be greatly appreciated. With this issue in the past, we’ve been unable to gain all of the information surrounding the circumstances of the error to fully explain it.
Can you send a diagnostic report and the logs to wftest @ wordfence . com? You can find the link to do so at the top of the Wordfence Tools > Diagnostics page. Then click on “Send Report by Email”. Please add your forum username where indicated and respond here after you have sent it.
Note: For the fastest response time, please make sure and add any information or questions directly to this topic and not the email address above unless asked.
Thanks,
Peter.
Thread Starter
markb
(@markbignell)
Thanks for your assistance, Peter.
I have emailed you the error log which includes the time stamp as detailed. And I have sent the Diagnostic Report via the WF plugin.
This seems to be a common/recurrent problem on many of our sites so I’d love to know what’s happening here. Thanks again for your help!
Cheers,
Mark
Hi @markbignell, thanks for sending those over.
We have previously thought when this error crops up, MySQL/MariaDB is stopping, reconnecting and leaving the connection in a state that somehow causes this error to appear.
Your logs contain at least one error from another plugin, so it doesn’t look like it’s restricted to just Wordfence:
[26-Nov-2020 04:37:21 UTC] WordPress database error Commands out of sync; you can't run this command now for query SELECT post_id, meta_key, meta_value FROM wp_postmeta WHERE post_id IN (8) ORDER BY meta_id ASC made by shutdown_action_hook, do_action('shutdown'), WP_Hook->do_action, WP_Hook->apply_filters, LiteSpeed\Core->send_headers, LiteSpeed\Tag::output, LiteSpeed\Tag::_finalize, do_action('litespeed_tag_finalize'), WP_Hook->do_action, WP_Hook->apply_filters, LiteSpeed\Thirdparty\WooCommerce->set_tag, get_post_meta, get_metadata, get_metadata_raw, update_meta_cache
It’s likely that other server logs might hold the key to a bigger problem that’s occurring to cause the database to behave in this way.
Thanks again,
Peter.
Thread Starter
markb
(@markbignell)
Thanks Peter, I’ll take this info to our server sysadmin and see if they can identify what’s causing the break in the chain.
Thanks @markbignell, that sounds like a good course of action.
If you have issues with Wordfence in the future, please start another topic and we’ll be glad to help you out any time.
Thanks again,
Peter.
Thread Starter
markb
(@markbignell)
Just a follow up on this one. There was something on the server causing an intermittent load issue. This has since been resolved and the server has remained stable and performing very well for over a week. Yet we’re still seeing this obscure error repeatedly showing up in error logs.
[21-Dec-2020 06:45:25 UTC] WordPress database error Commands out of sync; you can’t run this command now for query SELECT *, CASE
WHEN type
= 3 THEN 0
WHEN type
= 4 THEN 1
WHEN type
= 7 THEN 2
WHEN type
= 6 THEN 3
WHEN type
= 5 THEN 4
WHEN type
= 9 THEN 5
WHEN type
= 8 THEN 6
WHEN type
= 2 THEN 7
WHEN type
= 1 THEN 8
ELSE 9999
END AS typeSort
, CASE
WHEN type
= 3 THEN parameters
WHEN type
= 4 THEN parameters
WHEN type
= 1 THEN IP
WHEN type
= 9 THEN IP
WHEN type
= 5 THEN IP
WHEN type
= 6 THEN IP
WHEN type
= 7 THEN IP
WHEN type
= 2 THEN IP
WHEN type
= 8 THEN IP
ELSE 9999
END AS detailSort
FROM wp_wfblocks7
WHERE type
IN (7) AND (expiration
= 0 OR expiration
> UNIX_TIMESTAMP()) ORDER BY typeSort
ASC, id
DESC made by wfWAFIPBlocksController::synchronizeConfigSettings, wfBlock::lockouts, wfBlock::allBlocks
Hello,
I had the same exact problem which I noticed this morning, where my website would not load until I disabled (via FTP) the WF plugin.
My error-log shows the similar “out of sync” pattern shown in this thread.
Is there a solution for this? Or is it database related?
Thank you!
Giannis