Microsoft Operations Management Suite Cookbook
上QQ阅读APP看书,第一时间看更新

How to do it...

Perform the following steps:

  1. Navigate to the Azure portal (http://portal.azure.com) and sign in.
  2. In the Azure portal, type Log Analytics in the Search resources search field and select your workspace.
  3. In the Log Analytics blade for your workspace, click the Log Search button to take you to the search field.
  4. In the Log Search page, click on the Advanced Analytics link under the search box to take you to the Analytics portal:
Figure 2.14
  1. In the Analytics portal, click on the + button to open a new query tab:
Figure 2.15
  1. In the new query field, type the following query into the search field:
union withsource=type *
| where TimeGenerated > ago(48h)
| summarize AggregatedValue = count() by type
  1. Click the Go button in the upper right hand corner of your screen to return a distribution of your data over the last 48 hours. By default, the results are displayed in a table:
Figure 2.16
  1. Click CHART to chart the result, and to see the results in a stacked bar chart view:
Figure 2.17
  1. Click Stacked Column and select Doughnut to show another view of the results:
Figure 2.18
  1. Return to the search field in the same page and add a new line with the render tabular operator to render the data as a pie chart:
union withsource=type *
| where TimeGenerated > ago(48h)
| summarize AggregatedValue = count() by type
| render piechart
  1. Click the Go button in the upper right hand corner of your screen to return a distribution of your data over the last 48 hours, rendered as a pie chart:
Figure 2.19