Answer the question
In order to leave comments, you need to log in
Increase maximum memory for composer?
Composer version 1.8.0
How to increase the amount of allowed memory for consumption.
Crashes into a fatal error during installation.
Tried:
export COMPOSER_MEMORY_LIMIT=-1
in php.ini set memory_limit
php -d memory_limit=512M /usr/local/bin/composer install
Still throws an error:
composer install
Loading composer repositories with package information
Updating dependencies (including require-dev)
mmap() failed: [12] Cannot allocate memory
mmap() failed: [12] Cannot allocate memory
mmap() failed: [12] Cannot allocate memory
PHP Fatal error: Out of memory (allocated 638590976) (tried to allocate 67108872 bytes) in phar:///usr/local/bin/composer/src/Composer/DependencyResolver/RuleSet.php on line 84
Fatal error: Out of memory ( allocated 638590976) (tried to allocate 67108872 bytes) in phar:///usr/local/bin/composer/src/Composer/DependencyResolver/RuleSet.php on line 84
Answer the question
In order to leave comments, you need to log in
Your problem is not in the limits, but in the lack of memory as such. You can get around the problem by connecting swap, for example, in the form of a file.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question