Rename virtual directory on Windows Server 2008 (IIS7 )

Viewed 50126

How can I rename a virtual directory (i.e., change the Virtual Path name) in IIS7 on Windows Server 2008?

In Server Manager I click on the application, select Basic Settings, but the box showing the current Alias is greyed out and I can't edit it.

4 Answers

For as far as I know, there is no way to do it. You can only delete the virtual directory, and recreate it with the same settings.

Or at least, you can't do it through the GUI. There might be ways to do it through scripting in PowerShell for example. But I don't know how.

You may want to checkout this post here

From adilei...

Try PowerShell, I think IIS7 has introduced new administration tools that look quite powerful. I think you could also use these scripts to manage IIS remotely via WMI.

It shouldn't be any more complicated then VBScript.

Another way would be to use VBScript to edit the IIS configuration files or create an administration object, but that doesn't really seem to be the way to go about it.

and from jwmiller5...

Do you want to rename it in IIS, or change the virtual path? adsutil can do either. It should be installed in c:\inetpub\AdminScripts

adsutil.vbs SET W3SVC/svcnum/Root/AppName/AppFriendlyName "New Friendly Name" adsutil.vbs SET W3SVC/svcnum/Root/AppName/AppRoot "New Application Path"

Related