如何在Visual Studio中从IIS调试两个Web应用程序/服务? [英] How to debug two web applications/services on IIS from within Visual Studio?

查看:203
本文介绍了如何在Visual Studio中从IIS调试两个Web应用程序/服务?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Visual Studio 2010中,
我想同时调试在IIS上运行的两个Web应用程序。
调试第一个应用程序是没问题。但是当开始调试第二个应用程序并且第一个程序仍处于调试模式时,Visual Studio会提示:

In Visual Studio 2010, I want to debug two web applications running on IIS at the same time. When debugging the first application it is ok. But when starting to debug the second application and first program is still in debug mode, Visual Studio prompts:


无法在网络上开始调试服务器。调试器已经
附加

unable to start debugging on the web server. a debugger is already attached

我如何解决这个问题?

推荐答案

总而言之,必须在 IIS 中设置不同的应用程序池,以便两个应用程序进行调试。

To summarize, one has to set different application pools in IIS for the two applications to debug.

以下是一个粗略的说明,因为这两个应用程序已在Visual Studio中部署到IIS一次。

Here is a rough instruction, given that both applications have been deployed to IIS once within Visual Studio.


  1. 打开Internet信息服务(IIS)管理器

  2. 单击左窗格中的应用程序池 li>
  3. 在右窗格中添加另一个集成应用程序池,让我们命名为第二个ASP.NET 4.0集成

  4. 对于一个应用程序,打开高级设置...

  5. 在属性视图中,最后选择第二个ASP.NET 4.0集成作为应用程序池

  1. Open the Internet Information Services (IIS) Manager
  2. Click Application Pools on the left pane
  3. On the right pane add another integrated application pool, let's name it Second ASP.NET 4.0 Integrated
  4. For one application, open the Advanced Settings...
  5. In the properties view finally select Second ASP.NET 4.0 Integrated as the application pool

这样应用程序应该可以并行调试,因为每个应用程序池产生一个新的操作系统进程可以附加一个单独的调试器

This way the applications should be debuggable in parallel because each Application Pool spawns a new operating system process to which a separate debugger can be attached.

这篇关于如何在Visual Studio中从IIS调试两个Web应用程序/服务?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆