简体   繁体   English

应用程序池在现场崩溃

[英]Application Pool crashes on site

So I've been trying to figure out why the application pool keeps crashing every now and then, and I've pinpointed the page that is cau seems to be causing the issue.所以我一直在试图弄清楚为什么应用程序池时不时地崩溃,并且我已经确定了似乎是导致问题的 原因 的页面。

When I open the site in the browser, and visit the Shipping cart page (after adding stuff to the cart), the entire browser becomes unresponsive, and I open Task Manager, and see that IE (browser) is using 99% CPU, so I right-click > Create DUMP > Try to read DUMP but WinDBG does not seem to like DMP files;当我在浏览器中打开网站,并访问运输购物车页面(添加东西到购物车后),整个浏览器变得无响应,我打开任务管理器,看到 IE(浏览器)正在使用 99% 的 CPU,所以我右键单击 > 创建 DUMP > 尝试读取 DUMP 但 WinDBG 似乎不喜欢 DMP 文件; won't read them.不会读它们。

So I move on, and try to figure it out without the dump files.所以我继续前进,并尝试在没有转储文件的情况下弄清楚。 I fire up Visual Studio, open the site in question, and then follow the same process (add stuff to cart, then visit cart page).我启动 Visual Studio,打开有问题的站点,然后执行相同的过程(将东西添加到购物车,然后访问购物车页面)。 And to my surprise, everything is OK.令我惊讶的是,一切都很好。

Not sure what to do now.不知道现在该怎么办。 Any suggestions?有什么建议? How would you determine the cause of the hanging, when everything runs perfectly, locally - and when everything used to run perfectly online, but no longer runs fine online?您将如何确定挂起的原因,当一切都在本地完美运行时 - 以及当一切过去都可以完美地在线运行,但不再在线正常运行时?

If the browser becomes unresponsive and eats 99% CPU, that's a client side problem;如果浏览器无响应并占用 99% 的 CPU,那是客户端问题; it most likely doesn't have anything to do with IIS or your server side code.它很可能与 IIS 或您的服务器端代码无关。

Could it be that you have some javascript in your page is buggy and goes into a busy loop?可能是您的页面中有一些 javascript 有问题并进入繁忙循环? I think it's worth a shot to test this (use either IE's developer tools (F12), Visual Studio's javascript debugging functionality, or FireFox in combination with FireBug).我认为值得一试(使用 IE 的开发人员工具 (F12)、Visual Studio 的 javascript 调试功能或 FireFox 与 FireBug 结合使用)。

Edit It strikes me as odd that your AppPool crashes, and in doing so, causes the web browser to turn non-responsive.编辑您的 AppPool 崩溃了,这让我感到很奇怪,这样做会导致 Web 浏览器无响应。 With non-responsive, do you really mean that the browser itself stops working (ie navigating a page back or going to another url such as google.com is impossible?)没有响应,你真的意味着浏览器本身停止工作(即导航一个页面或转到另一个 url,例如 google.com 是不可能的?)

Anyway, if you think the problems occur on the server-side, you could try the following things (in order of increasing effort):无论如何,如果您认为问题发生在服务器端,您可以尝试以下事情(以增加努力的顺序):

  • After an AppPool crash, check the windows event log (run 'eventvwr' from a command prompt) and see what information that gives you. AppPool 崩溃后,检查 Windows 事件日志(从命令提示符运行“eventvwr”)并查看提供了哪些信息。
  • View the IIS log (you might have to turn it on first), see if it contains any weird request patterns, such as your page getting hammered)查看 IIS 日志(您可能必须先将其打开),看看它是否包含任何奇怪的请求模式,例如您的页面被锤击)
  • Run your website from IIS, but attach a debugger from Visual Studio (under Tools, Attach to process - include only managed code) to the IIS worker process (usually w3wp.exe).从 IIS 运行您的网站,但将 Visual Studio 中的调试器(在工具下,附加到进程 - 仅包含托管代码)附加到 IIS 工作进程(通常是 w3wp.exe)。 If your page throws an exception, VS should be able to catch it.如果您的页面抛出异常,VS 应该能够捕获它。
  • Add more tracing to your page, the Global.asax 's Application_Error seems like a particularly good candidate.向您的页面添加更多跟踪, Global.asax的 Application_Error 似乎是一个特别好的候选者。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM