I just can\'t solve this one.
I\'m on Linode 1G RAM basic plan. Trying to install a package via Composer and it\'s not letting me. My memory limit is set to \"-1\" o
A bit old but just in case someone new is looking for a solution, updating your PHP version can fix the issue.
Also you should be committing your composer.lock file and doing a composer install on a production environment which is less resource intensive.
More details here: https://github.com/composer/composer/issues/1898#issuecomment-23453850
Please disable js bundling and increase memory. That should fix it. I fixed mine by disabling js bundling.
Thanks
I had a similar issue on the cheapest server (512MB RAM) hosted with DigitalOcean, and I was also running Jenkins CI on the same server. After I stopped the Jenkins instance the composer install command worked (well, to a point, it failed with the mcrypt extension missing besides already being installed!).
Maybe if you have another app running on the server, maybe its worth trying to stop it and re-running the command.
Try this:
/bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024
/sbin/mkswap /var/swap.1
/sbin/swapon /var/swap.1
This work for me on Centos 6
I get into this situation most of the times so normally i used to follow the step of setting the swap memory.
But now i found a simple alternate trick which worked for me.
Run
composer update --no-dev
Other than composer update
Looks like you runs out of swap memory, try this
/bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024
/sbin/mkswap /var/swap.1
/sbin/swapon /var/swap.1
as mentioned by @BlackBurn027 on comments below, this solution was described in here