Indexing through Command line Magento1.x

Reindexing in Magento1.X through Command line:
Sometimes we need to re-index Magento through command line to avoid the broken process from Magento Interface.
On our Magento root folder we have shell directory that contains indexing script.
Go to your magento root folder then shell folder and run below commands:
1. php indexer.php --status
If you are indexing on xamp local throwing error like "PHP is not a recognized command" you can run command like below
E:/xamp/php/php.exe indexer.php --status
It will show you status of all the indexers like below.
2. To reindex a single index, we need to run the below command
php indexer.php --info
It will provide you the key of all indexers as below and to run any of indexer we use below syntax.
php indexer.php --reindex [Index Code]
php indexer.php --reindex catalog_product_price,catalog_url
OR
E:/xamp/php/php.exe indexer.php catalog_product_price,catalog_url
3. To reindex all
php indexer.php --reindexall
OR
E:/xamp/php/php.exe indexer.php --reindexall
It will output like this
Please rotate your device
We don't support landscape mode on your device. Please rotate to portrait mode for the best view of our site