Iis – How to repair IIS when it loses its configuration

iisiis-8.5

I am working with IIS Manager 8.5 on Windows 8.1 x64. I have been using this installation for more than half a year for developing a large web-app. Everything was configured based upon an internal step-by-step guide on how to set up development machines.

All of a sudden, my local installation of the web-app has started returning 503 (the only recent changes I have made since it still worked were a few modifications to JavaScript files delivered as a part of the web application). While trying to figure out the cause by means of the Failed Request Tracing module, the following new issues appeared in IIS Manager:

  • Clicking on the Application Pools node in the Connections tab gives me an empty list. I am pretty sure there was at least one item in there before.
    • When trying to re-add an application pool according to the aforementioned step-by-step guide, IIS Manager refuses to do so and says an application pool of that name is already existing.
    • When adding an application pool with a different name (say, pool_A), the OK button in the Add application pool dialog box gets greyed out upon clicking it, but the dialog box never disappears.
  • Clicking on the Sites node in the Connections tab gives me an empty list. Trying to expand the Sites node in the Connections tab will make IIS Manager freeze (i.e. busy cursor and no response).

I could find an applicationHost.config file that appears to contain the server configuration. It was last changed today, and it did contain pool_A. It is a well-formed XML file.

Rebooting the machine doesn't help. Rebooting the server causes endless wandering of the green status indicator, until finally, an error message is displayed, saying that the service W3SVC cannot be launched.

How can I proceed to debug this problem and find out what exactly is wrong?

Best Answer

First thing to do is look in C:\inetpub\history\ there are x folders CFGHISTORY_0* with the last x configurations of IIS.

I would to a diff on some ApplicationHost.config and the current one in C:\Windows\System32\inetsrv\config and see what changed.

You can either manually fix it or restore a config from the history.

It is possible that your problems have nothing to do with ApplicationHost.config, but this would be I first guess.

Normally if the ApplicationHost.config is not well formed, IIS Manager will tell you that, the fact that it doesn't show items and hangs, is not a good sign.

Related Topic