While PHP tries to process a large database record, or when importing or exporting a database getting error as below:
Fatal error: Allowed memory size of 12582912 bytes exhausted (tried to allocate 23456789 bytes) in somefile.php
Fatal Error: PHP Allowed Memory Size Exhausted
We are getting this error due to insufficient memory size. We can increase the memory limit through php.ini file.
To fix the problem, please modify the memory_limit line in php.ini to match this example:
Step 1: Login to the cPanel and go to file Manager.
Step 2: Create a file named info.php and check the memory limit.
Step 3: If it is 64MB, then go to php.ini file and then change it to 256M
according to the memory availability.