After installing Magento prompt: HTTP ERROR 500, how to solve?

Source: Internet
Author: User
Tags php error php error log magento2
I installed Magento2 on UBUNTU14, Web Access http://localhost/can show the Apache hint it work! , but http://localhost/magento2/tip http ERROR 500
I installed it by using the following command:

Apt-get updateapt-get install git wgetwget-o/usr/local/bin/composer http://getcomposer.org/composer.pharchmod +x/usr /local/bin/composercd/var/wwwgit Clone Https://github.com/magento/magento2.gitcd/var/www/magento2composer Install

After the error, I checked the PHP error log, prompting the following:

[Thu Sep 08 11:03:34.275419 2016] [: ERROR] [PID 2214] [Client 127.0.0.1:41732] PHP Fatal error:uncaught exception ' magento\framework\exception\filesystemexception ' with message ' the file '/var/www/ Html/magento2/var/.regenerate "cannot be deleted Warning!unlink (/var/www/html/magento2/var/.regenerate): Permission Denied ' In/var/www/html/magento2/vendor/magento/framework/filesystem/driver/file.php:382nstack trace:n#0/var/www /html/magento2/vendor/magento/framework/filesystem/directory/write.php (173): magento\framework\filesystem\ Driver\file->deletefile ('/var/www/html/m ... ') n#1/var/www/html/magento2/vendor/magento/framework/code/ generatedfiles.php (98): Magento\framework\filesystem\directory\write->delete ('/var/.regenerat ... ') n#2/var/ www/html/magento2/vendor/magento/framework/app/objectmanagerfactory.php (): magento\framework\code\ Generatedfiles->cleangeneratedfiles () n#3/var/www/html/magento2/vendor/magento/framework/app/bootstrap.php ( 385): Magento\framework\app\objectmanageRfactory->create (Array) n#4/var/www/html/magento2/vendor/magento/framework/app/bootstrap.php (362): Magento\ Framework\app\bootstra in/var/www/html/magento2/vendor/magento/framework/filesystem/driver/file.php on line 382

How should this situation be solved? That will allow me to install magento properly.

Reply content:

I installed Magento2 on UBUNTU14, Web Access http://localhost/can show the Apache hint it work! , but http://localhost/magento2/tip http ERROR 500
I installed it by using the following command:

Apt-get updateapt-get install git wgetwget-o/usr/local/bin/composer http://getcomposer.org/composer.pharchmod +x/usr /local/bin/composercd/var/wwwgit Clone Https://github.com/magento/magento2.gitcd/var/www/magento2composer Install

After the error, I checked the PHP error log, prompting the following:

[Thu Sep 08 11:03:34.275419 2016] [: ERROR] [PID 2214] [Client 127.0.0.1:41732] PHP Fatal error:uncaught exception ' magento\framework\exception\filesystemexception ' with message ' the file '/var/www/ Html/magento2/var/.regenerate "cannot be deleted Warning!unlink (/var/www/html/magento2/var/.regenerate): Permission Denied ' In/var/www/html/magento2/vendor/magento/framework/filesystem/driver/file.php:382nstack trace:n#0/var/www /html/magento2/vendor/magento/framework/filesystem/directory/write.php (173): magento\framework\filesystem\ Driver\file->deletefile ('/var/www/html/m ... ') n#1/var/www/html/magento2/vendor/magento/framework/code/ generatedfiles.php (98): Magento\framework\filesystem\directory\write->delete ('/var/.regenerat ... ') n#2/var/ www/html/magento2/vendor/magento/framework/app/objectmanagerfactory.php (): magento\framework\code\ Generatedfiles->cleangeneratedfiles () n#3/var/www/html/magento2/vendor/magento/framework/app/bootstrap.php ( 385): Magento\framework\app\objectmanageRfactory->create (Array) n#4/var/www/html/magento2/vendor/magento/framework/app/bootstrap.php (362): Magento\ Framework\app\bootstra in/var/www/html/magento2/vendor/magento/framework/filesystem/driver/file.php on line 382

How should this situation be solved? That will allow me to install magento properly.

Install the package under the direct official website test

Permission denied

Insufficient permissions to ensure that the./var directory is writable, preferably the owner of the directory where the project resides belongs to Apache
Chown-r Apache:apache./

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.