Webkul
Services
Technologies Bagisto QloApps
iOS Android SAP BigCommerce Wix
Trusted by
Samsung Intel Toyota Walmart Disney Nokia Nestlé Decathlon
See all customers
Back to Top
DOC

Fix Allowed Memory Exhausted Error When Compile Code In Magento 2

Fix Allowed Memory Exhausted Error When Compile Code In Magento 2 :-  Sometimes when we execute compile  or deploy command it gives allowed memory size exhausted error.

<span class="typ">Fatal</span><span class="pln"> error</span><span class="pun">:</span> <span class="typ">Allowed</span><span class="pln"> memory size of </span><span class="lit">134217728</span><span class="pln"> bytes exhausted </span>

To fix this issue you need to increase memory allocated to php. To increase memory limit you have to set memory_limit parameter to 256M or 512M in php.ini file.

Or for quick solution add memory limit in the command :

php -d memory_limit=1G bin/magento setup:di:compile

php -d memory_limit=1G bin/magento setup:static-content:deploy

Hope so it will help you.

. . .

Leave a Comment

Your email address will not be published. Required fields are marked*


1 comments

  • Bhupendra Mehra
  • Back to Top

    Message Sent!

    If you have more details or questions, you can reply to the received confirmation email.

    Back to Home