This tutorial will demonstrate how to migrate websites from one server to another server.
Below, an example of how to migrate a DNN site by WebsitePanel and FTP will be given.
Here are the options that need to be done
- Create the same domain name in new Control Panel(required)
- Create the same website name in new Control Panel(required)
- Create the same database and DB user in new Control Panel(required)
- Copy web files(required)
- Take a backup and restore database(required)
- Update database connection string(required)
- Update host file to test the site(optional)
- Update DNS records or name server(required)
- Move SSL(required if the website is SSL certified)
1 How to Add a New Domain to Website Panel
1.1 Login to Website Panel
1.2 Add a domain name in the Website Panel
Click the ‘domains’ menu.
Click ‘Add Domain’ button.
Add a Top-Level Domain or a Sub-domain by clicking the ‘Domain’ or ‘Sub-domain’ button.
Type your domain name. Check on the option ‘Create Web Site’ and the website will be created in the web server. Check the option ‘Enable DNS’. You can manage the DNS in the Website Panel if the domain name is using Database Mart name servers. Click ‘Add Domain’ button to complete adding a new domain name.
2 How to Backup database in the Website Panel
Login to the Website Panel where is the location hosts the old database.
Click the database which you want to backup.
2.2 navigate to the ‘Maintenance Tool’ option
Expand the ‘Maintenance Tool’ menu, you will find the ‘Backup’ button list below, Click the Backup botton.
2.3 Save path
Select the root folder, then click the backup button. The database backup file will be backed up in the root folder of the hosting space.
3 How to Migrate web files and database backup
3.1 Find out the FTP server IP address
Login to the WebsitePanel.
Click the Space Statistics menu.
Click view space summary link right hand of the panel.
The FTP server IP can be found in the FTP section list below.
Download and upload the web files via FileZilla client, Enter Your New Site Name
- Host: Entry your server IP or ftp.yourdomain.com
- Encryption: Please select FTPES-FTP over Explicit TLS/SSL
- Logon Type: Please select Normal
- User Name: Entry the user name you created in Website Panel Control Panel
- Password: Entry the password of the user
- Click Connect
- Move all of the files to the wwwroot directory.
4 Restore database
4.1 Restore feature
Login to the WebsitePanel.
Click the database version.
4.2 Create a new database
Create a new database, the database name is the same to the old DNN site database name.
4.3 Add a new database user
Fill in the database user name and password which same to the old database user name and password. Select the default database as the database which was created.
4.4 Restore feature
Click the database name, go to the ‘Maintenance Tool’ option.
Expand the ‘Maintenance Tool’ menu, you will find the ‘Restore’ button list below.
Click the ‘Restore’ button to choose a database media which need to be restored.
5 How to Update the Database Connection String
5.1 Login to the Website Panel
Locate the new database hosting server. Click the database version.
Click the database name, the database hosting server will be found in the ‘External Server’ region.
5.2 Modify the connect string
Modify the web.config file under C:\Hosting Spaces\yourdomain.com\wwwroot, you can modify the web.config file in your local machine, then upload it to the hosting server. Also, you can modify the content by connecting with FTP client.
6 Move SSL(requited if the website is SSL certified)
Refer to the 2.8 how to import SSL and add a binding to the website.
7 Test web site
Modify the hosts file under C:\Windows\System32\drivers\etc to test the website in your local PC. Access to the directory C:\Windows\System32\drivers\etc\, Edit the hosts file by notepad, Modify the content below, enter the hosting server IP before the domain name.
Open the web browser on your local PC, type in the domain name testing it out.
8 Update name server or DNS A records
- If the domain name is using Database Mart’s name servers, make sure that the DNS record is correct. Check the DNS record by intodns.com to see if the www A record pointing to the correct web server.
- If the domain name is using the name servers in other domain provider, please ask clients to update the DNS records by contacting their domain provider to update the DNS record.