When Organic groups access control is enabled, I get a message:
"The content access permissions need to be rebuilt. Rebuild permissions."

When I attempt to rebuild permissions, I get:
An error has occurred.
Please continue to the error page
An AJAX HTTP error occurred. HTTP Result Code: 500 Debugging information follows. Path: /batch?id=733&op=do StatusText: error ResponseText:

Error Message in logs:
Notice: Undefined index: controller class in entity_get_controller() (line 7678 of /includes/common.inc).

I upgraded from OG 7.x.1.5 to OG 7.x-2.0-beta2 last week.

Comments

amitaibu’s picture

Status: Active » Fixed

You'll need to check it with re-upgrading from 1.x to 2.x using the latest --dev version of 2.x, thanks to #1795166: Improve Migration query to solve various errors

fbouzek’s picture

Worked. Had to re-upgrade to latest 7.1.x then upgrade to 7.2.x

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

scottAtRoot802’s picture

Status: Closed (fixed) » Active

I'm having the same issue. If "re-upgrade to latest 7.1.x then upgrade to 7.2.x" works, how do I go about doing this? I could override the OG module with the 7.1.x version, run update, then upgrade to 7.2.x again. However, I imagine it is not as simple as this. There were a number of steps to migrating to OG 7.2.x. How does migration factor in?

I followed the steps here:
http://drupal.org/node/1839652

skyredwang’s picture

Version: 7.x-2.0-beta2 » 7.x-2.0-beta4
Category: support » bug

tested 7.x-2.0-beta4 and latest 7.x-2.x-dev. This error is still there.

BrightBold’s picture

Did everyone's migration complete successfully? I was also getting an AJAX error when attempting to rebuild permissions. I realized that the migration from 1.x to 2.x hadn't completed: 6 of the OGMigrateMembership rows had failed and then OgMigrateRoles wasn't running due to a dependency on OgMigrateMembership. (Side note: I hadn't noticed this because the error message appeared in the same "messages status" div as the successful portion, rather than in a messages div with the "error" class. So I confess I failed to notice the error because it was in a big green box with a checkmark!)

In the database, I could see a number of og_membership rows that were attached to deleted groups. I deleted those rows and re-ran the migration, hoping that would allow the migration to complete successfully. It didn't, so then I checked the option to ignore dependencies, and the OgMigrateRoles completed successfully. After that, I was able to rebuild permissions without an error.

Jan-E’s picture

@BrightBold: I had troubles that my OgUiSetRoles did not migrate (the failure was hidden in green content). I solved that by clicking the "Register" button at admin/content/migrate/registration. Only after this action OgMigrateMembership, OgMigrateRoles and OgMigrateUserRoles appeared in my migrate-list. I had to migrate those first and then in a second pass OgUiSetRoles would migrate as well.
When averything was migrated, I could also rebuild the permissions without getting AJAX HTTP errors.

BrightBold’s picture

Hmm. When I click "Register" I get "The website encountered an unexpected error. Please try again later" and now I also get that error when I attempt to visit the main Migrate page. So I hope I haven't broken something.

I think my migration was failing due to an issue someone else had identified with the number of rows being reported incorrectly, so my belief/hope is that everything did migrate successfully.

sparker888’s picture

Any luck with this issue? I've just run into the same problems myself.

Edit: Upgraded to og-7.x-2.x-dev and AJAX error persisted. Uninstalled Organic groups access control and the error was gone and the permissions table was rebuilt. Fortunately I do not need og access control, so this solved this issue for me. However it appears there is still an issue with the module as of this date.

rv0’s picture

I had a similar issue due to some rows in og_membership table not having a group type / field_name

UPDATE `og_membership` SET group_type = 'node', field_name = 'og_group_ref' WHERE group_type = ''
UPDATE `og_membership` SET group_type = 'node', field_name = 'og_group_ref' WHERE group_type LIKE '0'

this helped/fixed it in my case, but don't blindly enter this without knowing what and why you are doing it!

bryancasler’s picture

Running into a similar problem. Had to disable Organic Groups Access Control all together. Searching my DB broadly for even a reference like %og_access% turns up nothing useful. Thoughts? Not even sure how that's possible, but I did upgrade from D6->D7 and have had problems for over a year with oddball OG bugs.

mradcliffe’s picture

Ran into this with version 7.x-2.6, but did not encounter the issue with 7.x-2.x today.