CodeTrack: Profiling a process hosted in IIS Express
This can be used to profile any .NET code that is hosted within IIS Express.
- Select the collect tab (on the left of the application)
- Select ‘IIS Express’ and click the arrow on the right to go to the next step.
Note that IIS Express tracing is available from v22.214.171.124 !
- Click on the globe button to select the website you want to profile.
Now you can select the website you want to trace.
Codetrack gets iis express sites in 2 ways: by looking at which iisexpress processes are running and by looking in the specified
If your site is not listed there are 2 possible reasons:
- The iis express config file is not correct.If it's not the machine config (usually in C:\Program
Files\IIS Express\config), it might be located in the.vs\config\ folder in your project folder.You
can also select your Visual Studio solution file, codetrack will then try to find the right config.
- Currently your site is not running (or it is and you need to press the refresh button in the lower
When you selected your site, press OK. The bittness and DotNet version should be selected automatically.
Should this be incorrect, you can still change this manually.
Now click the arrow on the right to go to the next step.
Now it's time to decide upon your level of detail. Important to remember, is that the more detail you require, the higher
the impact profiling will have on your performance. If you just started investigating a problem, it might
be a good idea to use the sampling option. Since this will be the most performant profiling mode. From this
information you can then start another session with much more detail, profiling only the code that causes
the performance issue. By default Codetrack will not trace code executed in IISExpressTray.exe. (It will
still apear in the tracing stats, but it will be excluded from the resulting data)
For more information about the different profiling settings, read
Now we are ready for the last step, click on the right arrow to continue.
In this last section you need to select the destination of the profiling data. (Make sure you select a location with enough
space if you profile with lots of detail).
If you need to profile on a very slow machine,one with little RAM, or a production server, you can disable
the processing of the data. This allows you to do the number crunching offline on another machine.
If you want to start profiling immediately, make sure you click the record button, otherwise click the
pause button and hit record from the moment you want to start capturing data.
Now you are ready to start profiling. If you click the play button, IIS express will be restarted (this
might take a while). Now you can browse to your website (you can use the iis express tray in your system
tray to open your browser).
If you press the stop button Codetrack will stop IIS express (again: this might take a while).