I have a problem with Laravel . after restart my system, My project will not run !!!
I run with php artisan serv
, but I have below messages in console :
[Tue Jul 3 14:31:35 2018] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /laravel-projects/blog/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php on line 122
[Tue Jul 3 14:31:35 2018] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /laravel-projects/blog/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php on line 46
[Tue Jul 3 14:31:38 2018] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /laravel-projects/blog/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php on line 122
[Tue Jul 3 14:31:39 2018] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /laravel-projects/blog/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php on line 46
[Tue Jul 3 14:31:39 2018] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /laravel-projects/blog/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php on line 122
Before the system was restored, the project was well implemented !!
This means you need to also update your php.ini memory_limit
directive.
Try put in your php.ini :
memory_limit=1024M and restart apache :
sudo systemctl restart httpd.service
Change in php.ini
which is there inside apache2
folder
memory_limit=1024M
restart apache2
you can even check which php ini config is using by:
php -i | grep "php.ini"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With