7

How to fix Magento 2.0 Index Management stuck at processing state?

There's no var/lock to delete inside Magento 2 root directory, so old ways to fix this are obsolete.

Forcing with these new CLI didn't work either:

sudo -u www-data php /var/www/html/magento2/bin/magento cache:flush
sudo -u www-data php /var/www/html/magento2/bin/magento indexer:reindex

2 Answers 2

9

Indexer status is stored in indexer_state table so try to update the status manually using:

update magento.indexer_state set status='invalid' where status ='working'
6
  • Thanks @Alex P, I'll give it a try later and let you know. :)
    – chrone
    Dec 9, 2015 at 10:59
  • Alex P, it works! Thanks :D Turned out it was causing by the latest update of php7.0-fpm in Ubuntu 14.04 exiting with SegFault every time the cron indexer ran.
    – chrone
    Dec 10, 2015 at 0:40
  • This only changes the status of index. When i re-index again, the problem re-occurs. Any solution for that ? Feb 15, 2016 at 9:49
  • Have you tried to get the latest Magento 2.0.2 release? It should be compatible with PHP 7 and no segmentation faults should occur anymore. Feb 15, 2016 at 9:53
  • no i haven't tried that. I will check it, thank you. Feb 16, 2016 at 6:20
2

You can fix this from the command line by reseting the index which will invalidate the state of the index and remove the processing flag from the index.

php bin/magento indexer:reset

Optionally you may also append the index name to the command to just just reset that index.

1
  • this command doesn't exist for me in 2.0.4
    – jtate
    Feb 20, 2017 at 14:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.