简体   繁体   中英

500 internal server error on laravel?

I made a project in laravel and when I migrated to a live server it gives me 500 internal error.

This is the first time I try to install laravel.

The problem occurs when I run rm -rf public_html AND ln -s laravel/public/ public_html

This is the error log:

[Sat Nov 08 12:57:46 2014] [notice] Apache/2.2.29 (Unix) mod_ssl/2.2.29 OpenSSL/1.0.1e-fips mod_bwlimited/1.4 configured -- resuming normal operations
[Sat Nov 08 12:58:01 2014] [error] [client IP ADDRESS ] SoftException in Application.cpp:357: UID of script "/home/%STACK%/public_html/index.php" is s$
[Sat Nov 08 12:58:01 2014] [error] [client IP ADDRESS ] Premature end of script headers: index.php
[Sat Nov 08 12:58:01 2014] [error] [client IP ADDRESS ] SoftException in Application.cpp:357: UID of script "/home/%STACK%/public_html/index.php" is s$
[Sat Nov 08 12:58:01 2014] [error] [client IP ADDRESS ] Premature end of script headers: index.php
[Sat Nov 08 13:03:27 2014] [error] [client IP ADDRESS ] SoftException in Application.cpp:357: UID of script "/home/%STACK%/public_html/index.php" is s$
[Sat Nov 08 13:03:27 2014] [error] [client IP ADDRESS ] Premature end of script headers: index.php
[Sat Nov 08 13:03:27 2014] [error] [client IP ADDRESS ] File does not exist: /home/%STACK%/public_html/500.shtml
[Sat Nov 08 13:07:00 2014] [error] [client IP ADDRESS ] SoftException in Application.cpp:357: UID of script "/home/%STACK%/public_html/index.php" is s$
[Sat Nov 08 13:07:00 2014] [error] [client IP ADDRESS ] Premature end of script headers: index.php
[Sat Nov 08 13:07:00 2014] [error] [client IP ADDRESS ] File does not exist: /home/%STACK%/public_html/500.shtml
[Sat Nov 08 13:09:02 2014] [error] [client IP ADDRESS ] SoftException in Application.cpp:357: UID of script "/home/%STACK%/public_html/index.php" is s$
[Sat Nov 08 13:09:02 2014] [error] [client IP ADDRESS ] Premature end of script headers: index.php

Change the permissions of your app/storage folder to 755 if that doesn't works change it to 777. If you are running nginx on the server check /etc/nginx/nginx.conf file and check the first which states the user running nginx and then

chown -R www-data:www-data /your/document/root/public_html/

change www-data by the user name you found in config file you can also validate it by running ps on terminal

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM