Renaming applications in IIS 7.0

It's generally known that you are not allowed to edit the application alias while editing application settings through window interface of IIS Manager. The alias of an application has the gray color (not admitted to change). But in this article you may found how to do this through the command-line utility software:

But there is an another way to do it. You can edit the settings file as it is written in this article:

In the settings file I just changed the value ("/Site1") of the path attribute at the application element and nothing more:

<application path="/Site1" applicationPool="DefaultAppPool">
        physicalPath="C:\Sites\Site1" />

The issue is that I don't know whether these two ways is the same and have the same results. Maybe the command-line utility (appcmd) does some additional work except just renaming the application name?


I recently had to do this and I think you are better off using appcmd because ,as you said, we don't know what else is changing behind the scenes.


appcmd list app

APP "Default Web Site/" (applicationPool:DefaultAppPool)
APP "Default Web Site/develop" (applicationPool:mypool)
APP "Default Web Site/develop/xyz" (applicationPool:mypool)

In my case, I did have to do the renaming starting from the child. Otherwise, appcmd won't find the child site.

appcmd set app "Default Web Site/develop/xyz" -path:/B455/xyz
appcmd set app "Default Web Site/develop" -path:/B455


appcmd list app

APP "Default Web Site/" (applicationPool:DefaultAppPool)
APP "Default Web Site/B455" (applicationPool:mypool)
APP "Default Web Site/B455/xyz" (applicationPool:mypool)

Note: appcmd can be found under %windir%\system32\inetsrv

I have used appcmd recently to change a website application name with no issues. I ran a cmd prompt as admin then:-

cd c:\windows\syswow64\inetsrv\
appcmd set app WebsiteName/applicationname -path:"/newapplicationname"

Works a treat :)

All that is happening here, regardless of which method you use, is that the name of the application path is changed.

There's really no magic to it. Obviously any paths in your web application that depended on the old path name would need to be renamed.

You might find my answer to this question useful for gaining an understanding of the mechanics of virtual directories and applications in IIS7:

Using ServerManager to create Application within Application

Need Your Help

Is there some way to PUSH data from web server to browser?

ajax webserver comet

Of course I am aware of Ajax, but the problem with Ajax is that the browser should poll the server frequently to find whether there is new data. This increases server load.

How to send an email using PHP?

php email wamp wampserver

I am using PHP on a website and I want to add emailing functionality.