XF 2.2 Have this MySQL error on the logged-in members

ideasmania

Member
Hello there, I am getting thiis error using PHP 7.4 + MySQL 10.3.32-MariaDB-cll-lve, everything was runniing smoothly and about 4 days ago the logged-in users started to get this following error and having slow sessions specially on the thread pages (I guess the hosting company upgraded to this Mysql version that have some issues with Xenforo 2.2). BTW, I am on a shared hosting (thinking to move to a VPS soon).

Code:
An exception occurred: [XF\Db\Exception] MySQL statement prepare error [2006]: MySQL server has gone away in src/XF/Db/AbstractStatement.php on line 230

    XF\Db\AbstractStatement->getException() in src/XF/Db/Mysqli/Statement.php at line 198
    XF\Db\Mysqli\Statement->getException() in src/XF/Db/Mysqli/Statement.php at line 41
    XF\Db\Mysqli\Statement->prepare() in src/XF/Db/Mysqli/Statement.php at line 56
    XF\Db\Mysqli\Statement->execute() in src/XF/Db/AbstractAdapter.php at line 96
    XF\Db\AbstractAdapter->query() in src/XF/Session/DbStorage.php at line 57
    XF\Session\DbStorage->writeSession() in src/XF/Session/Session.php at line 221
    XF\Session\Session->save() in src/XF/Pub/App.php at line 462
    XF\Pub\App->complete() in src/XF/App.php at line 2354
    XF\App->run() in src/XF.php at line 517
    XF::runApp() in index.php at line 20

Any guess how I could solve this?
Thank you in advance
 
Ok, thanks for the replies.
I will try to migrate my website to a VPS and look into the wait_timeout setting.
As soon as the issue is solved, I will update this thread.
Kind regards
 
The issue was solved, at least it seems to be.
An addon called "[BS] Similar threads 2.2.6" was generating the problem, as soon as I disabled it, everything worked fine again.
I suppose there is an incompatibility between this add-on and the MySql version, or something.
In spite of this, I will move to a VPS in the next months.
Kind regards.
Many thanks. I was getting the same error. On a VPS . The hosting support kept on telling me they can't do anything to solve it.
I disabled the similar threads add on and it works fine now.

XF\Db\Exception: MySQL fetch error [2014]: Commands out of sync; you can't run this command now in src/XF/Db/AbstractStatement.php at line 228​


Anyone who is getting the above error for logged in users should try and disable the similar threads plugin to see if it works.
 
Back
Top Bottom