Support » Localhost Installs » Error moving from local to live server

  • Can anybody help?

    I built a wordpress site on a local MAMP server and all went well. I then proceeded to move the site to a live server and got the familliar ‘error establishing a database connection’. I moved the site in the usual way using filezilla, first uploading all the local files and folders to the live server, then editing the config.php file with the relevant details. I have checked and double checked these details and all seems to be correct.
    I also moved the database in the usual way. I also opened the table ‘wp_options’ table and changed ‘site URL’ and ‘Home’ to reflect the URL of the live server. After all that, I’m still getting the same error.

    Now, here’s the next problem – I went back to my local site with the intention of just doing a fresh upload and trying again.
    This time, I first went to my dashboard > general settings > and changed the wordpress address URL and the site address URL to reflect the address of my live server. But then I got an error on my localhost site too and was locked out of all but the home page and getting ‘internal database error’ on all other pages.

    I tried going in to the database table ‘wp_options’ on my local database and changing the URL’s back to localhost but I’m still getting the same error.

    I’m afraid to do any more in case I make things worse. Is there something I’m missing or not doing correctly?
    Any help would be greatly appreciated.

    P.S I’m using a mac and filezilla for transfers

    Thanks in advance

Viewing 3 replies - 1 through 3 (of 3 total)
  • esmi


    Forum Moderator

    Try reviewing Moving_WordPress.

    Try deleting (or moving) wp-config.php, then using the wordpress auto-installer to make a database connection. This should always resolve database connectivity problems. You will need the wp-config-sample.php file in your WordPress root folder to run the auto-installer

    As far as I know, this is a database connectivity problem (WordPress cannot connect to the database), so the settings in the database should not matter.

    For your next move, you might want to try this instead of editing the database. It might still fix your problem.

    And on your local server, you might want to restore from a database backup, if problems remain. You might have accidentally made an error in the database.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Error moving from local to live server’ is closed to new replies.