Ariel
Ariel

Reputation: 4500

Debugging ASP.NET with IIS

I've set up debugging in Visual Studio 2008 to IIS instead of the built in server so I can run url rewriting while developing (using IIRF).

It took a while to get to work (changing permissions, reinstalling the .NET framework) but it was working.

I turned off my machine, and now that it's back on the debugger won't start. I'm using Parallels with WinXP on an iMac.

"Unable to start debugging on the web server. Could not start ASP.NET debugging. More information may be available by starting the project without debugging"

I read a whole bunch of posts on SO as well as googled the subject but none seem to provide a working answer.

Has anyone encountered this and knows how to get it to work?

Thanks.

Upvotes: 4

Views: 3349

Answers (6)

Ariel
Ariel

Reputation: 4500

So after a whole lot of experimenting I managed to find the issue, well kind of.

The main issue was that Keep-Alives were not enabled, which in turn didn't allow the authentication to work properly. With that enabled the debugger actually works. But. It will only work if I start debugging with a .aspx page selected. If I start debugging with a .cs page selected it wont.

Strange, but at least it works!

Upvotes: 1

ggonsalv
ggonsalv

Reputation: 1262

Some times if debug element of compilation element on the web.config is set to false, that is the error you get.

Also if you are not a member of the Administrators group you tend to get his error.

Have you tried to debug with the built-in web server>

Upvotes: 0

campo
campo

Reputation: 1912

I had this problem, and it was because my Application pool in IIS 7 was "Classic" instead of "integrated", using the .net 4 framework.

Upvotes: 0

Joel Etherton
Joel Etherton

Reputation: 37543

Make sure your IIS website is not bound to any IP address. VS 2008 has a problem attaching to bound IPs.

Upvotes: 0

Eran Betzalel
Eran Betzalel

Reputation: 4203

Try manual attachment of the VS debugger to the w3svc.exe process.

Upvotes: 1

Vadim K.
Vadim K.

Reputation: 2456

Make sure you've enabled Windows authentication for your site in IIS.

In the IIS MMC snap-in, right-click on your web site, choose "Properties", select the "Document Security" tab, click on "Edit..." in the "Anonymous access and authentication control" box, and make sure that "Integrated Windows authentication" is selected.

Upvotes: 2

Related Questions