Migration question

  • This topic has 1 reply, 2 voices, and was last updated 9 years ago by udadmin.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #134863
    Rachel
    Participant

    Hello,

    I am moving a site from one host to another. The URL will remain the same, but I haven’t redirected the DNS yet. I installed WordPress and UpdraftPlus on the new host, and was prompted to purchase Migrator tool, which I did, on the new install. Then I did a “restore” to migrate the backup files from the old site, and clicked the “search and replace” box as prompted. (It was unclear to me whether this was needed, since ultimately I am not changing URL’s. But it sounded like it was needed, because of moving the database to a new host). Anyway, the migration went OK, and right now the site looks fine, but it has a temporary URL, not a domain name. I’m worried that when I point the DNS to the new nameserver, everything will break and I won’t be able to get into the dashboard. Right now, in the general settings, the WP and Site URLs are the temporary URL given to me by the new host. If I now point the domain name to the new nameservers and everything breaks, how to do I get in to fix it? How do I do another search and replace on the database to get rid of the temporary URL?

    Thanks.
    Rachel

    #134907
    udadmin
    Keymaster

    Hi Rachel,

    How do I do another search and replace on the database to get rid of the temporary URL?

    You can do this in the “Expert/Debugging” tab of UpdraftPlus (on the settings page).

    In order to be able to log in after changing the DNS, you can log in by adding this near the top of your wp-config.php:

    define('WP_SITEURL', 'https://example.com');
    define('WP_HOME', WP_SITEURL);

    That will allow you to log in to run the search/replace.

    Alternatively, if you want to do the search/replace before changing the DNS, then you can still navigate the site after doing so, by creating a local DNS over-ride on your computer, by editing your computer’s hosts file. To learn about this technique, Google “edit PC hosts file” or “edit Mac hosts file”, as appropriate.

    David

Viewing 2 posts - 1 through 2 (of 2 total)
  • The topic ‘Migration question’ is closed to new replies.