Skip to main content

Composer

Update Magento Module in production mode steps

Backup your website: Before making any changes, it is essential to create a backup of your Magento 2 installation, including the database and files. This backup will serve as a safety net in case anything goes wrong during the update process.

Enable maintenance mode: Enable maintenance mode on your Magento 2 website. This will display a maintenance page to visitors while you perform the update, preventing any potential issues or disruptions.

Magento 2 Allowed Memory exhausted error when compile code

you need to increase the memory_limit in php.ini

and as a quick solution you can use these commands directly in the command line

 

php -dmemory_limit=5G bin/magento setup:di:compile

and 

php -dmemory_limit=5G bin/magento setup:static-content:deploy

 

 

another code for the composer update

php -dmemory_limit=5G composer.phar update

php -d memory_limit=-1 /usr/local/bin/composer update