Deleting web sites in the IIS on XP

March 6, 2007

I recently installed EPiServer on my XP computer, which is cumbersome to say the least. For example, when you choose an existing SQL account instead of creating a new one, the installer tells you that “the account already exists” and throws an exception. Duh!

Well, due to many attempts at installing EPiServer, my IIS was crowded with duplicate EPi sites… and I couldn’t find an easy way of deleting them. EDIT: I tried deleting them in EPiServer Manager, but for some reason that didn’t work.

The answer is two things:

1. Download the Microsoft Metabase Editor, and install it. Open up and go to the W3SVC in the LM branch. There you see different numbers for each of your sites. Remember what numbers correspond to the site you want to remove (the name is usually visible in the ServerComment key).

2. Open up the good old cmd.exe, change directory to C:\inetpub\AdminScripts (or wherever your inetpub is) and type the following:

C:\inetpub\AdminScripts>adsutil.vb delete W3SVC/X

where X is the number for the site that you noted from the metabase.

Done and done!


4 Responses to “Deleting web sites in the IIS on XP”

  1. Steve Celius Says:

    Or, in EPiServer Manager, right click the site, select Delete. You can choose to delete the IIS Site, the Database and/or all files in the directory.

  2. Microserf Says:

    Steve: Yes, that would be a lot easier. I forgot to mention however that that option wasn’t available for me at the time of writing, the “delete” menu command was greyed out for some reason. Dunno why…

  3. Henric Moberg Says:

    Ah, thank you! Now I don’t have to reinstall IIS. Also I have a question; I couldn’t get my EPIServer running because I got an error saying that IIS didn’t allow access to metabase data or something like that. It’s been a while since I tried so I don’t remember exactly. Any thoughts about this?

  4. microserf Says:

    I’m sorry Henric, but I’ve never seen that error. I’d use google and google groups searching for that exact error message, that’s all I can think of now.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: