CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • WSOD on module list page when I enable CiviCRM
Pages: [1]

Author Topic: WSOD on module list page when I enable CiviCRM  (Read 1994 times)

adshill

  • I post occasionally
  • **
  • Posts: 96
  • Karma: 8
WSOD on module list page when I enable CiviCRM
July 23, 2009, 11:06:38 am
I'm getting the following errors that produce WSOD:

[23-Jul-2009 09:44:40] PHP Fatal error:  Out of memory (allocated 1031536640) (tried to allocate 79 bytes) in /home/xxxxx/public_html/sites/all/modules/civicrm/CRM/Core/Error.php on line 393
[23-Jul-2009 09:45:30] PHP Fatal error:  Out of memory (allocated 1031536640) (tried to allocate 35 bytes) in /home/xxxxx/public_html/sites/all/modules/civicrm/CRM/Core/Error.php on line 385

On the drupal admin/build/modules page. When I disable Civi it goes away. Seems to work fine on my local copy. The site is the only site on a 1.6Ghz server with 2Gb RAM. I have about 25 other drupal contribs there. Is it really possible that I have run out of memory just due to the number/type of modules or is there something causing mischief here...? Every other page on the site runs smoothly...

Any ideas much appreciated as its a nightmare having to disable Civi in order to enable/disable others.

Grazi e ciao :)

Adam

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: WSOD on module list page when I enable CiviCRM
July 23, 2009, 05:50:57 pm

so seems like u've allocated a LOT of memory (983M or so) before it complains. Civi is a memory hog (admittedly), but even by its lax standards thats a lot of memory :(

i would check how much memory is used by all other drupal modules minus civicrm (use devel module). then add civicrm and see how much more is added. also ensure u dont enable the civicrm related modules (like group_roles etc), so do it one at a time. seems like some code out there is using up a lot of memory (i.e. a bug)


lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

adshill

  • I post occasionally
  • **
  • Posts: 96
  • Karma: 8
Re: WSOD on module list page when I enable CiviCRM
July 24, 2009, 09:33:41 am
Thanks Lobo,

Unfortunately, the Devel module also uses a lot of memory which makes installing/using it a bit difficult!! But will continue with your guidance to try and find the culprit. We have 1024 Memory allocated so can't get more than that!

Thanks,

Adam

adshill

  • I post occasionally
  • **
  • Posts: 96
  • Karma: 8
Re: WSOD on module list page when I enable CiviCRM
July 28, 2009, 03:19:53 pm
Hmmm... very strange. This went from being a slight issue on one page to us receiving many "Page not found" errors and huge amount of Warning: MySql has gone away errors, to the current issue. We found the culprit but are not sure what is causing it, however it is definately something concerning CiviCRM:

# User@Host: annalin1_civicrm[annalin1_civicrm] @ localhost []
# Query_time: 48655 Lock_time: 0 Rows_sent: 0 Rows_examined: 569325668
SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact `civicrm_group_contact-10` ON contact_a.id = `civicrm_group_contact-10`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-11` ON contact_a.id = `civicrm_group_contact-11`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-12` ON contact_a.id = `civicrm_group_contact-12`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-13` ON contact_a.id = `civicrm_group_contact-13`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-14` ON contact_a.id = `civicrm_group_contact-14`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-15` ON contact_a.id = `civicrm_group_contact-15`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-16` ON contact_a.id = `civicrm_group_contact-16`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-17` ON contact_a.id = `civicrm_group_contact-17`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-18` ON contact_a.id = `civicrm_group_contact-18`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-19` ON contact_a.id = `civicrm_group_contact-19`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-20` ON contact_a.id = `civicrm_group_contact-20`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-21` ON contact_a.id = `civicrm_group_contact-21`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-22` ON contact_a.id = `civicrm_group_contact-22`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-5` ON contact_a.id = `civicrm_group_contact-5`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-6` ON contact_a.id = `civicrm_group_contact-6`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-7` ON contact_a.id = `civicrm_group_contact-7`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-8` ON contact_a.id = `civicrm_group_contact-8`.contact_id LEFT JOIN civicrm_group_contact `civicrm_group_contact-9` ON contact_a.id = `civicrm_group_contact-9`.contact_id WHERE ( ( `civicrm_group_contact-5`.group_id IN ( 5 ) AND `civicrm_group_contact-5`.status IN ("Added") ) OR ( `civicrm_group_contact-6`.group_id IN ( 6 ) AND `civicrm_group_contact-6`.status IN ("Added") ) OR ( `civicrm_group_contact-7`.group_id IN ( 7 ) AND `civicrm_group_contact-7`.status IN ("Added") ) OR ( `civicrm_group_contact-8`.group_id IN ( 8 ) AND `civicrm_group_contact-8`.status IN ("Added") ) OR ( `civicrm_group_contact-9`.group_id IN ( 9 ) AND `civicrm_group_contact-9`.status IN ("Added") ) OR ( `civicrm_group_contact-10`.group_id IN ( 10 ) AND `civicrm_group_contact-10`.status IN ("Added") ) OR ( `civicrm_group_contact-11`.group_id IN ( 11 ) AND `civicrm_group_contact-11`.status IN ("Added") ) OR ( `civicrm_group_contact-12`.group_id IN ( 12 ) AND `civicrm_group_contact-12`.status IN ("Added") ) OR ( `civicrm_group_contact-13`.group_id IN ( 13 ) AND `civicrm_group_contact-13`.status IN ("Added") ) OR ( `civicrm_group_contact-14`.group_id IN ( 14 ) AND `civicrm_group_contact-14`.status IN ("Added") ) OR ( `civicrm_group_contact-15`.group_id IN ( 15 ) AND `civicrm_group_contact-15`.status IN ("Added") ) OR ( `civicrm_group_contact-16`.group_id IN ( 16 ) AND `civicrm_group_contact-16`.status IN ("Added") ) OR ( `civicrm_group_contact-17`.group_id IN ( 17 ) AND `civicrm_group_contact-17`.status IN ("Added") ) OR ( `civicrm_group_contact-18`.group_id IN ( 18 ) AND `civicrm_group_contact-18`.status IN ("Added") ) OR ( `civicrm_group_contact-19`.group_id IN ( 19 ) AND `civicrm_group_contact-19`.status IN ("Added") ) OR ( `civicrm_group_contact-20`.group_id IN ( 20 ) AND `civicrm_group_contact-20`.status IN ("Added") ) OR ( `civicrm_group_contact-21`.group_id IN ( 21 ) AND `civicrm_group_contact-21`.status IN ("Added") ) OR ( `civicrm_group_contact-22`.group_id IN ( 22 ) AND `civicrm_group_contact-22`.status IN ("Added") ) );

The important point being: Query_time: 48655

Any reason why its taking this long?! Thanks,

Adam

alfred_nutile

  • Ask me questions
  • ****
  • Posts: 464
  • Karma: 14
    • River Valley Tech Collective
Re: WSOD on module list page when I enable CiviCRM
July 29, 2009, 05:07:16 am
make sure you devel modules is not set to track and show everything.
Also make sure the theme developer modules is disabled. (it can be set to on in drupal modules but off in the devel area)

Or just turn off devel for a moment to see if it is is tracking too much info.
I use both together but I have a limited amount of features turned on.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: WSOD on module list page when I enable CiviCRM
July 29, 2009, 06:33:27 am

1. are you using acl's?

2. that looks like a search query which checks for membership in a contact in multiple groups (and not efficiently constructed either). not sure why its running on the admin pages? is there any other modules u r using that interact with civicrm?

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

adshill

  • I post occasionally
  • **
  • Posts: 96
  • Karma: 8
Re: WSOD on module list page when I enable CiviCRM
July 30, 2009, 04:03:07 am
Thanks for your help,

Lobo in answer to your questions: 1) Yes, extensively 2) Yes, it seems this is where the issue has come from.

We disabled our contributed module, devel module, dblog module on drupal and then enabled civicrm and things seem to be working ok. So I think our contrib is the problem - we're looking into this now.

However, we now have another strange issue - when we enable the civicrm module, the "Who's online" block (also featured in the admin_menu module) shows an increasing number of guest visitors. This number increases with page visits. When we deactivate civicrm then the number goes back down to something more realistic.

While I guess this is not a major issue, its a bit worrying in terms of performance and also this is a very useful feature of drupal.

As far as I know this number is generated from the sessions table of drupal. Is there any known conflict or reason why civicrm could affect the number of online users or do something strange with the sessions table?

Thanks again,

Adam

adshill

  • I post occasionally
  • **
  • Posts: 96
  • Karma: 8
Re: WSOD on module list page when I enable CiviCRM
August 02, 2009, 05:17:48 am
Actually this problem still exists... There is something wrong with the civicrm search which is knocking our server sideways.

A user logged in today and simply did a search and it sent our server to overload with load readings of 10+

When we disable civicrm (no contribs are now running) and restart apache then the site runs great again.

Our host is blaming the following:

+--------+------------------+-----------+------------------+---------+------+--------------+------------------------------------------------------------------------------------------------------+
| Id | User | Host | db | Command | Time | State | Info |
+--------+------------------+-----------+------------------+---------+------+--------------+------------------------------------------------------------------------------------------------------+
| 184927 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 7827 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact |
| 184983 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 7721 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact |
| 185089 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 7546 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact |
| 185213 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 7346 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact |
| 185258 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 7255 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_email ON (cont |
| 185409 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 6984 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact |
| 185450 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 6905 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact |
| 185468 | annalin1_civicrm | localhost | annalin1_civicrm | Query | 6863 | Sending data | SELECT count(DISTINCT contact_a.id) FROM civicrm_contact contact_a LEFT JOIN civicrm_group_contact |

We have around 22 groups and about 100 contacts, the civi database is less than 200kb - its all making no sense and driving me mad as it completely prohibits use of civicrm, and then the whole website.

And ideas what is causing the search queries to take so long and cause server overload? Thanks for any help!

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: WSOD on module list page when I enable CiviCRM
August 02, 2009, 07:09:38 am

1. i assume u can reproduce this easily

2. if 1 is true, any chance we can get ssh access to investigate. We'll need write access to the CiviCRM files to add a few debug statements etc. Ping kurund or me on IRC

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

adshill

  • I post occasionally
  • **
  • Posts: 96
  • Karma: 8
Re: WSOD on module list page when I enable CiviCRM
August 02, 2009, 09:54:19 am
Hi Lobo,

1) Yes I can now... just realised that the bug doesn't appear with the admin user hence why everything seemed fine to me. Logged in with a normal user and there was the crash - when I search, its triggering off some kind of loop or problem that is causing not only the page to stall and timeout, but the server's average load increases at a phenominal pace till its in the region of 11, 11, 11!!

When I add the user to the "Administrator" group, then the user is fine and can search normally. So I think somewhere in setting up my ACL groups, I've created a situation that the search query just can't handle (I can add/edit as usual) and sends MySql into crazy mode...

I'm digging deeper. I have 22 ACL's and so I think I've done something weird. Considering to build them all again from the ground up and see if that deals with it.

2) Well, this is a bit harder but I'm waiting on our hosts to get us access, I tried but it wasn't working (I'm no good with unix/code!). I'll do my best, in the meantime any suggestions on the above would be great as I feel I'm getting closer...

As always, thanks so much for you help.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: WSOD on module list page when I enable CiviCRM
August 02, 2009, 11:34:00 am

based on the behavior u describe, i'm pretty sure your acl's are causing an infinite loop within the code and hence the spike in load etc

can we get a copy of your CiviCRM DB. Also we'd need to know the acl group of the user that is causing this issue

thanx

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • WSOD on module list page when I enable CiviCRM

This forum was archived on 2017-11-26.