Composer PHP Fatal error: Allowed memory size

Source: Internet
Author: User


The detailed error message is as follows:

$ Composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
PHP Fatal error: Allowed memory size of 536870912 bytes exhausted
(Tried to allocate 32 bytes) in phar: // usr/local/Cellar/composer/
1.0.0-alpha8/libexec/composer. phar/src/Composer/DependencyResolver/
Rule. php on line 62
 
Fatal error: Allowed memory size of 536870912 bytes exhausted
(Tried to allocate 32 bytes) in phar: // usr/local/Cellar/composer/
1.0.0-alpha8/libexec/composer. phar/src/Composer/DependencyResolver/
Rule. php on line 62
I always thought it was the network reason. Recently, the network connected to foreign countries was not very stable. Later, according to the error message Allowed memory size of 536870912 bytes exhausted, I was prompted to know that the memory allocation may be insufficient, we all know that in the PHP configuration file php. in ini, memory_limit is set to limit the memory for script running. This problem can be solved by increasing the value.


Memory_limit = 1G
Of course, you may not like modifying the configuration file php. ini at will. In the post "Composer update runs out of memory #1898", Dynom provides a temporary solution:

Php-dmemory_limit = 1G composer. phar update

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.