Cannot attach debugger to w3wp

Deadly 提交于 2019-11-29 02:51:31
Sandy

When you reset IIS or IIS is not running, you need to make a call to the server, when you hit the server for the first time the w3wp process starts.

THe same thing happened to me. After an update I couldnt find the W3WP! I realized that it didnt show all the processes. Checking the checkbox 'Show processes from all user' was required.

Anthony Leonard

Same thing was happening to me, when i remembered that IIS has an idle timeout! As above the proc w3wp is running, but VS2010 looks at it in the sleep state and thinks its not running, so dos'nt show it in the list...

spinning up IIS [calling a site served from locahost in your favourite web browser] reactivates IIS and suddenly VS can see the process [w3wp] now too

NOTE - must ask MS to ignore the sleep state of IIS/w3wp and if it is in sleep mode - cause it to automatically wake up!

thanks

Quick fix for this, when debugging WCF services in Visual Studio:

  1. Pop open your client app's web.config file.

  2. Find the endpoint entry for the service that isn't appearing in Attach To Process.

  3. Hit Ctrl+Click on the endpoint url, so that it loads the service window in Visual Studio's internal browser.

That's it. IIS will fire-up and you can now pop back over to your service and find W3WP.exe in the processes list.

Also, make sure "Show Processes From All Users" is checked.

I also encountered the same problem. Just build the project again. It would then show up the w3wp.exe in the attach process list.

Also when the attach to process window is open in the bottom left there is a checkbox 'Show processes from all user' make sure this check box is checked then it will show up. You may need to run visual studio as administrator to too. Hope this helps.

Make sure you run VS as an administrator.

Look closely at the URL of the page you are debugging in the off chance that it changed to a different server - something that may rarely happen but happened to me. This falls under the category of "check your assumptions".

I don't how, but there appeared to be an extra application tied to the app pool I was using. Try creating a new app pool and point your application to the newly created app pool. Double check there is only 1 application with your new app pool.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!