WordPress.org

Ready to get started?Download WordPress

Forums

Locked out of Backend (13 posts)

  1. smartrel8nships
    Member
    Posted 1 year ago #

    I can't get into the admin backend after upgrading. The log-in screen redirects to 'http://www.smartrelationships.org/wp-admin/upgrade.php?_wp_http_referer=%2Fwp-admin%2F' where I get a nice message saying "WordPress has been updated! Before we send you on your way, we have to update your database to the newest version. The update process may take a little while, so please be patient." If I click on the button that says "Update", I'm redirected to 'http://www.smartrelationships.org/wp-admin/upgrade.php?step=1&backto=%2Fwp-admin%2F' which is a nice blank screen with WP logo at the top. I have tried renaming my theme and my plugin folders, but it still takes me through the same dead loop. The site is still functioning fine, but I can't get into the dashboard.

    Any suggestions?

  2. johnfotios
    Member
    Posted 1 year ago #

    I wonder if it has anything to do with the permissions. Try changing your root directory to 777 and try the update again, maybe WordPress using the nobody account can't do what it wants to do. I don't know really.

  3. johnfotios
    Member
    Posted 1 year ago #

    Another thought, do you have a backup of wp-config.php and htacccess from before the update?

  4. smartrel8nships
    Member
    Posted 1 year ago #

    I have a backup. htaccess is still a 2012 version, so it wasn't updated. wp-config.php is dated 2011. This is from looking at the files via FTP.

  5. johnfotios
    Member
    Posted 1 year ago #

    Upload those to root and overwrite the current ones... Backup the new ones though!

  6. smartrel8nships
    Member
    Posted 1 year ago #

    Okay, where would I get a better version of those files to overwrite?

  7. If you're looking to replace wp-config.php with a new one, you can rename wp-config-sample.php. Your .htaccess file is usually generated via Settings > Permalinks unless you have custom stuff in there.

  8. smartrel8nships
    Member
    Posted 1 year ago #

    Thanks for your patience with a newbie. I can rename and upload the wp-config-sample.php. Can I just move the .htaccess file somewhere else and let it automatically be generated? Since I'm locked out of the backend I can't see the menu you're referencing.

  9. If you're still locked out of the backend, try just renaming your existing .htaccess file to something like OLD.htaccess. This would also go for if you have an .htaccess file located in your wp-admin directory.

  10. smartrel8nships
    Member
    Posted 1 year ago #

    Okay, I now know that the issue which causes me to be locked out is the table prefix line in the wp-config file. When that's set to the default _WP, it thinks this is a brand new site and completes the update for me. And my entire web site disappears. When it's set to the real table prefix it locks me into the loop again.

    Where can I go from here?

  11. smartrel8nships
    Member
    Posted 1 year ago #

    And a new development - I renamed OLD.htaccess back to .htaccess and tried to let WP complete the update again. This time instead of the grey screen I got:

    "Internal Server Error
    The server encountered an internal error or misconfiguration and was unable to complete your request.
    Please contact the server administrator and inform them of the time the error occurred, and anything you might have done that may have caused the error.
    More information about this error may be available in the server error log.
    Apache Server at http://www.smartrelationships.org Port 80"

  12. johnfotios
    Member
    Posted 1 year ago #

    It's a nightmare this one tbf. Any chance of starting a fresh install of WordPress or do you have a million pages/posts? :P

  13. smartrel8nships
    Member
    Posted 1 year ago #

    I can't do a reinstall. I have weveral years of posts, and this is my company page. I think this must be the section of code from upgrade.php that is causing my problem. Any advice on how I can modify it to let me back in? I'm not a programmer.

    ?>
    <?php else :
    switch ( $step ) :
    	case 0:
    		$goback = stripslashes( wp_get_referer() );
    		$goback = esc_url_raw( $goback );
    		$goback = urlencode( $goback );
    ?>
    <h2><?php _e( 'Database Update Required' ); ?></h2>
    <p><?php _e( 'WordPress has been updated! Before we send you on your way, we have to update your database to the newest version.' ); ?></p>
    <p><?php _e( 'The update process may take a little while, so please be patient.' ); ?></p>
    <p class="step"><a>"><?php _e( 'Update WordPress Database' ); ?></a></p>
    <?php
    		break;
    	case 1:
    		wp_upgrade();
    
    			$backto = !empty($_GET['backto']) ? stripslashes( urldecode( $_GET['backto'] ) ) : __get_option( 'home' ) . '/';
    			$backto = esc_url( $backto );
    			$backto = wp_validate_redirect($backto, __get_option( 'home' ) . '/');
    ?>


    [Please use the code button or backticks when posting code]

Topic Closed

This topic has been closed to new replies.

About this Topic