<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.iis.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>cpattekar</title><link>http://blogs.iis.net/cpattekar/default.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Debug Build: 20510.895)</generator><item><title>Running IIS7 worker processes under debugger</title><link>http://blogs.iis.net/cpattekar/archive/2008/05/13/running-iis7-worker-processes-under-debugger.aspx</link><pubDate>Tue, 13 May 2008 20:49:00 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:2355597</guid><dc:creator>cpattekar</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.iis.net/cpattekar/rsscomments.aspx?PostID=2355597</wfw:commentRss><comments>http://blogs.iis.net/cpattekar/archive/2008/05/13/running-iis7-worker-processes-under-debugger.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;This blogs explains how to configure debugger such that worker processes launch under debugger in Windows Server 2008. &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Step 1:&lt;/STRONG&gt; Install Debugging tools for windows from &lt;A href="http://www.microsoft.com/whdc/devtools/debugging/default.mspx" mce_href="http://www.microsoft.com/whdc/devtools/debugging/default.mspx"&gt;http://www.microsoft.com/whdc/devtools/debugging/default.mspx&lt;/A&gt;. This will install ntsd.exe which is what we are going to use. Note the directory to which the debuggers got installed.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Step 2:&lt;/STRONG&gt; In this step, we will create an entry in Windows System Registry for the debugger. Simply open Windows registry editor (regedit.exe) and navigate to:&lt;/P&gt;
&lt;P mce_keep="true"&gt;"HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options". &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Step 3:&lt;/STRONG&gt; Right click on "Image File Execution Options" node and click on New &amp;gt; Key. Name this key "w3wp.exe".&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Step 4:&lt;/STRONG&gt; In the right pane of Registry editor, right click and add New &amp;gt; String value. Call this key "Debugger". &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Step 5:&lt;/STRONG&gt; Double click Debugger and in the "Value data" text field, enter the following string:&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;EM&gt;&amp;lt;debugger path&amp;gt;&lt;/EM&gt;\ntsd.exe -server npipe:pipe=w3wp%d -G&amp;nbsp;-g&lt;/P&gt;
&lt;P mce_keep="true"&gt;-g tells the debugger&amp;nbsp;not to breakin on the initial breakpoint&amp;nbsp;when the worker process is starting up.&lt;/P&gt;
&lt;P mce_keep="true"&gt;-G tells the debugger not to breakin on the final breakpoint when the worker process is exiting.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Step 6:&lt;/STRONG&gt; Make a request to IIS using internet explorer or your faviourite client so that the worker process starts up. Start a command prompt and CD to the debugger folder. Type "tlist -t" to get a tree view of processes running on the machine. Look for w3wp.exe and it should be running under ntsd.exe like:&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; svchost.exe (1628)&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ntsd.exe (1308)&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; w3wp.exe (2212)&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Step 7:&lt;/STRONG&gt; Connect to the debugger via remote.exe using the following command:&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;EM&gt;&amp;lt;debugger path&amp;gt;&lt;/EM&gt;\ntsd -remote npipe:server=&lt;EM&gt;&amp;lt;machine name&amp;gt;&lt;/EM&gt;,pipe=w3wp&amp;lt;debugger PID&amp;gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;where &amp;lt;debugger PID&amp;gt; is the PID of the ntsd.exe process under which the worker process is running. In the above example, it will be 1308. Lot of people confuse this with the PID of the worker process which doesn't work.&lt;/P&gt;
&lt;P mce_keep="true"&gt;Note: It is recommended that you match the bitness of debugger with the bitness of w3wp.exe. I mean that if you are running 32 bit worker process on 64 bit OS (in wow64), you should use 32 bit debuggers. In this case, install 32 bit debuggers on the machine and use the following registry key:&lt;/P&gt;
&lt;P mce_keep="true"&gt;"HKEY_LOCAL_MACHINE\SOFTWARE\&lt;STRONG&gt;Wow6432Node&lt;/STRONG&gt;\Microsoft\Windows NT\CurrentVersion\Image File Execution Options"&lt;/P&gt;
&lt;P mce_keep="true"&gt;Note: This behavior for wow64 debugging is going to change for next version of windows (win7). I will blog about the new behavior when win7 releases.&lt;/P&gt;&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=2355597" width="1" height="1"&gt;</description><category domain="http://blogs.iis.net/cpattekar/archive/tags/ntsd/default.aspx">ntsd</category><category domain="http://blogs.iis.net/cpattekar/archive/tags/IFEO/default.aspx">IFEO</category><category domain="http://blogs.iis.net/cpattekar/archive/tags/Debug/default.aspx">Debug</category><category domain="http://blogs.iis.net/cpattekar/archive/tags/Image+File+Execution+Options/default.aspx">Image File Execution Options</category><category domain="http://blogs.iis.net/cpattekar/archive/tags/Debugging/default.aspx">Debugging</category></item><item><title>Stress testing IIS</title><link>http://blogs.iis.net/cpattekar/archive/2008/05/08/stress-testing-iis.aspx</link><pubDate>Thu, 08 May 2008 23:02:00 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:2346951</guid><dc:creator>cpattekar</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.iis.net/cpattekar/rsscomments.aspx?PostID=2346951</wfw:commentRss><comments>http://blogs.iis.net/cpattekar/archive/2008/05/08/stress-testing-iis.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;As promised in my first blog, I am writing about stress testing IIS in this blog.&lt;/P&gt;
&lt;P mce_keep="true"&gt;The idea behind IIS stress testing is to bombard the server with multiple simultaneous requests of different kind so that the CPU usage goes to 100%. This helps detecting memory leaks, access violations and deadlocks. &lt;/P&gt;
&lt;P mce_keep="true"&gt;There is a fine line between stress testing and reliability testing. In stress testing, the response of the server for every request doesn't matter as long as we&amp;nbsp;verify that a few of the responses are as expected. As I said the main aim of stress testing is to keep the CPU pegged without too much worrying about the response. In reliability also, we hit the server to keep it busy, but we don't want to hit it as hard.&amp;nbsp;In reliability testing,&amp;nbsp;we validate each and every response coming back from the server to make sure it is as expected.&lt;/P&gt;
&lt;P mce_keep="true"&gt;Talking about stress, while the machine is being bombarded by requests, we make a few simple requests called Stress Verification Tests (SVTs) every 15 minutes and validate them to make sure server is responding as expected. We also run a script in parallel that fetches various performance counters like&amp;nbsp;memory usage, handle count etc and validate them to make sure they are in the acceptable range.&lt;/P&gt;
&lt;P mce_keep="true"&gt;We have setup the server and its multiple physically separate clients on the same rack so that we get enough throughput. To begin with, we create multiple sites, applications and app pools with a variety of settings&amp;nbsp;on the server. Then we start our script to monitor performance counters. We make a single pass of SVTs before starting stress on the server to make sure all configuration is good. We the start the clients that use WCAT (available on iis.net for download). WCAT is web capacity analyzer tool that bombards the server using multiple threads. I will try to blog about WCAT in a separate blog.&lt;/P&gt;
&lt;P mce_keep="true"&gt;We have multiple types of stress runs, some are overnight and some run for 3 weeks. When a run doesn't hit any failure for the duration of run, we consider that passed. Most of the failures&amp;nbsp;get caught&amp;nbsp;if an SVT fails or if there is an AV in the worker process or if there is a performance counter that is outside of expected range. &lt;/P&gt;
&lt;P mce_keep="true"&gt;SVT failures can be quite challenging because we might have overstressed the server and there is no way server can respond to SVT request. These are just like a false alarm. There is not much anyone can do here.&lt;/P&gt;
&lt;P mce_keep="true"&gt;For nightly stress runs, we have 100+ servers and each server has 1 or more clients. Managing all these machines is a big challenge. We have a nice logging mechanism that logs the status of these runs to a database and a web application as a UI. We also log few interesting performance counters to the database and view graphs of those performance counters in the web application that uses silverlight for charting. Worker processes run under debugger with some special debugger extensions that directly logs about&amp;nbsp;failures to the database. Everything is automated!&lt;/P&gt;
&lt;P mce_keep="true"&gt;Why do we need 100+ runs every night? The stress client uses different kinds of requests for different runs. Some runs use CGI requests, some runs use plain HTM requests, some runs use ASP, some runs use ASPNET, some runs use combination of these. It is not necessary that if one run that uses HTM requests fails, all will fail. Different machines have different hardware configuration, so one might fail but others might pass. We also have different settings in IIS config so that may give us different results. E.g. if FREB is enabled, server may get more stressed because worker process is doing more work per request.&lt;/P&gt;
&lt;P mce_keep="true"&gt;Stress testing is overwhelming but I hope the reader of this blog got an idea of what it is and the challenges we face. In the next blog, I will write more about WCAT.&lt;/P&gt;&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=2346951" width="1" height="1"&gt;</description><category domain="http://blogs.iis.net/cpattekar/archive/tags/WCAT/default.aspx">WCAT</category><category domain="http://blogs.iis.net/cpattekar/archive/tags/Stress/default.aspx">Stress</category></item><item><title>Who is CJ Pattekar from IIS Team?</title><link>http://blogs.iis.net/cpattekar/archive/2008/05/08/who-is-cj-pattekar-from-iis-team.aspx</link><pubDate>Thu, 08 May 2008 22:22:00 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:2346921</guid><dc:creator>cpattekar</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://blogs.iis.net/cpattekar/rsscomments.aspx?PostID=2346921</wfw:commentRss><comments>http://blogs.iis.net/cpattekar/archive/2008/05/08/who-is-cj-pattekar-from-iis-team.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;Hello,&lt;/P&gt;
&lt;P mce_keep="true"&gt;A year ago I setup my account on IIS.net so that I could write blog and answer&amp;nbsp;questions from IIS customers on forums. But the main focus at that time was to ship Windows Server 2008 and then the focus switched to shipping IIS out of band modules. Although the shipping process doesn't stop and there will always be something that takes higher priority, I feel this is about the time I should start interacting with IIS customers through various channels. The obvious one is &lt;A href="http://www.iis.net/"&gt;www.iis.net&lt;/A&gt;. So I am jumping in and writing&amp;nbsp;my first blog here.&lt;/P&gt;
&lt;P mce_keep="true"&gt;My full name is Chittaranjan Pattekar and I am from India. I have shortened my first name to CJ for the convenience of my collegues :). I did my masters in computer science from Syracuse university in NY state.&amp;nbsp;I have been working with the IIS "test" team for last 2+ years.&lt;/P&gt;
&lt;P mce_keep="true"&gt;I own stress, reliability and some internal tools to image our test machines. I also own testing some legacy IIS features like performance counters and CGI, but most of my time is spent in stress testing IIS and maintaining the infrastructure tools.&lt;/P&gt;
&lt;P mce_keep="true"&gt;In my next blog, I will write about IIS Stress testing tools and challenges.&lt;/P&gt;
&lt;P mce_keep="true"&gt;-CJ&lt;/P&gt;&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=2346921" width="1" height="1"&gt;</description></item></channel></rss>