7
votes

I created a windows azure worker role. I used the default templates and the default app.config for the worker role.

 <add type="Microsoft.WindowsAzure.Diagnostics.DiagnosticMonitorTraceListener,      Microsoft.WindowsAzure.Diagnostics, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
                name="AzureDiagnostics">
 </add>

The worker role is using Trace.TraceInformation to log messages.

In which file does the information get logged?

3

3 Answers

8
votes

Diagnostics data collected by your roles is stored in Windows Azure Storage Tables & Blob Containers. Assuming you have configured diagnostics properly, you should see a table called WADLogsTable in a storage account specified via Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString config setting in your role's cscfg file. This is where you will see the data. You may find this link helpful regarding configuring diagnostics for your worker role: http://msdn.microsoft.com/en-us/library/windowsazure/gg433048.aspx.

6
votes

If you see just your TraceError messages but not your TraceInformation then you should change the diagnostics settings of the role in your cloud project.

  • Goto your cloud project, select the role in question and properties
  • Goto Configuration tab and click Configure button

There you should see under General tab "Select a diagnostic configuration" section.

There you should select All information radio button to see TraceInformation.

0
votes

With addition to above step, select Storage account in Configuration tab so that it will get automatically gets added into settings tab under Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString