I'm receiving the following error when I visit any term link (term view page /taxonomy/term/%):

Fatal error: Maximum execution time of 30 seconds exceeded in /srv/www/html/drupal/includes/database/database.inc on line 2139

I'm only getting this error when when logged in as a non-admin. My admin account does not experience this issue. One might think this is a permission issue or a redirect conflict, but there isn't any permission issue that I can find. I'm not using the taxonomy access module. I'm also not aware of any redirect looping.

There isn't any log activity to give me any clues as to what might be the issue. All I can see is that apache is busy.

I experimented with extending the max_execution_time to 180 seconds to see if this would help but it doesn't. The error may change slightly but only with the file and line it times out on. The maximum execution is always reached. So the error file and line aren't really any indication of what is going wrong.

I'm running Drupal 7.21
PHP 5.3.3
PHP memory limit: 256M

I believe have sufficient memory so I'm not sure what else to try. I'm not even sure if this is a views issue or a core taxonomy issue. If anyone has any possible solutions, or can point me in the right direction I would greatly appreciate it.

Comments

scottAtRoot802’s picture

Project: Views (for Drupal 7) » Organic groups
Version: 7.x-3.5 » 7.x-1.5
Component: taxonomy data » og-field-access
Priority: Major » Normal

I believe I figured out the issue with the term page, at least I figured out what was happening. The field for the terms wasn't visible to non-mebers because the OG field permissions for the term field were not allowed. Once I made the term field for non-members visible I was able to view the term page.

Now it makes sense why non-members couldn't see a term. What remains an issue is how the OG Field Access module handles the permission failure. It should send you to the Access Denied page, instead of creating a php failure.

scottAtRoot802’s picture

Project: Organic groups » Organic groups moderation
Version: 7.x-1.5 » 7.x-1.0
Component: og-field-access » Code
Priority: Normal » Major

After further review, I was able to track this issue back to OG Moderation. There is recursive looping starting with the og_moderation_node_grants function. The following is the sequence of function calls in the loop.

  • og_moderation_node_grants
  • og_user_access
  • og_get_user_roles
  • og_is_group_default_access
  • OgGroup::getEntity
  • entity_load
  • DrupalDefaultEntityController::load
  • NodeController::attachLoad
  • DrupalDefaultEntityController::attachLoad
  • call_user_func_array
  • og_moderation_node_grants

After disabling OG Moderation, the recursion stopped and the term page loaded as expected. Any help with how to stop the recursion would be appreciated.

scottAtRoot802’s picture

Title: Term Page Error - Maximum execution time of 30 seconds exceeded » Recursion Error - Maximum execution time exceeded

Update the title to more accurately describe the issue.

shenzhuxi’s picture

Issue summary: View changes
Status: Active » Closed (won't fix)

There will not be OG 7.x-1.x releases in the future, so we stopped supporting og_moderation 7.x-1.x.
If there is a patch, I'd like to apply.