mysql error on move-blogs.php during Multi-db install

Does anyone know whether there any reason that I would get this error. I had all green until I clicked to move dbs

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/tsnleade/public_html/wp-content/scripts/move-blogs.php on line 140

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/tsnleade/public_html/wp-content/scripts/move-blogs.php on line 141

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/tsnleade/public_html/wp-content/scripts/move-blogs.php on line 140

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/tsnleade/public_html/wp-content/scripts/move-blogs.php on line 141

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/tsnleade/public_html/wp-content/scripts/move-blogs.php on line 140

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/tsnleade/public_html/wp-content/scripts/move-blogs.php on line 141

  • review
    • WPMU DEV Initiate

    $dbname = "tsnleade_wrdp1"; //This is your current database
    $blog_table_prefix = 'wp_'; //Prefix of your wpmu blog tables, most likely this won't need to be changed
    $newdb_prefix = 'tsnleade_wrdp1_'; //This is the prefix of the db's you're moving your tables into - we assume they are all the same, if not, you're in trouble

    //We need info to connect to the databases
    $dbhost = 'localhost';
    $dbuname = 'tsnleade_wrdp1';
    $dbpass = 'Z1eDw2riwqTr';

    //How many db's are you moving into (16, 256, or 4096)?
    $db_scaling = '4096';

    I finally got it to run after my programmer made a change in the script but it only processed the global database.

  • review
    • WPMU DEV Initiate

    i repeated the process with the original plugin intact (no modifications),. bumped into the same error

    here are lines 19 - 29 of move-blogs.php

    ///DB Settings
    $dbname = "tsnleade_tangoms";  //This is your current database
    $blog_table_prefix = 'wp_';  //Prefix of your wpmu blog tables, most likely this won't need to be changed
    $newdb_prefix = 'tsnleade_tangoms_';  //This is the prefix of the db's you're moving your tables into - we assume they are all the same, if not, you're in trouble
    
    //We need info to connect to the databases
    $dbhost = 'localhost';
    $dbuname = 'tsnleade_tangoms';
    $dbpass = 'tango123';
    
    //How many db's are you moving into (16, 256, or 4096)?
    $db_scaling = '4096';

    =========================================================


    i have attached the 3 files
    db.php
    db-config.php
    move-blogs.php

  • aecnu
    • WP Unicorn

    Greetings review :slight_smile:

    I am very sorry and sincerely apologize for the delay in someone getting back to you on this - it seems your ticket somehow got buried in the system.

    If you are still having an issue with this please let us know so that we may try to get you fixed up as soon as possible by choosing to mark this ticket as unresolved.

    This will also bring your ticket up front back in plain view again.

    Joe :slight_smile:

  • review
    • WPMU DEV Initiate

    My programmer had to suppress the php error in order to get the move-blogs.php script to run... We did get the install on a development domain but we are working through permission issues on the production domain... I think more info could be given to the "adding user and pass to each DB".

  • cartier247
    • Flash Drive

    Joe,

    I'm also facing a similar issue. After following the instructions for multi-db setup, I try and go to the move-blogs.php and get the following error: "Could not connect to mysql"

    I used multi-db with a new Wordpress multisite install. The Wordpress multisite works, but the multi-db and move-blogs.php don't work.

    Is there any updated documentation regarding setting up multi-db?

    Best Regards,

    CJ

  • review
    • WPMU DEV Initiate

    Are you connecting to localhost ip 127.0.0.1? this seemed to help my connection problems... Also making sure that you have GRANTED ALL Permissions to the MySQL database user... I had to do it from the Root PHPAdmin.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.