Fatal Error: Allowed Memory Size of 134217728 Bytes Exhausted error in my web application, while accessing a page. To solve this issue, we have to do a configuration change in php.ini of our web server.
Follow these steps to update memory limit to resolve this error from the Mac/Ununtu terminal:
- Determine PHP version from terminal
RUN: php -v
- Navigate to php.ini file
REFERENCE: nano /etc/php/{PHP_VERSION}/php.ini
RUN: nano /etc/php/8.3/php.ini
- Use up and down arrows to locate memory storage and update storage allocation (this was surprisingly far down) memory_limit = 128M
Update to 256M
- Save and exit php.ini
Ctrl + O to save changes in nano
Enter to save to file
Ctrl + X to exit
This resolved this error for me! Hope this helps
No comments:
Post a Comment