Skip to main content

Cleanup AppFabric Dashboard Part 1: Old virtual paths and phantom applications on IIS

While you are working with IIS installing and uninstalling web applications you might run into this issue on AppFabric Dashboard:


Another example is this error message:


There are two steps necessary to get a cleaned AppFabric Dashboard.

Delete old virtual paths

Old virtual paths might remain in %windir%\system32\inetsrv\config\ApplicationHost.config. To get rid of these crappy virtual paths switch to command line tool and use the following script:

C:\Windows\System32\inetsrv>appcmd.exe list vdir

VDIR "Default Web Site/" (physicalPath:%SystemDrive%\inetpub\wwwroot)
VDIR "Default Web Site/Service/App1/" (physicalPath:C:\Service\App1)
VDIR "Default Web Site/Service/App2" (physicalPath:C:\Service\App2)
VDIR "Team Foundation Server/" (physicalPath:C:\Program Files\Microsoft Team Foundation Server 12.0\Tools\Templates)
VDIR "Team Foundation Server/tfs/" (physicalPath:C:\Program Files\Microsoft Team Foundation Server 12.0\Application Tier\Web Services)
VDIR "Team Foundation Server/tfs/queue/" (physicalPath:C:\Program Files\Microsoft Team Foundation Server 12.0\Application Tier\Message Queue)

C:\Windows\System32\inetsrv>appcmd.exe delete vdir "Default Web Site/Service/App1/"
VDIR object "Default Web Site/Service/App1/" deleted

Remove phantom applications

The file might also contain some obsolete application entries. I found the solution here.
Search for application XML nodes in your applicationHost.config file and delete them if the the application does no longer exist. Of course, do not forget to create a backup of the file before you start changing it.

To prevent this issue

Always remove deployments like this to avoid, or at least reduce the risk to run into this issue.


Comments

Popular posts from this blog

How to delete Azure Active-Directories

When I was trying to delete an Azure Active-irectory by using the management portal I have received the error message “Directory contains one or more applications that were added by a user or administrator” and I was really confused.

Then I found out this is a common issue. The solution was even more confusing, some PowerShell cmdlets are needed. Unfortunately I was not able to proceed, it was not possible to login with my Microsoft-ID to execute the needed commands.

Here I found out I have to install the correct version of the tools. These are located here.

Clean up AppFabric Dashboard Part 2: Duplicate collection entry in Web.config

In Part one I have already described how to remove phantom apps here on more supplement. These phantom apps could also remain in the AppFabric Monitoring db:


Just delete no longer needed entries in this table.
Duplicate collection entry When you receive this kind of issue, like "[...] Cannot add duplicate collection entry [...]" you have defined the a configuration section twice in two different Web.config files in different places in your file system.

Clear One easy solution is to use a clear statement. Searching for the inherited element There is a post in Microsoft's documentation which is explaining how to do it. Visual Studio in debug mode When you are working with Visual Studio in debug mode, which means you are just pressing F5 to run it on your local IIS instead of publishing it to a web server, you should keep in mind that e.g. your obj folder might contain more copies of your Web.config file. This could lead into this duplicate collection issue as well.

How to move iTunes library to NAS folder

This is nothing new, but to free up some space on my MacBook I decided to move my iTunes library to a network drive on my NAS. I got some inspiration from this old German video. I tried to collect all relevant information for doing so.
I did it by following this steps I closed iTunesI mounted a network drive with AFPI copied my iTunes library folder to a folder on the network drive (it is important to keep the folder name "iTunes"!) I opened iTunes while pressing the "alt" key. Now you can create a library or choose one from another location I set the new iTunes folderI deleted the local iTunes library My iTunes settings look like this now, iTunes took over the selected folder: Keep in mind the followingYou cannot open the iTunes library with two accounts at the same time.When you choose to set "Keep iTunes Media folder organized" iTunes will set your folder structure for artists an albums and also the file pattern for your songs. You have to think about th…