Products

Solutions

Resources

Partners

Community

About

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

The Community Blog is a personal opinion of community members and by no means the official standpoint of DNN Corp or DNN Platform. This is a place to express personal thoughts about DNNPlatform, the community and its ecosystem. Do you have useful information that you would like to share with the DNN Community in a featured article or blog? If so, please contact .

The use of the Community Blog is covered by our Community Blog Guidelines - please read before commenting or posting.


HOW TO: Move a DotNetNuke installation

A lot of posts in the Install It! forum are from people wonder how to move their DNN installation from their development environment to production. In a nutshell, this is the process:

  1. in your dev environment add a new http alias for the production environment. You can do this in Admin > Site Settings, but only when logged on as host. For instance, if your dev site runs under http://localhost/dotnetnuke, and your production site will run under http://www.mydomain.com, you should add www.mydomain.com as http alias. Why is this important? Always, when DNN receives the first page request, a lookup against the defined portal aliases is done. If the hostname that is used to request pages from DNN is not found in the list of portal aliases, DNN will redirect to the first available portal alias of the first portal. Quite often this will be your dev environment. A common mistake is to not add the portal alias, and thus be redirected to your devsite when browsing to your production site for the first time
  2. Move your database to the production database server. There are a couple of ways of doing this. You can do a backup of your dev DB, and restore it (or have your provider restore it) on your production db server. The problem i have with this approach is twofold: if the db collation of the production server is different than the collation of your dev db server, you could get into troubles when using modules that use temporary tables. The collation of TempDB is always the same as the server collation, while the collation of the database is copied over from the dev db during the restore. The other problem you might run into with this approach is the fact that although usernames might match on both servers, in reality they are not the same. The security id (SID) will be different, so you will not be able to use the same user, and also, you will have an orphaned user in your production database.
    Alternatively, you can simply detach your db from your dev sql server and attach it to the production server. This might also cause issues with collation and user id's.
    The method i like myself is a bit more expensive: database comparison, but works very good. I almost always use the tools from Red-Gate, SQL Compare and SQL Data Compare. These tools automate the comparison between to databases to a very high degree. A great plus of these tools is that you can use them to keep your development database and your production database in sync as well. Just run Data Compare, and the contents of the 2 db's will be the same again.
  3. Move all the files in your dnn application folder to the production folder. This can be done by ftp or any other method you use to copy files.
  4. Make the appropriate changes to web.config. At the very least you should change the sql connection string, to have dnn look at your production db
  5. Browse to your production site... done

I found a couple third party blog posts about moving DNN and moving databases:

Please, no questions / discussion in comments to this blog. I am going to maintain a FAQ about this in the forums, if you have any further questions, please ask them in the Install It! forums, i will pick them up there and answer in the Faq post.

Comments

Jordan Gottlieb
I was unable to successfully migrate, though everything seems to work fine except for a few modules only show up when visiting localhost/dnn, but not /dnn, on prod... I ran your Red-Gate stuff and it found a few diffs but repaired them. Any other ideas?
Jordan Gottlieb Wednesday, September 10, 2014 7:40 PM (link)
Heather Jenkins
If I just want to move my dnn application (not the DB) over to a new server can I just move the dnn application folder there or do I need to install dnn on the new server first and then move the folder over?

Heather Jenkins Thursday, January 22, 2015 3:38 PM (link)
Jordan Gottlieb
Do you mean copy the DNN root directory from one server to another, and keep hosting the DB in the same place? Or are you using the file system DB?
Jordan Gottlieb Friday, January 23, 2015 12:09 PM (link)
Kyle Overton
I am trying to move site from managed.com to godaddy.com what are the steps to accomplish on godaddy? I have my site files and the .bak file of my database but I don't know steps needed on godaddy to get it all working. Help please.
Kyle Overton Thursday, February 25, 2016 1:13 PM (link)

Comment Form

Only registered users may post comments.

NewsArchives


Aderson Oliveira (22)
Alec Whittington (11)
Alessandra Daniels (3)
Alex Shirley (10)
Andrew Hoefling (3)
Andrew Nurse (30)
Andy Tryba (1)
Anthony Glenwright (5)
Antonio Chagoury (28)
Ash Prasad (37)
Ben Schmidt (1)
Benjamin Hermann (25)
Benoit Sarton (9)
Beth Firebaugh (12)
Bill Walker (36)
Bob Kruger (5)
Bogdan Litescu (1)
Brian Dukes (2)
Brice Snow (1)
Bruce Chapman (20)
Bryan Andrews (1)
cathal connolly (55)
Charles Nurse (163)
Chris Hammond (213)
Chris Paterra (55)
Clint Patterson (108)
Cuong Dang (21)
Daniel Bartholomew (2)
Daniel Mettler (181)
Daniel Valadas (48)
Dave Buckner (2)
David Poindexter (12)
David Rodriguez (3)
Dennis Shiao (1)
Doug Howell (11)
Erik van Ballegoij (30)
Ernst Peter Tamminga (80)
Francisco Perez Andres (17)
Geoff Barlow (12)
George Alatrash (12)
Gifford Watkins (3)
Gilles Le Pigocher (3)
Ian Robinson (7)
Israel Martinez (17)
Jan Blomquist (2)
Jan Jonas (3)
Jaspreet Bhatia (1)
Jenni Merrifield (6)
Joe Brinkman (274)
John Mitchell (1)
Jon Henning (14)
Jonathan Sheely (4)
Jordan Coopersmith (1)
Joseph Craig (2)
Kan Ma (1)
Keivan Beigi (3)
Kelly Ford (4)
Ken Grierson (10)
Kevin Schreiner (6)
Leigh Pointer (31)
Lorraine Young (60)
Malik Khan (1)
Matt Rutledge (2)
Matthias Schlomann (16)
Mauricio Márquez (5)
Michael Doxsey (7)
Michael Tobisch (3)
Michael Washington (202)
Miguel Gatmaytan (3)
Mike Horton (19)
Mitchel Sellers (40)
Nathan Rover (3)
Navin V Nagiah (14)
Néstor Sánchez (31)
Nik Kalyani (14)
Oliver Hine (1)
Patricio F. Salinas (1)
Patrick Ryan (1)
Peter Donker (54)
Philip Beadle (135)
Philipp Becker (4)
Richard Dumas (22)
Robert J Collins (5)
Roger Selwyn (8)
Ruben Lopez (1)
Ryan Martinez (1)
Sacha Trauwaen (1)
Salar Golestanian (4)
Sanjay Mehrotra (9)
Scott McCulloch (1)
Scott Schlesier (11)
Scott Wilkinson (3)
Scott Willhite (97)
Sebastian Leupold (80)
Shaun Walker (237)
Shawn Mehaffie (17)
Stefan Cullmann (12)
Stefan Kamphuis (12)
Steve Fabian (31)
Steven Fisher (1)
Tony Henrich (3)
Torsten Weggen (3)
Tycho de Waard (4)
Vicenç Masanas (27)
Vincent Nguyen (3)
Vitaly Kozadayev (6)
Will Morgenweck (40)
Will Strohl (180)
William Severance (5)
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out