Howto: Move the Windows Server 2003 Inetpub directory from default directory c:\Inetpub to another drive letter


Here’s how to move the Windows Server 2003 Inetpub directory from default directory c:\Inetpub to another drive, d:\Inetpub in this example.

1. From a command prompt type:
xcopy c:\inetpub d:\inetpub /O /X /E /H /K

This will copy the IIS Inetpub directory, it’s contents, and the file permissions to the new drive. See KB 323007 for details on how to use xcopy.exe to maintain file and directory permissions.

2. In IIS manager, view the properties of the default web site. On the Home Directory tab, change the path from c:\inetpub to d:\inetpub. Make this change for each web site the server hosts.

3. Run iisreset from a command prompt to restart the web server services.

4. Remove the old c:\inetpub directory

That’s it!

3 Responses to “Howto: Move the Windows Server 2003 Inetpub directory from default directory c:\Inetpub to another drive letter”

  1. Kelley Gallabd Says:

    Can I just Delete this file Inetpub file?

  2. Kelley Gallabd Says:

    Can I delete this file without anything else going wrong, or is it an important file on my 2002 XP Pro. It seems to be an incomplete file with empty folders.
    Thanks

  3. Seshu Kumar Akella Says:

    You will have edit IIS Metabase to reflect the new inetpub directory. Removing the old inetpub directory will recreate it with each IIS recycle.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: