Move IIS6 to an Alternative Partition

September 14, 2009

In this example I will assume that IIS is currently located at “C:\InetPub” and it’s logs are located at  “C:\iislogs.” Both directories will be migrated to the “D:” partition.

1. Stop all IIS services
This can be done via the command line by going to Start -> Run -> cmd and using the command net stop http /y .
Or this can be done via the services snap in by going to Start -> Run -> services.msc. Once in the services menu, locate the IIS Admin Service. Right-Click the service and select Stop. A message will appear listing all the services that will be set to stopped. Click Ok.

2.    Copy the folder  and contents of “C:\inetpub” and “C:\iislogs” to D:

3.    Create a backup of the metabase by making a copy of the metabase.xml file located at “c:\windows\system32\inetsrv” and rename to metabase.xml.bak

4.    Using a text editor with a find and replace feature, open the metabase.xml file and replace instances of “C:” with “D:” Be very careful to not use an automated accept method, ensure that the text editor ask for confirmation for each line change before applying it. Specifically you are looking for lines similar to:
Path=”C:\Inetpub\wwwroot” which would be changed to Path=”D:\Inetpub\wwwroot”
LogFileDirectory=”C:\IISLogs” which would be changed to LogFileDirectory=”D:\IISLogs”

5.    Launch the registry editor. Start -> Run -> regedit

6.    Locate the key hklm\system\currentcontrolset\services\http\parameters

7.    Locate the key “ErrorLoggingDir” and modify the value to D:\IISLogs. This key may have to be created if you have never modified the location of your IIS log files.

8.    Reboot the server to apply the updated registry settings.

9.    After the reboot it is recommended to review the Windows Event logs for errors.

{ 1 comment… read it below or add one }

admin October 15, 2009 at 08:33

Edited the post and added some additional detail to explanations on a few steps.

Reply

Leave a Comment

Previous post:

Next post:

© Agrypnia.com 2007-2010. All Rights Reserved.

Theme powered by Thesis.