Debugging Azure: Error attaching the debugger to t

2019-01-13 21:26发布

I have a web application asp.net to deploy to Windows Azure. I try to run it on local first. But when debugging, I catch this error from VS2010:

"There was an error attaching the debugger to the IIS worker process 
for URL 'http://127.255.0.0:82/' for role instance 
'deployment16(6).WindowsAzureProject2.WebApplication3_IN_0'. 
Unable to start debugging on the web server ......."

I've search so hard to find the solution for this problem but there's nothing seems work for me. I'm a newbie in Windows Azure, it's really a big trouble with me.

8条回答
We Are One
2楼-- · 2019-01-13 22:05

Please check the version of emulator you have installed. If your code is created in older sdk and you have a new emulator installed it will give you this error.

查看更多
姐就是有狂的资本
3楼-- · 2019-01-13 22:08

Follow step 11 from http://www.microsoft.com/en-us/download/details.aspx?id=35448. Worked for me on Windows 8 with Oct 2012 SDk

查看更多
We Are One
4楼-- · 2019-01-13 22:16

This usually happens when there's a problem with the project to be deployed to the emulator (WindowsAzureProject2 in your case).

Try the following:

  • Check %UserProfile%\AppData\Local\dftmp\IISConfiguratorLogs\IISConfigurator.log file for the error messages. See more details in this answer.

  • Make sure your project can be started without the emulator. It's a web project, so just try to start it as a regular web project. Or publish it to the separate folder and try to create a website in IIS of it.

  • Check your *.csdef and *.cscfg files to make sure all the configuration is correct.

  • Make sure that the build output of your project is not empty. You can do this by going to IIS, find the site with the name similar to deployment16(6).WindowsAzureProject2.WebApplication3_IN_0, right click --> Explore.... Make sure that this folder is not empty and contains all the files required to start a web project successfully.

BTW, there's a similar question: Debugger can't connect when starting local azure project

查看更多
放我归山
5楼-- · 2019-01-13 22:19

I just have today the same problem trying to Debug locally with Azure Storage Emulator in Windows 7. So in the Azure project properties, in Web tab, I checked the radio button 'Use IIS Express' and it debugged without problem. I hope this helps someone.

查看更多
相关推荐>>
6楼-- · 2019-01-13 22:20

I had similar problem with Windows 8, debuging a cloud application with Visual Studio 2012 RTM and Azure SDK 1.71, when trying to launch the application into the compute emulator. It was a very simple app, but I used Azure diagnostics. At the end these are two things I have changed that have work for me, both turning on Windows 8 features (so go to Win8 and open 'Turn Windows Features On/Off'.

Activate the checkboxes for:

  1. Internet Information Services Hostable Web Core

  2. Internet Information Services > World Wide Web Services > Application Development Features > ASP.NET 4.5

  3. Internet Information Services > World Wide Web Services > Health and Diagnostics > Tracing

  4. Internet Information Services > Web Management Tools > IIS Management Scripts and Tools

That worked for me, it makes sense, as I'm using Visual Studio 2012 and trying to get some trace information using diagnostics in Azure.

I hope this will work for you or give some tip about the problem. In the case of being useful information, remember to vote as response or as value tip.

Thanks,

Mike

查看更多
唯我独甜
7楼-- · 2019-01-13 22:21

Also, make sure you run Visual Studio as administrator

查看更多
登录 后发表回答