when you use wamp in windows7 for magento, you can open the cmd run as administrator and type code below to fix that warning. (magento2 is project name)
C:\wamp\bin\php\php7.0.4>php C:\wamp\www\magento2\bin\magento indexer:reindex
i have jsut installed
magento 2.0.4
on wamp 3 with php 7.0.4
on a windows 7 machine.
researching the solution is to place in the cli
php magento indexer:reindex
the problem is i do not know how to get to the cli, saw a tutorial on a app called mage but i cna not find it in my install.
my doc root is c:\sites\www\asite.com\magento
can someone give me a map of instructions to complete indexing and/or create a cron job.
thanks
craig
Solved! Go to Solution.
Hi @zpupster
On windows environment you have to set php as environment variable to be able to run the command from console.
Try following to set up the php as environment variable. (How to set the env variable for PHP?)
System>Advanced System Settings>Environment Variables
Click new
Variable name : path
Variable value : c:\wamp\bin\php\php5.3.13\
Click ok
Once you do this you will be able to run the Magento re index command.
Go to Magentto root from command line and run following command.
php bin/magento indexer:reindex
For cron job creation you have to create a scheduled job in the windows.
It is better to use Linux for the development (You can set up Magento on virtual box also)
How to reindex Magento 2 data from the command line? https://mage2.pro/t/163
How to setup and run cron for Magento 2? https://mage2.pro/t/32
Hi @zpupster
On windows environment you have to set php as environment variable to be able to run the command from console.
Try following to set up the php as environment variable. (How to set the env variable for PHP?)
System>Advanced System Settings>Environment Variables
Click new
Variable name : path
Variable value : c:\wamp\bin\php\php5.3.13\
Click ok
Once you do this you will be able to run the Magento re index command.
Go to Magentto root from command line and run following command.
php bin/magento indexer:reindex
For cron job creation you have to create a scheduled job in the windows.
It is better to use Linux for the development (You can set up Magento on virtual box also)
this is my root magento : bin>magento
#!/usr/bin/env php
<?php
/**
* Copyright © 2016 Magento. All rights reserved.
* See COPYING.txt for license details.
*/
if (PHP_SAPI !== 'cli') {
echo 'bin/magento must be run as a CLI application';
exit(1);
}
try {
require __DIR__ . '/../app/bootstrap.php';
} catch (\Exception $e) {
echo 'Autoload error: ' . $e->getMessage();
exit(1);
}
try {
$handler = new \Magento\Framework\App\ErrorHandler();
set_error_handler([$handler, 'handler']);
$application = new Magento\Framework\Console\Cli('Magento CLI');
$application->run();
} catch (\Exception $e) {
while ($e) {
echo $e->getMessage();
echo $e->getTraceAsString();
echo "\n\n";
$e = $e->getPrevious();
}
exit(Cli::RETURN_FAILURE);
}
Whre i put this code : php bin/magento indexer:reindex
when you use wamp in windows7 for magento, you can open the cmd run as administrator and type code below to fix that warning. (magento2 is project name)
C:\wamp\bin\php\php7.0.4>php C:\wamp\www\magento2\bin\magento indexer:reindex
I installed magento with softaculous installer and I dont know what to do to fix the problem. HELP ME PLEASE
Go to Root Folder of your Magento Installation and run the below command in the CLI.
php bin/magento indexer:reindex
The warning "Make sure your Magento cron job is running." will be gone for sure.
Thanks
Go to Root Folder of your Magento Installation and run the below command in the CLI.
php bin/magento indexer:reindex
The warning "Make sure your Magento cron job is running." will be gone for sure.
Thanks
It's working. Thank you.