Solved

Cloning IIS 7.5 website from one server to another

Posted on 2013-05-20
17
773 Views
Last Modified: 2013-05-23
Hi,
We have an app running on IIS 7.5 that we would like to move to another IIS 7.5 server. I would like to first export/import the site from old to new server and test it before the final cut over.

I found something about web deploy tool that I can use. What would be the best way to use this tool to make a duplicate site from old to new server for testing?

Thanks,
Sharad
0
Comment
Question by:sharad_rai
  • 9
  • 4
  • 4
17 Comments
 
LVL 4

Accepted Solution

by:
bepsoccer1 earned 300 total points
ID: 39181957
This should help you packing and deploying to the new server using web deploy.  Should be rather painless.  http://www.iis.net/learn/publish/using-web-deploy/packaging-and-restoring-a-web-site
0
 

Author Comment

by:sharad_rai
ID: 39181966
Thanks bepsoccer1,
Steps look fairly simple! This will however not break anything on the production site right? We want that site to be fully functional while we test the site on the new server.

Sharad
0
 

Author Comment

by:sharad_rai
ID: 39181975
msdeploy.exe -verb:sync -source:apphostconfig="Default Web Site" -dest:package=c:\dws.zip > DWSpackage7.log

oops, one more question. So I will change the "Default Web Site" to the name of the site I want to copy, correct? Please also note, I have multiple sites running on the same old server with host headers and I want the site also function in the same way on the new server.

Thanks,
Sharad
0
 
LVL 4

Expert Comment

by:bepsoccer1
ID: 39181976
No, it should not stop IIS or impact it when you run it.  And yes, replace "Default Site" with the name of your site.
0
 

Author Comment

by:sharad_rai
ID: 39182003
I will give it a try now... Thanks,
0
 

Author Comment

by:sharad_rai
ID: 39182021
Will the switch "...-verb: sync" attempt to keep these sites in sync when online? Any change on one site will change the other site as well?
I'm sorry for my naiveness but it's been a while that I have worked with IIS.

thanks, Sharad
0
 
LVL 4

Expert Comment

by:bepsoccer1
ID: 39182054
No it will not continue to try to sync that is something completely different which is know as web farm framework.
0
 
LVL 3

Expert Comment

by:ajmehta
ID: 39182176
That seems like a great tool, but FWIW, I've always used the GUI for robocopy and it's worked perfectly (including permissions on NTFS folders, which is usually a pain even if you get the site copied because permissions may not be).  That does require resetting up in IIS though for HTTP/HTTP/FTP.  Are you also just doing a restore of the DB for the site (if applicable)?
0
Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

 

Author Comment

by:sharad_rai
ID: 39182305
Hi ajmehta,
I did run that tool (msdeploy) and the site seems to have replicated over nicely. I am trying to set it for some testing with the dev team here before I can confirm its working.
And I didn't understand the DB question, do sites have databases too?

Sharad
0
 
LVL 3

Expert Comment

by:ajmehta
ID: 39182339
If it's a web application, oftentimes you have user accounts or other data that you may have in SQL or other database.  it's possible that you used a local Access DB or something else, but you'll need to check.
0
 

Author Comment

by:sharad_rai
ID: 39182362
This site in fact runs an app/api that connects to one of our SQL clusters. I think Devs will provision about how to test this piece on the server.
Thanks,
0
 
LVL 3

Expert Comment

by:ajmehta
ID: 39182383
In that case, be careful testing, because your TEST site is connecting to LIVE data/api's
0
 
LVL 4

Expert Comment

by:bepsoccer1
ID: 39182499
Your connection strings should be in the root web.config.  You will need to change them to point to different databases should you not want to test with live data.
0
 

Author Comment

by:sharad_rai
ID: 39182694
I have let the devs know about it - thanks,
0
 

Author Comment

by:sharad_rai
ID: 39192133
I eventually exported and imported the site from production to a test server couple of days ago to run in parallel with the production site using web deploy tool. Incidentally, the production site is down and has been down without any one noticing it and my question is: "does the tool break the source site during backup/restore process?

the test site is up however...
0
 
LVL 3

Expert Comment

by:ajmehta
ID: 39192153
it shouldn't... but you could restart the app pool and website in IIS
0
 

Author Closing Comment

by:sharad_rai
ID: 39192676
This solution alone was enough for me to accomplish what I wanted to achieve. Other suggestions were good but not directly applicable to this issue.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Running classic asp applications under Windows Server 2008 R2 (x64) and IIS 7 is not as easy as one may think. It took me a while to figure it out while getting error 8002801d a few times. After you install the OS you will need to install the fol…
A safe way to clean winsxs folder from your windows server 2008 R2 editions
This tutorial will walk an individual through the steps necessary to configure their installation of BackupExec 2012 to use network shared disk space. Verify that the path to the shared storage is valid and that data can be written to that location:…
This tutorial will walk an individual through configuring a drive on a Windows Server 2008 to perform shadow copies in order to quickly recover deleted files and folders. Click on Start and then select Computer to view the available drives on the se…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now