WordPress.org

Ready to get started?Download WordPress

Forums

SharDB
[resolved] Login Issue After Migration & Placement of db.php (7 posts)

  1. cmdr_riker
    Member
    Posted 1 year ago #

    okay.. i've scoured the web and google fu'd till exhaustion.

    this is all being done on my dev site (clone of production btw.)

    i've created my db's
    tried to put shardb-admin.php in mu-plugin folder - no workee sooo
    i put it in shardb-admin.php in plugins and that worked
    i ran the global migration and then sites
    that seems to run successfully...
    sooo when i move db.php to wp-content poof! i get redirected to the login screen and there's nothing in my error log or debug that seems to indicate what's going on.

    i think its not finding the right tables/blog #'s now in my sharded db

    entering my password doesn't work.. the main site has a blank screen. i've got nothing more to go on in the instructions. i am using an env.php... but everything works until i drop db.php in wp-content.

    http://wordpress.org/extend/plugins/shardb/

  2. Ron Rennick
    MultiSite Guru
    Plugin Author

    Posted 1 year ago #

    Did you edit the included db-settings.php to configure? Did you follow the instructions in the guide?

    When you install a plugin in the mu-plugins folder you don't upload the folder just the plugin file.

  3. cmdr_riker
    Member
    Posted 1 year ago #

    Yes I modified the db-settings.php to include:

    $shardb_hash_length = 1; -- because i'm using the 17 db's
    $shardb_prefix = 'shard_yorkwpms_'; -- name of my db's
    $shardb_dataset = 'milton'; -- my secret key

    i followed the instructions and placed the plugin file in my mu plugins dir and chowned them to my nginx-apache user with 775 perms.

    i ran the migration script and its seemed to populate the databases correctly
    the problem i have is when I move db.php to my wp-content folder i get stuck in a redirect loop at wp-login...

    i am retracing my steps..perhaps i missed something.

  4. Ron Rennick
    MultiSite Guru
    Plugin Author

    Posted 1 year ago #

    Where did you add the require( 'db-settings... line?

  5. cmdr_riker
    Member
    Posted 1 year ago #

    Where did you add the require( 'db-settings... line?

    Boone Gorges has been working on my setup so i've got an env.php along with my wp-config.php.

    i've tried placing the line in both and I get the successful display of the shardb migration. i click on that and try to now migrate my global and i get a 404...

    I'm pretty much spun around here so i'm going to take a break from this.

    regards

    eric

  6. Boone Gorges
    Moderator
    Posted 1 year ago #

    cmdr_riker - This might be my doing. Your env.php file contains a constant SKIP_SHARDB. This is a custom constant I introduced in order to allow for non-sharded copies of the site (such as in local dev environments, where having thousands of databases can be inconvenient). Make sure that this constant is defined as false in your env.php file.

  7. cmdr_riker
    Member
    Posted 1 year ago #

    I got the plugin working by placing require('db-settings.php'); in my env.php file.

    I've tested that this works in either wp-config or env.php --since i'm using the latter as mentioned by jedi Gorges.

    with this issue solved I'm onto another.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.