Wednesday, February 3, 2016

Import all Websites and application pools by Exporting it from IIS7.5

Task:Create new server with all the pre-configured settings with IIS web server.

Scenario:-
I want to create replica server for all my website with preconfigured apppool setttings.

Actions Taken:-
  1. Taken remote of web server.
  2. Exported all Application Pools from the Server with below command
%windir%\system32\inetsrv\appcmd list apppool /config /xml > c:\apppools.xml

  1. Exported all Websites along with Applications ( Virtual Directories ) with below command
%windir%\system32\inetsrv\appcmd list site /config /xml > c:\sites.xml

  1. Copied both the files from DR webserver to newly formatted C: \
  2. Then Task is to import all application pools and Websites in IIS 7.5
  3. To do so first open INETMGR and delete all Applications and default Website from it ( as its newly formatted we don’t have any important website configured on it)
  4. First Import Application pools which can be done with below command on CMD
%windir%\system32\inetsrv\appcmd add apppool /in < c:\apppools.xml

  1. Then import all Websites along with Applications to do so use below command
%windir%\system32\inetsrv\appcmd add site /in < c:\sites.xml

  1. After all done , IISReset /stop and then IISReset /start
 

No comments:

Post a Comment