Jeff Sanders Technical Blog

I am a Microsoft employee that has worked on all aspects of the Web Stack for a long time. I hope these blogs are useful to you! Use this information at your own risk.


<< Go Back

My Favorite System Net Trace Configuration File Dumps Process Id And Date Time Information

- 24 Mar 2009

Often you need to correlate a .NET trace with a <a title=”Netmon” href=”http://www.microsoft.com/downloads/details.aspx?FamilyID=f4db40af-1e08-4a21-a26b-ec2f4dc4190d&DisplayLang=en” target=”_blank” mce_href=”http://www.microsoft.com/downloads/details.aspx?FamilyID=f4db40af-1e08-4a21-a26b-ec2f4dc4190d&DisplayLang=en”>Netmon</a> trace.  To do that you need the date and time of the call from the <a title=”System.Net trace” href=”http://msdn.microsoft.com/en-us/library/ty48b824.aspx” target=”_blank” mce_href=”http://msdn.microsoft.com/en-us/library/ty48b824.aspx”>System.Net trace</a>.  This will do it!

NOTE:  This section is configures where the log file is and where it should be written: initializeData=”System.Net.trace.log”
Specify the path and file name and make sure the process running has permissions to write that file in the location you specify!<p mce_keep="true"> </p>

Copy Code:


   
       
               
               
                       
               
                       

                </source>
               
                       
               
                       

                </source>
       
                       
               
                       

                </source>
       
                       
               
                       

                </source>
               

       
                <add
                 name="System.Net"
                 type="System.Diagnostics.TextWriterTraceListener"
                  initializeData="System.Net.trace.log"
                 traceOutputOptions = "ProcessId, DateTime"
                />
       

   
       
       
       
       
   

   

</p>

Hint.  If Verbose is too verbose you can change that value to one of these:

Critical, Error, Verbose, Warning, and Information.

Ref: How to: Configure Network Tracing

If you find this useful, please drop me a note in the comments!

<< Go Back