views:

215

answers:

2

Note: I couldn't decide whether this was more appropriate for Stack Overflow or Serverfault, so if you have some insight into that, let me know.

Background: Recently, my server (Windows 2000, MS SQL 2005, IIS 5.0, ASP Classic) experienced a spike in traffic to a specific set of ASP pages. This spike caused a massive drain on the processor, spiking it at 100% and causing all kinds of timeout problems for the visitors.

We've actually handled larger volumes in traffic than this without error. The problem seemed to be that the specific ASP scripts being called were using a huge amount of processor time. Using the Process Explorer from Sysinternals, I found that dllhost.exe was taking up all of the processor time. Looking at its threads, the culprit was calls to COMSVCS.DLL, which seems to be COM+ objects.

So, it seems like my ASP pages are calling COM+ objects and it's killing my processor.

Here's the question: How do I determine which parts of my ASP scripts are calling the COM+ objects, and how would I begin to improve performance from these parts? I have basically no background in Windows programming, so I am at a loss of how to begin.

Thanks for your help.

+3  A: 

Neither COM+ or DLLHOST are likely your problem, they are just the containers that the web site and COM objects are running in. The actual objects they are being "fed" are your issue and/or the ways/frequency they are being called by the web app.

A more productive way to isolate the problem would be to look at the IIS logs for the pages with the longest processing time and have a programmer analyze what is going on in that page and what objects are being called.

Specifically, check the "time-taken" column in the IIS log.

JohnFx
Thank you for your answer, that really helps. I've already started to pull my IIS logs into SQl Server to figure out which pages are causing the problem. Hopefully that will give me a reasonable start.Could I ask you to elaborate on this:"...have a programmer analyze what is going on in that page and what objects are being called."How would you go about analyzing the page and what objects are being called?
DanielMason
It depends on what language the pages are written in, but a competent programmer should be able to isolate the areas of a script that are poor performing. Eduardo's answer is a good start, but I think the focus on objects may be a red-herring. Just about everything is done through objects at some level. Have them try to narrow down the code to the offending part and then worry about what objects are used there (if necessary). Also, beware that many performance issues only present themselves when a lot of users hit the site at the same time. It may perform beautifully with a single user.
JohnFx
+1  A: 
Eduardo Molteni