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
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'
  • Thanks @Alex P, I'll give it a try later and let you know. :) – chrone Dec 9 '15 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 '15 at 0:40
  • This only changes the status of index. When i re-index again, the problem re-occurs. Any solution for that ? – Reena Parekh Feb 15 '16 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. – Alex Paliarush Feb 15 '16 at 9:53
  • no i haven't tried that. I will check it, thank you. – Reena Parekh Feb 16 '16 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.

  • this command doesn't exist for me in 2.0.4 – jtate Feb 20 '17 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.