Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ASP.NET web app performance issue ThreadPool

 
One of my bank customers planned to roll out a new ASP.NET web application serving as their critical internet banking portal. They faced some weird performance issue in their UAT environment. They noticed the CPU utilization was really high (above 90%) without any fluctuation. After checking the IIS log, I found that time-taken value was really small which showed IIS can respond promptly. The stress testing was conducted in the same machine as IIS server so any suspicion on network can be diverted. As usual, I took three rounds of hang dump on IIS server as well as performance monitor log.
 
The CPU utilization on IIS server was really high and most of them was User Mode time. I also noticed the Worker Thread usage had a running number of 24. As the number shown here might not be accurate, we need to dig further on whether it was a thread pool issue.
Work Request in Queue: 0
--------------------------------------
Number of Timers: 9
--------------------------------------
CPU utilization 91%
--------------------------------------
Worker Thread: Total: 27 Running: 24 Idle: 3 MaxLimit: 200 MinLimit: 2
Completion Port Thread:Total: 2 Free: 2 MaxFree: 4 CurrentLimit: 2 MaxLimit: 200 MinLimit: 2
 
With that in mind, I dumped the System.Web.RequestQueue object and found the minExternFreeThreads value of 176 which can in turn calculate the worker threads of 24.
 
0:010> !do 06641d20
Name: System.Web.RequestQueue
MethodTable: 68a20dc8
EEClass: 68a20d58
Size: 64(0x40) bytes
GC Generation: 2
(C:\WINDOWS\assembly\GAC_32\System.Web\2.0.0.0__b03f5f7f11d50a3a\System.Web.dll)
Fields:
      MT    Field   Offset                 Type VT     Attr    Value Name
790fed1c  4001134       14         System


Ïà¹ØÎĵµ£º

×ªÔØ ASP.NETÏÂÔØÎļþ´úÂë

ÈçºÎͨ¹ýASP.NETÀ´ÏÂÔØÎļþ£¬Õâ¸öÎÊÌâÎÒÃǾ­³£Óöµ½£¬°Ñ³£Óõķ½·¨×ܽᵽһÆð£¬Ñ§Ï°Ñ§Ï°¡£µ±ÎÒÃÇÒªÈÃÓû§ÏÂÔØÒ»¸öÎļþ£¬×î¼òµ¥µÄ·½Ê½ÊÇͨ¹ýResponse.RedirectÖ¸Á
Response.Redirect("test.doc")
Äú¿ÉÒÔ°ÑÉÏÃæÕâÐÐÖ¸Áî·ÅÔÚButtonµÄClickʼþµ±ÖУ¬µ±Óû§µã»÷°´Å¥Ö®ºó£¬ÍøÒ³¾Í»á±»×ªÖ·µ½¸Ãwordµµ£¬Ôì³ÉÏÂÔØµÄЧ¹û¡£
µ«Ê ......

ÎÞˢв¨ÐÎŤÇúasp.netÑéÖ¤Âë

 ÎÞˢУºÒ²¾ÍÊÇÒ»°ãÍøÕ¾¶¼Óеē¿´²»Ç壬µã»÷¸ü»»”¡¢“¸ü»»ÑéÖ¤Â딵ÄÄÇÖÖ¹¦ÄÜ£¬Ò»¶Îjs½Å±¾¸ã¶¨£¡
 ²¨ÐÎŤÇú£ºÀàËÆgoogleÑéÖ¤Â룬Õâ¸öÄܸüÓÐЧµÄ·ÀÖ¹ÑéÖ¤Âë±»»úÆ÷È˹¥ÆÆ£¬¾ßÌåµÄŤÇú³Ì¶È¿ÉÒÔ×ÔÐÐÉèÖã¨ÕýÏÒÇúÏßWaveŤÇúͼƬ²úÉú²¨ÐÎÂ˾µÐ§¹û£©£¬¼Ó¼Ó²ÎÊýÒ²¿ÉÒԸijÉmsnµÄÄÇÖÖ°¡£¬×Ô¼º¾ÙÒ»· ......

ASP.net »ñµÃ¿Í»§¶ËµÄIP

  ASP.net »ñµÃ¿Í»§¶ËµÄIP£¬×î³£¼ûµÄÊÇʹÓÃÏÂÊö´úÂ룺 string user_IP = System.Web.HttpContext.Current.Request.ServerVariables["REMOTE_ADDR"];
¶ÔÓÚÁ˽â´úÀí·þÎñÆ÷Çé¿öµÄÈË£¬ÎÒÃÇ»áÖªµÀ£¬Èç¹ûÓû§Ê¹ÓÃÁË´úÀí·þÎñÆ÷£¬ÉÏÊö´úÂë»ñµÃµÄÊÇ´úÀí·þÎñÆ÷µÄIPµØÖ·£»Èç¹ûÓû§Ê¹ÓÃÁ˶à¸ö´úÀí·þÎñÆ÷£¬ÔòÊǵ½´ï·þÎñÆ÷µÄ×îºóÒ ......

ASP.NETµ¼³öExcelÂÒÂëµÄ½â¾ö·½°¸

ÔÚasp.netÖе¼³öexcel ÖбȽÏͨÐеÄ×ö·¨ÊÇ: Response.ContentType = "application/vnd.ms-excel";
È»ºóÖ±½ÓÏòÀïÃæÈÓ html µÄtable
µ«ÊÇÓÐÖÐÎĵÄʱºò ÀϳöÏÖÂÒÂ룬Óкܶà½â¾ö·½°¸£¬µ«¶¼²»ÄÜͨÅ̽â¾ö, ¾ÍÊÇÔÚ Êä³öhtmlÁ½Í·Êä³ö
 
Response.Write("<html><head><meta http-equiv=Content-Type conte ......

[·ÖÏí]ASP.netÒ»¸ö¿Õ¼ä¶à¸öÍøÕ¾µÄÉèÖÃ

¿´µ½ÓÐÈËÌáÎÊÒ»¸ö¿Õ¼äÖ§³Ö¶à¸öÍøÕ¾µÄÎÊÌâ¡£
×ܽáһϣº
×îºÃ±£Ö¤¸÷¸öÏîÄ¿app_codeÄÚµÄÎļþ¶¼ÊÇÒ»ÑùµÄ¡£
ÒòΪÉú³É¶à¸öÏîÄ¿±Ø¶¨Éú³É¶à¸öApp_Code.dll£¬
ÓÉÓÚËùÓÐdll·ÅÔÚͬһ¸öbinĿ¼£¬ËùÒÔÒª±£Ö¤app_codeÄÚµÄÎļþÒ»Ñù¡£
·¢²¼Ç°ËùÓÐÏîÄ¿aspxÎļþµÄ Inherits="menulefttb" ÖеÄÃû×Ö²»ÄÜÏàͬ¡£
½«Ã¿¸öÏîÄ¿·¢²¼ºóÉú³ÉµÄdll ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ