开发者

Drupal: How long should it take to rebuild permissions

I have just installed the ACL and Content Ac开发者_开发知识库cess module. Imedietly after enabling them I was asked to rebuild the permissions. All perfectly normal I am told.

However, I set the 'rebuild' permissions page running about 40 minutes ago and it still says 'Initializing'. How long should it take? Am I doing something wrong?


The standard "rebuild perms" duration is roughly proportional to the number of node multiplied by the number of access modules enabled.

On a site with 100k nodes, you can easily take more than 24hours to rebuild permissions. Which means you simply don't want to do it interactively. But you can launch that rebuild from drush or use one of the faster non-standard rebuild methods.


To do it via drush, use:

drush php-eval 'node_access_rebuild();'


Just refresh the page. The perms get rebuilt in a few seconds :).


Note: If it takes you 24 hours to rebuild on a site with 100K nodes, something is wrong. It takes us about 30min on a site with 200K+ FWIW. For a smaller site it should be much less; I suspect you were experiencing an error of some kind.


A quick solution can be just change your theme back to default GARLAND theme and than try again rebuilding permissions, most probably it will work. As sometime it is JS errors which is causing it to stuck on Initialization.

And if your site has too much data (node like 100k , 200K) you can also use this script by placing it in a php file in Drupal root and running it. The code is under the heading

WSODs Due to Specific Modules -> Node Access

on this link :

http://drupal.org/node/158043

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜