The MU forums have moved to WordPress.org

Permission Error After MU Upgrade (7 posts)

  1. johnsee
    Member
    Posted 14 years ago #

    I've just finished an upgrade from one of the early version 2's (pre auto upgrade feature). All blogs are working fine, but when the admin user attempts to login the following error is returned:

    'You don’t have permission to view this blog. Please contact the system administrator.'

    It is a Wordpress error page, not an apache or php error etc.

    '?c=5' is also appended to the URL.

    A google of the error message amazingly doesn't return a single result :(

    Other users can login and access their dashboards ok.

    Any ideas?

  2. andrea_r
    Moderator
    Posted 14 years ago #

    "I've just finished an upgrade from one of the early version 2's (pre auto upgrade feature)"

    So... 2.6.5?

    Did you go straight to 2.8.3? I'm guessing that's why.

    Can you as site admin login to the backend of the sub-blogs? What's the error logs say? Did you turn off all the plugins?

  3. johnsee
    Member
    Posted 14 years ago #

    I get the same error trying to log into another users blog.

    All plugins have been turned off.

    [09-Aug-2009 22:59:16] WordPress database error Table 'lsd_wpmu.wp_39_terms' doesn't exist for query SELECT t.*, tt.* FROM wp_39_terms AS t INNER JOIN wp_39_term_taxonomy AS tt ON tt.term_id = t.term_id INNER JOIN wp_39_term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id WHERE tt.taxonomy IN ('category') AND tr.object_id IN (3) ORDER BY t.name ASC made by require, require_once, include, the_category, get_the_category_list, get_the_category, wp_get_object_terms

    That is what is being thrown up in the error logs.

    I checked the database and the following wp_39 tables DO exist:

    wp_39_comments
    wp_39_links
    wp_39_options
    wp_39_postmeta
    wp_39_posts
    wp_39_referer_blacklist
    wp_39_referer_visitLog
    wp_39_sk2_logs
    wp_39_sk2_spams
    wp_39_terms
    wp_39_term_relationships
    wp_39_term_taxonomy

  4. johnsee
    Member
    Posted 14 years ago #

    Andrea, any ideas which file generates the permission error? Might allow me to backtrack to my problem

  5. DeannaS
    Member
    Posted 14 years ago #

    The problem is that you don't have a primary_blog assigned to you as a user. Take a look at this trac ticket:

    http://trac.mu.wordpress.org/ticket/1076.

    If you apply this patch:
    http://trac.mu.wordpress.org/attachment/ticket/1076/1076_fix_existing.patch (referenced in the above ticket), it should get you to where you can at least log in.

    You can also go directly into the database and give the site admin user a primary_blog user meta field. That will allow the site admin to log in, but you'd have to repeat for all the other users.

    You can also dig through the intermediary upgrade scripts and find the script that ran that would have given everyone that user_meta field.

  6. johnsee
    Member
    Posted 14 years ago #

    Cheers DeannaS

    I applied both those patches.

    I have now set user in both wp_usermeta and wp_1_usermeta to have:

    wp_1_user_level as 10
    wp_1_capabilities as a:1:{s:13:"Administrator";b:1;} (This was its current setting)
    primary_blog as 1

    This still didn't help. I then changed 'Administrator' to 'administrator' in wp_1_capabilities, and its has sort of fixed the problem. These users have all the features they should, however can't do anything MU related, like view all blogs, edit MU settings etc.

    What are the possible values that can be set for wp_1_capabilities?

  7. iolaire
    Member
    Posted 14 years ago #

About this Topic