Running a common composer command, post an upgrade on the server to Centos 7 and I received the following error:
/usr/local/bin/composer: line 8: 6210 Killed
The "Killed" message usually means that your process consumed too much memory, so you may simply need to add more memory to your system if possible. You can increase the memory, however, note that you shouldn't be doing this action on a production server, and additionally you shouldn't be using composer update at all. Instead adopt a different that is something like:
- Run composer update in a local environment like on your physical laptop / desktop where memory limitations shouldn't be a problem;
- Upload or git push the composer.lock file;
- Run composer install on the production server;
- composer install will then read from the .lock file, fetching the exact same versions every time rather than finding the latest versions of every package. This makes your site or app less likely to break, and composer using less memory.
Read more here: https://getcomposer.org/doc/01-basic-usage.md#installing-with-composer-lock
Alternatively, you can upload the entire vendor directory to the server, bypassing the need to run composer install at all, but then you should run composer dump-autoload --optimize.