0

Just another Laravel 4 white screen with no clues.

My context:

  • Server CentOS 6.5
  • Apache 2.2.15
  • PHP 5.4.23
  • php mcrypt enabled
  • php log_errors working
  • Laravel fresh install: "$ laravel new project"
  • storage folder permissions 777
  • there is no laravel error log
  • there are no errors on php log
  • there are no errors on apache/httpd log

I've tried to do a "manual debug" and the app stops at start.php:

$app = new Illuminate\Foundation\Application;

Going deeper compiled.php I've lost track on the share method call:

use Illuminate\Support\ServiceProvider;
class EventServiceProvider extends ServiceProvider
{
    public function register()
    {
        $this->app['events'] = $this->app->share(function ($app) {
            return new Dispatcher($app);
        });
    }
}

EDIT

Checked same "500 Server Internal Error" using Laravel's server ($ php artisan serve).

David Gras
  • 958
  • 2
  • 12
  • 21

2 Answers2

1

If there is no error log message it's probably an error log configuration problem.

Check out all php log related params at php.ini:

log_errors = On
error_reporting = E_ALL   // or 32767
error_log = syslog        // log file, 'syslog' value usually means /var/log/messages
                          //   or /var/log/syslog

display_errors = On          // print errors on screen if you're not
display_startup_errors = On  //   in a production environment

In case you're running Apache/VirtualHost, check it out httpd.conf for an alternative log file

<VirtualHost>
    ErrorLog /var/www/example.com/error_log
</VirtualHost>
David Gras
  • 958
  • 2
  • 12
  • 21
0

Try running Laravel's server to debug possible errors in your webserver.

php artisan serve

You should have access to localhost:8000

If it does not display Laravel's splash page, then there can be a problem with Composer. If it display the splash page, it could be

  • Apache configuration
  • app/storage directory and subdirectories not being writable by PHP

Also you can check Laravel logs for errors in addition to Apache error logs

marcanuy
  • 23,118
  • 9
  • 64
  • 113
  • Thank you for your answer. Laravel's server gives me a "**500 Internal Server Error**" response. Laravel's storage/logs folder is empty. – David Gras Aug 18 '14 at 09:02
  • Have you set the permissions correctly on your index.php? – Gareth Daine Aug 18 '14 at 09:05
  • Owner, group and read permissions are correct for the whole project. Do you mean that? – David Gras Aug 18 '14 at 09:23
  • Try 755 on index.php, if that doesn't work check if mod_rewrite is enabled on the server. Can you see the start page? – Gareth Daine Aug 18 '14 at 11:22
  • Nothing changes. Yes, I have other php-simple-pages on the same server, mod_rewrite is working properly (and so the logs). In fact, I've created the Laravel project in a subfolder, that could be a problem?? – David Gras Aug 18 '14 at 17:55