Hello all,
I recently consolidated a number of DotNetNuke installs from physical co-located servers running various versions of Windows Server and MS SQL to a Amazon Web Services EC2 instance running Windows x64, and Amazon RDS MS SQL.
Since I'm basically brand new to Amazon's cloud offerings it took a bit to nail down a solid working process so I thought I would share. Oh and no I don't work for Amazon or anything. I'm just an independent developer.
Here is the process I used...
Migrating DotNetNuke to Amazon EC2 / RDS
1) Spin up EC2 target Windows instance and RDS. Do your standard OS setup.
2) Set up an elastic IP and point it to your EC2 target instance.
3) Open TCP port 1433 inbound on the source database server's Firewall(s) to the public/elastic IP of your EC2 instance.
4) Remote Desktop into the EC2 / target server
5) Download and install SQL Azure Database Migration Wizard, and install on target EC2 Windows instance (important)
http://sqlazuremw.codeplex.com/
Yes I know I said Amazon RDS, not Azure, but this tool works perfectly with RDS. It is a great point and click solution.
Since RDS does not support SQL backup file restores SQLAzureMW is the best method I've found for migrating the database.
6) Launch SQLAzureMW, enter destination MS SQL connection info, connect, select DNN database, select all objects and generate SQL scripts.
This will take some time depending on the size and performance of your DNN database.
Click the Auto Scroll Dispay checkbox if you want to monitor the output of the job.
You will likely see a few warnings in Red regarding Azure SQL compatibility. I'm fairly certain these can be ignored since the destination is RDS. At least I haven't run into any issues with this. YMMV.
When the scripts have been generated, hit next then select SQL Server for Server Type and enter the RDS DNS endpoint, RDS admin DB user and password. Next then Create the Target Database, make sure it it selected, hit next and execute the scripts.
7) While the SQLAzureMW is doing it's thing FTP the DNN web site root from the source to target server.
I have some pretty big DNN implementations and crazy enough some of our old servers were not happy about zipping up 200+ GB folders.
So I just let the FTP client go to town on the root directory which, while slow, always did the trick.
8) Edit the connection string info in the web.config file on the target server with the new RDS end point, user and password.
9) Add the site to IIS and configure all of your portal domain bindings.
10) Edit the /etc/hosts file on your local workstation and add an entry with the target public ip and domain name for each portal and portal alias.
Test each portal and make sure everything is running great
11) Update the domain host records for each portal and all aliases.
12) remove the entries from your /etc/hosts file