magento / magento2

Prior to making any Submission(s), you must sign an Adobe Contributor License Agreement, available here at: https://opensource.adobe.com/cla.html. All Submissions you make to Adobe Inc. and its affiliates, assigns and subsidiaries (collectively “Adobe”) are subject to the terms of the Adobe Contributor License Agreement.
http://www.magento.com
Open Software License 3.0
11.56k stars 9.32k forks source link

Magento 2.3.1 installation gives 500 error #22972

Closed logicallimit closed 5 years ago

logicallimit commented 5 years ago

Summary of the issue: On a new installation of Magento CE 2.3.1, I get 500 error when I access my development sub-domain.

Information on the environment: OS Name: CentOS Linux release 7.6.1810 at Digital Ocean Using Varnish Cache Server and Nginx Reverse Proxy

Steps to reproduce (*):

  1. Uploaded Magento 2.3.1 CE zipped file to development subdomain root
  2. Extracted it
  3. Accessed development subdomain URL in the browser
  4. I get 500 error on the browser as below:

    Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request.

  5. If I remove entry Options +FollowSymLinks from default .htaccess file that came in the downloaded Magento CE 2.3.1 zipped package then the Magento installation screen shows up normally.

[Wed May 22 10:49:26.533936 2019] [core:alert] [pid 21653:tid 140634820118272] [client 179.50.121.141:48721] /home/myadmin/dev.domainname.com/.htaccess: Option FollowSymLinks not allowed here

I researched a few places on internet and found people suggesting to use Options +SymlinksIfOwnerMatch instead of Options +FollowSymLinks

Preconditions (*)

  1. Apache version: Apache/2.4.39
  2. PHP version: 7.2.18
  3. MySQL version: 10.1.40-MariaDB
  4. Magento 2.3.1 CE

Expected result (*)

Following screen should be shown normally image

Actual result (*)

Following error is shown on browser image

m2-assistant[bot] commented 5 years ago

Hi @logicallimit. Thank you for your report. To help us process this issue please make sure that you provided the following information:

Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:

@magento-engcom-team give me 2.3-develop instance - upcoming 2.3.x release

For more details, please, review the Magento Contributor Assistant documentation.

@logicallimit do you confirm that you were able to reproduce the issue on vanilla Magento instance following steps to reproduce?


williankeller commented 5 years ago

Hi @logicallimit Could you share the error in your Apache logs? Otherwise, we can't understand the root cause of the error.

logicallimit commented 5 years ago

@williankeller

Following is the error log shown:

[Wed May 22 10:49:26.533936 2019] [core:alert] [pid 21653:tid 140634820118272] [client 179.50.121.141:48721] /home/myadmin/dev.domainname.com/.htaccess: Option FollowSymLinks not allowed here

I researched a few places on internet and found people suggesting to use Options +SymlinksIfOwnerMatch instead of Options +FollowSymLinks

I found such a link although not related to Magento but to Drupal suggesting same. link

m2-assistant[bot] commented 5 years ago

Hi @williankeller. Thank you for working on this issue. In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:


williankeller commented 5 years ago

Hi @logicallimit, I did some research and this is not a Magento related issue and is not reproducible. It's probably related with your CentOs server configuration. Please make sure you have the right configuration under your virtual hosts, like:

<Directory /var/www/magento>
    Options FollowSymLinks
    AllowOverride All
    Order deny,allow
    Allow from all
</Directory>

You should keep using the FollowSymLinks for security reasons and also you can face some issues with the SEO rewrite, etc.

I'm closing this ticket since the research I did shows up that might be a server configuration. You can reopen or create a new one. Thanks.