Magento 2 error: One or more indexers are invalid
In Magento 2, after you change your system configurations, there will be a system message saying “One or more indexers are invalid. Make sure your Magento cron job is running.”
What is Magento cron job?
Several Magento features require at least one cron job, which schedules activities to occur in the future. A partial list of these activities follows:
- Catalog price rules
- Generating Google sitemaps
- Customer Alerts/Notifications (product price change, product back in stock)
- Private sales (Magento Commerce only)
- Automatic updating of currency rates
- All Magento e-mails (including order confirmation and transactional)
Magento depends on proper cron job configuration for many important system functions, including indexing. Failure to set it up properly means Magento won’t function as expected.
How to solve it?
To get rid of this message, you need to perform reindex task using command line.
1. Open your command line tool (SSH or Terminal)
2. Go to your Magento 2 root folder
3. Type this command to reindex:
php bin/magento indexer:reindex
4. Go back to your backend, close the popup message and refresh the page.
A knowledge craver who always strive to be wiser everyday.