10

We've got a new server, and I am trying to set it up for our website.

I got a new application for the engineers set up in the Application Pools called eng_app, then added our applications to it.

Now, we have been given an external drive that these applications need to be on, but I can't seem to edit or delete the existing applications.

I tried following the Microsoft Technet Article • Remove an Application (IIS 7) but, as you can see in the screenshot, those are incorrect.

C:\Windows\System32\inetsrv>appcmd delete app "eng_app/drawing"
ERROR ( message:Cannot find APP object with identifier "eng_app/drawing". )

C:\Windows\System32\inetsrv>appcmd delete app "/eng_app/drawing"
ERROR ( message:Must specify the APP object with identifier or "APP.NAME" parameter. )

Could someone tell me what I missed here?

screenshot

Community
  • 1
  • 1

3 Answers3

20

Using Powershell

  1. Go to folder
    cd C:\Windows\system32\inetsrv
  2. List all applications to get the correct APP.NAME
    .\appcmd list app
  3. Delete the application using fullname for <APP.NAME>.
    Ex.: "Default Web Site/The.Application".
    I mean, you must put it with web site name including the double-quotes.
    .\appcmd delete app <APP.NAME>
  • I'll upvote it, but I do not work in software anymore. I cannot test this to confirm if it solved my problem from 5+ years ago. –  Jul 15 '20 at 15:11
  • This works like a charm. For the last command make sure to add double quotes around the APP.NAME. Thats. it! .\appcmd delete app "" – SurenSaluka Sep 03 '22 at 14:02
  • worth noting that you have to enable IIS under 'turn windows features on or off' on your local machine. – CularBytes Jun 21 '23 at 11:08
  • I am baffled as to why there isn't a simple ui to do this. But this command does work, thank you! – Morgeth888 Jun 29 '23 at 20:10
2

OK, it looks like you can't do it either through the command line or using the Application Pool interface.

After stopping the webservice, what I did was:

  1. go down to the list of Sites and select my application from the list,
  2. click Basic Settings...
  3. change the Application pool with the Select... button and edit the Physical path

Afterwards, you can restart the webservice.

screenshot

There might be a better way, but this is how I did it.

0

appcmd delete app eng_app/drawing

Lex Li
  • 60,503
  • 9
  • 116
  • 147