XF 2.2 I have a huge problem !!!!

ScrapDog

Member
After updating my xenforo to v2.2.7 Patch 1, i get the following message:

Naamloos.png

An exception occurred: [XF\Db\Exception] MySQL statement prepare error [144]: Table './xenforo/xf_session' is marked as crashed and last (automatic?) repair failed in src/XF/Db/AbstractStatement.php on line 230

  1. XF\Db\AbstractStatement->getException() in src/XF/Db/Mysqli/Statement.php at line 198
  2. XF\Db\Mysqli\Statement->getException() in src/XF/Db/Mysqli/Statement.php at line 41
  3. XF\Db\Mysqli\Statement->prepare() in src/XF/Db/Mysqli/Statement.php at line 56
  4. XF\Db\Mysqli\Statement->execute() in src/XF/Db/AbstractAdapter.php at line 96
  5. XF\Db\AbstractAdapter->query() in src/XF/Session/DbStorage.php at line 57
  6. XF\Session\DbStorage->writeSession() in src/XF/Session/Session.php at line 217
  7. XF\Session\Session->save() in src/XF/Pub/App.php at line 462
  8. XF\Pub\App->complete() in src/XF/App.php at line 2348
  9. XF\App->run() in src/XF.php at line 512
  10. XF::runApp() in index.php at line 20

I have downloaded the full version again and installed the whole xenforo list. After that i get the same problems, except i can login again to the admin panel.
Can someone help me please to fix this issue !

Sincerely,

ScrapDog
 
If you click on the table to view its contents, there should be an option to "Empty" the table (if I'm remembering correctly).

Failing that, you may need to delete and recreate the table which you can do by running the following queries:

SQL:
DROP TABLE xf_session;

SQL:
CREATE TABLE `xf_session` (
  `session_id` varbinary(32) NOT NULL,
  `session_data` mediumblob NOT NULL,
  `expiry_date` int unsigned NOT NULL,
  PRIMARY KEY (`session_id`),
  KEY `expiry_date` (`expiry_date`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 
This is an issue with one of your MySQL tables, specifically the xf_session table. This is more of a server issue so you may want to discuss with your host.

If you have access to your database through PhpMyAdmin or similar then you may want to try clicking the “Repair” option against that table or clicking the “Empty“ or “Truncate” option.

If you don’t have access to do this then your host should be able to help.
 
Hello Chris,

thank you so very much for the help. It finally worked by the second option.
I am very glad it is saved.

But what can be the cause of this error, i like to know so i can prevent having another error like this....

thanks again,

sincerely,

ScrapDog
 
I have the same Problem

Error: Can only throw objects in src/XF/Db/Mysqli/Statement.php at line 79
  1. XF\Db\Mysqli\Statement->execute() in src/XF/Db/AbstractAdapter.php at line 96
  2. XF\Db\AbstractAdapter->query() in src/XF/Db/AbstractAdapter.php at line 220
  3. XF\Db\AbstractAdapter->insert() in src/XF/Mvc/Entity/Entity.php at line 1521
  4. XF\Mvc\Entity\Entity->_saveToSource() in src/XF/Mvc/Entity/Entity.php at line 1253
  5. XF\Mvc\Entity\Entity->save() in src/XF/Mvc/FormAction.php at line 71
  6. XF\Mvc\FormAction->XF\Mvc\{closure}() in src/XF/Mvc/FormAction.php at line 189
  7. XF\Mvc\FormAction->run() in src/XF/Admin/Controller/UserGroup.php at line 119
  8. XF\Admin\Controller\UserGroup->actionSave() in src/XF/Mvc/Dispatcher.php at line 352
  9. XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 259
  10. XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 115
  11. XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 57
  12. XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2487
  13. XF\App->run() in src/XF.php at line 524
  14. XF::runApp() in admin.php at line 13
 
Top Bottom