Changes between Initial Version and Version 1 of Other_Issues

08/06/10 13:45:15 (10 years ago)
fabio.batalha (IP:



  • Other_Issues

    v1 v1  
     1= Other issues = 
     3== Allowed memory size exceeded ==  
     5Required for installation: YES 
     7By default, PHP is usually installed with a memory limit of 16MB that any PHP script may consume. working to get this below 32MB. 
     9Sample error message 
     11Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 16 bytes) in /home/jamilatta/project/submission/htdocs/classes/xml/ on line 42 
     13=== Solutions === 
     15On a hosted server, no root access 
     17Ask your hosting provider to increase PHP's allowed memory size to 64MB or more. 
     19=== Local php.ini file === 
     21Some web hosts allow placing a php.ini file in your local web directory to override the default site settings. 
     23memory_limit = 64M; 
     25On a personal web server, a VPS, or a shared server with root access 
     27   1. Locate the php.ini file used by your web server: 
     28          * On a linux system you can try the commands: 
     30            $ locate php.ini 
     32            or 
     34            $ find / -name php.ini 
     36          * You may find several php.ini files, you want to edit the file in the cgi or apache directory (depending on whether PHP is running as a CGI or mod_php). 
     37          * You can also use phpinfo() in a file to display a list of php.ini settings, including the current location of your php.ini file. 
     38   2. Open your php.ini file with your favorite text editor 
     39          * Make sure to open the file with su privileges (use sudo if avaiable) 
     40   3. Edit the line below and set the memory limit to 64M: 
     42      memory_limit = 64M      ; Maximum amount of memory a script may consume (16MB) 
     44   4. Save your changes to php.ini 
     45   5. Restart your Apache process (only necessary if PHP is running as an Apache module): 
     47      $ apache2ctl restart 
     49Resource limits section in a typical php.ini file 
     52Resource Limits 
     54max_execution_time = 30     ; Maximum execution time of each script, in seconds [[BR]] 
     55max_input_time = 60 ; Maximum amount of time each script may spend parsing request data [[BR]] 
     56;max_input_nesting_level = 64 ; Maximum input variable nesting level [[BR]] 
     57memory_limit = 32M      ; Maximum amount of memory a script may consume (16MB) [[BR]]