Moving a Site to Another Server

Overview 

There are several reasons for moving or migrating a site to another server, such as performing a system upgrade or setting up a secondary environment. Local content must be moved, but so must Microservices data such as Liquid Content, which is stored on the DNN cloud.

This article will walk you through the steps of doing a site migration from one server to another. The new server can be local or on a cloud hosting platform. The process should be similar either way. If the server change will involve a change to internet routing, that will need to be updated as well. This article outlines moving the physical resources of the site, but will not address routing changes.

 

Environment

 

Solution

Moving local content

  1. Compress (using Winzip, for example) the root DNN folder on the source server. 

  2. Move the .zip file to a newly created folder. 

  3. Extract the .zip file to the website folder location on the new server.

  4. In the new server, create a new IIS site.

  5. Add necessary permissions for your website folder.

  6. Copy the database and set up a database user.

    1. In the old server, take a full backup of the database (the usual practice is to name it with a .bak file extension), then copy the .bak file to the new server.
    2. In the new server, restore the SQL database.
    3. In the new server, use SSMS to set up a database user with the appropriate permissions.
  7. Configure the web.config and the Crawl List.

    1. In the new server, access the web.config file, and verify that the connectionStrings section is correctly configured.
      • Data Source must be set to the path of your database server.
      • Catalog must be the name of the database you restored.
      • User ID and Password must be the credentials of the authorized user that you created for your database.
      • Data Source must be set to the path of your database server.
    2. If the web address for the new site is different from the old site, update the starting URL for crawling.

  8. Set up IIS bindings for the new URL.
  9. Clear cache and restart.
    1. In IIS Manager, restart your website.
      1. Go to Control Panel > Administrative Tools > Internet Information Services (IIS) Manager.
      2. In the Actions pane on the right, go to Manage Server > Restart.

        2019-05-08_16-12-28.png

        TIP: Remember to update your DNS with your new server’s IP address.

    2. Clear the DNN cache.
    3. Restart the DNN application.

Special Consideration: moving Microservices data

If you are using Liquid Content, then some of your information is stored on DNN Corp's cloud storage and accessed via the API. Local and cloud content are linked using the Microservices Tenant ID. The Tenant ID is created automatically based on the connection string between the local content and remote content, so while it is possible to keep the same Tenant ID across a migration in some cases, it may not always be possible.

There are two recommended options for migrating your Liquid Content which are described in the articles linked below:

 

Testing

Browse the website at its new location. Note that depending on the previous configuration, your browser cache may need to be cleared and there may be propagation time involved if internet routing was changed.

If you encounter a .NET error while browsing the site mentioning a NULL object reference or "Object reference not set to an instance of an object," there may be an issue with database permissions or an incorrect connection string. See this article for troubleshooting steps.

Comments

0 comments

Please sign in to leave a comment.