1. Installation stops at about 70%
During installation using the Setup Wizard, the process stops at about 70% (with or without sample data). No errors display on the screen.
Common causes for this issue include:
- The PHP setting for
max_execution_time
- Timeout values for nginx and Varnish
Solution:
Set all of the following as appropriate.
All web servers and Varnish
- Locate your
php.ini
using aphpinfo.php
file. - As a user with
root
privileges, openphp.ini
in a text editor. - Locate the
max_execution_time
setting. - Change its value to
18000
. - Save your changes to
php.ini
and exit the text editor. -
Restart Apache:
- CentOS:
service httpd restart
- Ubuntu:
service apache2 restart
If you use nginx or Varnish, continue with the following sections.
- CentOS:
nginx only
If you use nginx, use our included nginx.conf.sample
or add a timeout settings in the nginx host configuration file to the location ~ ^/setup/index.php
section as follows:
location ~ ^/setup/index.php { ..................... fastcgi_read_timeout 600s; fastcgi_connect_timeout 600s; }
Restart nginx: service nginx restart
Varnish only
If you use Varnish, edit default.vcl
and add a timeout limit value to the backend
stanza as follows:
backend default { ..................... .first_byte_timeout = 600s; }
Restart Varnish.
service varnish restart
2. Cannot install using nginx
If you use the nginx web server and you attempt to install the Magento software, the installation sometimes fails.
Detail
You can confirm the issue by the following error in the var/report
directory:
NOTE: You cannot install Magento using the Setup Wizard because the Magento setup directory cannot be accessed. You can install Magento using either the command line or you must restore access to the following directory: /var/www/html/setup If you are using the sample nginx configuration, please go to http://ce.mtf03.bcn.magento.com/setup/";i:1;s:641:"#0 /var/www/html/lib/internal/Magento/Framework/App/Http.php(213): Magento\Framework\App\Http->redirectToSetup(Object(Magento\Framework\App\Bootstrap), Object(Exception))
Workaround
Append /setup
to the URL by which you access the Setup Wizard or install the Magento software using the command line.
3. During installation, fatal PDO error displays
Details
PHP Fatal error: Class 'PDO' not found in /var/www/html/magento2/setup/module/Magento/Setup/src/Module/Setup/ConnectionFactory.php on line 44
Solution:
Make sure you installed all required PHP extensions (CentOS, Ubuntu).
4. During installation, Reflection Exception error
Details
During the installation, a message similar to the following displays:
[ERROR] exception 'ReflectionException' with message 'Class Magento\Framework\StoreManagerInterface does not exist' in /<path>/lib/internal/Magento/Framework/Code/Reader/ClassReader.php
Solution
Clear all directories and files under Magento’s var
subdirectory and install the Magento software again.
As the Magento file system owner or as a user with root
privileges, enter the following commands:
cd <your Magento install directory>/var rm -rf cache/* di/* generation/* page_cache/*
5. Download fails because of changes in Composer
Symptom
During download, the following error displays:
[ErrorException] file_get_contents(app/etc/NonComposerComponentRegistration.php): failed to open stream: No such file or directory
Description
This happens because of changes in certain versions of Composer.
The workaround is to downgrade Composer to an earlier version and try your Magento download again.
Any version of Composer dated between November 21 and November 26, 2015 has this issue. To confirm this issue is related to the Composer version, enter the following command:
composer -v
The version displays similar to the following:
Composer version 1.0-dev (2b14f0a047dd4f3545ec82381f65c36ea93a4c81) 2015-11-25 17:13:09
Note the date is 2015-11-25, which indicates Composer has this issue.
To work around it:
-
Change your version of Composer to enable you to download the Magento software by doing any of the following:
-
Downgrade Composer using the following command:
composer self-update 1.0.0-alpha11
-
Upgrade Composer to a version later than November 26, 2015:
composer self-update
-
- Delete your Magento 2 directory and subdirectories.
- Try the download again using either
composer create-project
orgit clone
. -
After successfully downloading the Magento software, update Composer:
composer self-update