IIS backup Disaster action plan

                                                                                                                                                                                                                                   kick it on DotNetKicks.com

      Hi this is Satalaj, in this article we will see how to replicate old windows server to new windows server during disaster or maintenance situation.
Below are the some useful steps.
1. IIS backup.
2. Host File.
3. MS SQL Server network utility.

IIS Backup
    We need to first copy the physical folders to new server and create same folder structure like
old server.
   It is very difficult to remember the names of virtual directory. IIS is providing facility to backup
the Meta base data (xml file) where it has stored the pats of folder mapping. Below figures are self explanatory.
We will take Application Pools backup and save it as C:\IIS_Backup\ApplicationPool .




Same way we will take web applications backup.



save configuration file as c:\IIS_BACKUP\WebApps



That’s it. Now, assume that we have created same directory structure on new server. Moved ApplicationPool.xml and webapps.xml there. You can edit the webapps.xml and replace the Drive names if changed.

Let’s look at the brand new windows server. There we will be restoring these xml files


We will store application pools from ApplicationPool.XML file




Repeat the same procedure and load all other application pools.
Do same thing for Web sites. And select \ or default web to restore all in one shot.

and Start The IIS server .

by editing host file Ip entry you can resolve the domain to IP addresses if DNS failed to resolve or taking more than 1-24 hrs to resolve.
Host file can be found at
edit and add entry like this
e.g  www.google.com

Now hit the google.com or ping it will resolve to


Use Sql server network utility we can route the traffic to new sql server without changing
any application configuration.




Click add then click on TCP/IP
If you have used TCP/IP to access SQL server in your web Applications
All applications are accessing SQL server using IP
now let’s say it is changed to Below fig shows how to configure application server to use new IP instead of doing changes in all web.config / app.config or any hardcoded IP.

If applications are accessing SQL using domain use Named Pipes

Thanks for your time.



My name is Satalaj, but people call me Sat. Here is my homepage: . I live in Pune, PN and work as a Software Engineer. I'm former MVP in ASP.net year 2010.
Disclaimer: Views or opinion expressed here are my personal research and it has nothing to do with my employer. You are free to use the code, ideas/hints in your projects. However, you should not copy and paste my original content to other web sites. Feel free to copy or extend the code.
If you want to fight with me, this website is not for you.

I'm Satalaj.