Community

recovering system after theme.inc memory issue

I am building a site using ubercart and was experiment with some grid based themes when i got:

Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 71 bytes) in includes/theme.inc on line 98

I have had these messages before on since changing hosting have been able to set php memory to 512mb in settings.php to good effect until now. I have emptied the caches in the database and tried removing themes but i can't recover the system. Any ideas? would removing some modules from the file system achieve anything?

Comments

=-=

512M is a lot of memory. How many modules are installed?

rather than deleting the folders you can disable modules manually in the system table of the database by setting the status of the module to 0

modules

just ubercart, views, panels, meta tags, link field...i think it wasnt the modules, more that i had omega, squaregrid and ninesixty...i agree 512 should be plenty. luckily i havent got too far so i can start the site again but memory is my main concern with drupal, once you are in this situation your site is essentially screwed.

=-=

once you are in this situation your site is essentially screwed.

Incorrect. if the themes are the issue they can be disabled manually in the database too. Though themes can be moved out of the folder structure. If the active default theme folder is removed, the site would appear without any styling but would still allow navigating to the admin UI. can also set the conf in settings.php to force the use of a core theme. Though it does sound odd that more than one theme within the folder structure would cause a memory issue as only one theme can be enabled as set as default at a time.

thanks

good tips. Learnt some useful stuff there, the settings.php theme settings got me back up and running.

=-=

you're welcome. Glad to be of help.