Happens on some machines (consistently), but not others. I'm unable to debug any of the RC2 web templates (Core or Framework). I get the following errors:
"Unable to attach to application 'dotnet.exe'..."
/cc @BillHiebert @barrytang
Fixed by...
Rehosting image:

FYI, the blacked out text is the MACHINE NAME.
In case anyone else winds up running into this: this is an issue reported from webservices.dll, which is the transport used by the debugger to communicate between its two processes. Its possible that it is an issue in webservices itself, but probably the most likely explanation is a problem with the networking stack on the computer. Certainly one way of resolving this is what Simon did - reinstall Windows. Other possibilities would be to look at what networking software is installed on the computer and try removing or repairing it.
To add some context:
Not sure what any of that means, just documenting it here.
I'm getting the same issue, after uninstalling RC1 and installing RC2. I don't really want to reinstall windows and visual studio 2015 and rc2. Is there any other fix? I'm running windows 10, VS 2015. I'm going to try to repair VS2015
@conterio I tried uninstall every Microsoft developement related program or feature (including VS) and then reinstalling. That didn't work. Eventually I gave up and wiped the whole machine. According to @gregg-miskelly , you might try looking at networking software on your machine to see if there is a culprit there.
@SimonOrdo Success! What it was is I'm using Sophos Agent, I turned off the service and it works, not sure why I need to disable the service with RC2 but not RC1. either way thanks
@conterio @gregg-miskelly
I too had Sophos installed on that machine before I wiped it. I have not reinstalled it yet, so perhaps that is why my installation is working now.
I will have it reinstalled and we'll see how it does.
Things were working with Sophos in RC1. I'll re-open the issue to hopefully get some more insight.
My _guess_ is that your RC1 project was using a 32-bit process, and your RC2 project is going to be 64-bit.
If you wouldn't mind, please report the issue to Sophos. This is almost certainly their bug.
@gregg-miskelly
You got it. Unfortunately, I still don't understand what exactly is happening, so I'm not sure what to report. Any idea, in general terms what's happening? If I tell them my debugger can't attach to an ASP.NET RC2 web project, I'm not sure they're going to know what I'm talking about.
You can tell them that they are interfering with localhost traffic causing Visual Studio to be unable to debug. My guess would be that all traffic on dynamic ports to ::1 is broken, but of course, maybe it is a more specific bug.
I believe you could see the same problem when debugging any 64-bit process. You could start 64-bit notepad, and try and attach (Debug->Attach To Process) to confirm or deny this.
I will check it and report back when I have Sophos reinstalled. Closing for now.
Also getting this. I've installed VS2015 and RC2 on a clean copy of windows. I don't have Sophos. Should I format? I came here from linux and php dev because that was such a f*** hack.
yeaaaaaaaaah! Just ran a repair on VS. Problem fixed. I'm really impressed with what MS and the community are doing with ASP.net. This is a game changer.
I've exactly the same problem with Visual studio 2017 community edition.
Tried to disable almost all services that use network. no results
I've also this problem with Visual Studio 2015. I can't reinstall windows or other applicatios because it is a company computer. Don't know what to do.... Hope there is a solution......
@coolrix The error you are getting is "Unrecognized error occurred in the Windows Web Services framework"?
To be clear, if that is the error you are seeing (or one of the other related problems) -- _using_ the network isn't a problem. You could have many services operating on the network and you will be fine. The problem tends to be with horrible security software that does all sorts of nasty things to the Windows networking stack and causes it to no longer work. If so, you may be able to configure it such that it no longer breaks your network, or swap it out for something less buggy.
I've got this exact problem, it's indeed network related, turns out it happens only when I'm connected to VPN through NordVPN app. Even after I turn it off I have to restart Visual Studio for the error to go away.
@Xeevis In case it isn't obvious - this means that NordVPN is injecting itself into the Windows networking stack and breaking programs. If you are a customer, you may want to report it to their support team.
Thank you @Xeevis and @gregg-miskelly! It was NordVPN.
Thank you so much @Xeevis and @gregg-miskelly, NordVPN was also causing my issue.
Just ran into the same situation. In my case it was IPVanishVPN. Worked just fine until today.
FYI In Visual Studio 2017 version 15.7 (preview 3 and later), the debugger team added a new mode so that local 64-bit debugging can be configured to communicate between processes using anonymous pipes instead of TCP/IP, and thus working around these problems.
To enable this today:
@gregg-miskelly Thanks, this worked for me in VS Pro 2017 15.7.4
Most helpful comment
FYI In Visual Studio 2017 version 15.7 (preview 3 and later), the debugger team added a new mode so that local 64-bit debugging can be configured to communicate between processes using anonymous pipes instead of TCP/IP, and thus working around these problems.
To enable this today: