IIS 6 to
IIS 7 Migration
-----------------------------------------------
I have tested several
migrations on our LAB servers with different versions
of web deployment tools and
different methods as well, and finally
designing this migration
document with combination of all method, and
helpful for team for
real-time IIS migrations.
*** IIS
MIGRATION STEPS ***
1.
Backup your source IIS server (IIS 6)
In the IIS snap-in on the local
computer, click the Computer icon under Internet
Information
Services.
Click Action and select Backup/Restore
Configuration.
Click Create backup, choose a
name for your backup file, and then click OK.
NOTE: If you
wish to encrypt the backup set, place a check mark next to Encrypt
backup using password,
and enter your desired password before clicking OK
2.
Install web deployment tool on source server (IIS 6)
Download Web deploy
tool based on OS type 32bit or 64 bit,
Refer URL'S below for
downloading different web deploy versions.
Web
Deploy 1.1 -- http://www.microsoft.com/en-in/download/details.aspx?id=24709 (X86 -
32 bit)
Web
Deploy 1.1 -- http://www.microsoft.com/en-in/download/details.aspx?id=4148 (X64 -
64 bit)
Web
Deploy 2.0 -- http://www.microsoft.com/en-us/download/details.aspx?id=25230
Web
Deploy 3.0 -- http://www.microsoft.com/en-in/download/details.aspx?id=30436
Web
Deploy 3.5 -- http://www.iis.net/downloads/microsoft/web-deploy
3. Check
for all the dependencies installed on source Server
msdeploy
-verb:getDependencies -source:metakey=lm/w3svc/1
Note
-- Run above command from source server Msdeploy directory to check
the dependencies
installed, /1 is
website identity number and belongs to Default website, If you want to check
dependencies for all
sites than remove /1 and run the above command without /1 or
website
identity number
Once you run the above
command it will display all the dependencies software installed E.g
Asp.net 2.0, 4.0 or any
other dependent software or com files installed.
4. Backup
the configuration of all websites on Source server
msdeploy -verb:sync
-source:webserver60 -dest:archiveDir=<path to archive
to>,encryptPassword=<password>
-disableLink:contentExtension
Note -- Do
not change 'webserver60' to different server name, It is used as sync and need
to use
as it is. This will
create your IIS website configuration and data backup in XML format.
5.
Install IIS 7.0 / 7.5 on destination server
Note
-- Install IIS (7.0 or 7.5) on destination server, Refer link below
for installation steps
http://www.iis.net/learn/install/installing-iis-7/installing-iis-7-and-above-on-windows-server-2008-or-windows-server-2008-r2
After IIS installation
installed all the dependency software's found as per Step 3
( E.g .net 2.0, 4.0
etc)
6.
Backup your destination IIS server ( IIS 7, 7.5)
To
back up the IIS 7 configuration from a command prompt
Log on to the Windows Server 2008 with an
account that has administrator rights.
Open a command prompt by using the Run as
Administrator option and change
directory to
%windir%\system32\inetsrv.
At the command prompt, type appcmd add
backup <backupname>. If you do not
include the name of the
backup, the system will name it for you by using a date, time
format.
7.
Install web deployment tool on Destination server (IIS 7)
Download Web deployment
tool based on OS type 32bit or 64 bit,
Refer URL'S from step
2, for all Web deployment versions.
Note – Make
sure your account has administrator rights while installing web deployment.
8. Copy
the XML configuration files created from source to
destination
server
Note – Copy
.xml files created as per step 4 from source to destination server
9.
Restore configuration files on destination
After all files were in
place on the new server, run below command to restore IIS 7 with the
configuration
msdeploy -verb:sync
-source:archivedir=<path to
archive>,encryptPassword=<password
set in previous command> -dest:webserver60
Note -- Do
not change 'webserver60' to different server name and used the same
encryptPassword set in
source server while creating a XML configuration file. , Above command
will create all sites
on your destination IIS server and also set the web content path for all the
sites, It is also
observe that while using some of the lower webdeploy version webcontent
directory was not
moving to destination server in such scenario used following command to copy
the webcontent
directory from source to destination server, this will copy the webcontent
directory and keep all
the permissions intact.
Copy webcontent folder
along with all sub folders from source to destination using XCopy command
xcopy
<source path> <destination path> /O /X /E /H /K
10.
Check destination IIS server to confirm all the IIS sites
were
created
Test all your migrated
website status, Possibly you need to check the application pool settings
and correct the
permissions and application pool if require. Check for SSL certificate Bindings
and
assign the certificate for website, if it
is not bind properly with website after migration.
No comments:
Post a Comment