Bug #86986

Commands out of sync; you can't run this command now - error on TYPO3 backend module of EXT:indexed_search

Added by Peter Kraume over 2 years ago. Updated 3 months ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Indexed Search
Target version:
-
Start date:
2018-11-23
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
8
PHP Version:
7.2
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

In the production environment of my TYPO3 8.7 installation I get this error message when I try to open the TYPO3 backend module "Indexing":

Commands out of sync; you can't run this command now 

Doctrine\DBAL\Driver\Mysqli\MysqliException thrown in file
/home/www/html-data/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/Mysqli/MysqliStatement.php in line 280.

The problem seems to be in the loop in vendor/typo3/cms/typo3/sysext/indexed_search/Classes/Domain/Repository/AdministrationRepository.php in function getRecordsNumbers()

After some research it seems that closeCursor() is necessary, but I wasn't able to integrate that.

The funny thing is, that the error only occurs in my production environment. On the development machine, everything works fine!

So is this now a TYPO3 bug or a configuration problem of my production machine?

My environment:

- TYPO3 8.7.20

- Production:
-- PHP 7.2.8
-- MySQL 5.6.37
-- mysqlnd 5.0.12-dev

- Development:
-- PHP 7.2.7
-- MySQL 5.5.60
-- mysqlnd 5.0.12-dev

Only difference is that in the development environment pdo_mysql is not present.


Files

indexed_search.png (92.4 KB) indexed_search.png Peter Kraume, 2018-11-23 16:05
#1

Updated by Tobias Schmidt over 2 years ago

I recently came across this error in a single TYPO3 installation (TYPO3 8.7.10, PHP 7.0.30, MySQL 5.5.54) in two different situations:

  • Pasting copied news in the backend
  • Querying table tx_news_domain_model_news using QueryBuilder in a custom extension

The error only occurs in one of a dozen almost identical TYPO3 installations. And the error appeared all of a sudden a few weeks ago. Before that the installation was running fine without any problems. Until now I didn't manage to find out what causes this error.

Could it be that this is some kind of database error that has nothing to do with indexed_search or news?

MySQL documentation about Commands out of sync error_

#2

Updated by Stefan Franke over 2 years ago

  • TYPO3 Version changed from 8 to 9

I am experiencing this error when hitting the submit button to start a search in EXT:ke_search (branch "compat9").

TYPO3 9.5.1
PHP 7.2.10
MySQL 5.7.24
Ubuntu 18.04

#3

Updated by Stefan Franke over 2 years ago

  • TYPO3 Version changed from 9 to 8

Oops, sorry, didn't mean to change the TYPO3 version that was initially selected.

#4

Updated by Tobias Schmidt over 2 years ago

In my case table tx_news_domain_model_news was broken. Reading data worked but writing data sometimes didn't work for unknown reasons. Running mysqlcheck --auto-repair fixed this problem for me.

Tobias Schmidt wrote:

I recently came across this error in a single TYPO3 installation (TYPO3 8.7.10, PHP 7.0.30, MySQL 5.5.54) in two different situations:

  • Pasting copied news in the backend
  • Querying table tx_news_domain_model_news using QueryBuilder in a custom extension
#5

Updated by Peter Kraume over 2 years ago

Thank you Tobias Schmidt! This was the right hint. In my case, the index of index_rel was broken. Deleting the table and rebuilding it fixed the problem for me!

#6

Updated by Mona Muzaffar over 2 years ago

  • Status changed from New to Closed
#7

Updated by Tizian Schmidlin 8 months ago

Could we add this as a general error or troubleshoot for TYPO3 as a whole?

#8

Updated by Česlav Przywara 3 months ago

I came across the same error message in TYPO3 10. In my case it popped up in BE module of a custom extension and the actual problem was combination of insufficient sort_buffer_size on MySQL server in production and inefficient SELECT query. After I added one column used in ORDER BY clause to main index of the table, the problem was gone.

Would still like to know why I got this error in TYPO3 - I only found out about the insufficient sort_buffer_size when I rerun the problematic query in Adminer.

Also available in: Atom PDF