You can use metrics to troubleshoot applications and monitor their performance. You can create a configuration to extract metrics from logs and post these metrics to a metric store. VMware Aria Operations for Logs (SaaS) supports only Wavefront as a metric store.
- Log in to your Wavefront instance.
- Copy the Wavefront URL, for example, symphony.wavefront.com. You must use this URL in the Send To text box in the metric extraction configuration.
- If you do not have an API token for your Wavefront account, generate the token by following the instructions in https://docs.wavefront.com/users_account_managing.html.
- Copy the API token. You must use this token in the API Key text box in the metric extraction configuration.
- Click the two arrows icon in the upper-left corner of the screen to expand the main menu.
- Click Explore Logs.
- Enter a query and click the Search button to view the results.
You can select a time period and use filters for more specific query results. For more information, see Searching for Logs.
- On the Stream tab under the chart, locate a log.
- Click the three dots icon for the log and select Create Metric.
- Provide the following information to configure metric extraction:
Option Description Name A name for the metric extraction configuration. Enabled A toggle that enables or deactivates the metric extraction configuration. The toggle is green when the configuration is enabled and gray when it is deactivated. If deactivated, the metrics for the configuration are not sent to the metric store. Send To The metric store URL. API Key The API token from the metric store. Source Type The log filtering criteria. Pattern When you select a log in the Explore Logs page to configure metric extraction, the system recommends matching grok patterns in this drop-down menu. A grok pattern is a named regular expression pattern for parsing logs.
You can select one of the recommended grok patterns. If none of the recommended patterns match your log, you can write your own grok pattern in the text area under the drop-down menu.
After defining the grok pattern, click Parse to see the metrics that can be extracted from your log based on the pattern. The system displays the list of numeric metrics that you can send to the metric store, for example, avgbandwidth, avgiops, and avglatencyinms. You can configure each of these metrics in the Metric Values to Send section.
Sample Message This text area is auto-populated with the text from your selected log.
- Provide the following information in the Metric Values to Send section to configure the metrics that you want to send to the metric store:
Option Description Value Select a field from the drop-down menu whose value is sent to the metric store. Name The name for the metric in the metric store. Source Tag A single value that represents the source of the logs in a metric store.
To add a source tag, click Configure Source Tag. In the pop-up window, configure an expression by selecting fields under Available Fields (Parsed or Metadata). These fields are the parsed text fields from your selected log and log metadata. You can also use custom static string values with the fields to build the expression in the text box.Note: Because the fields are enclosed in the characters "<" and ">", you cannot use these characters in the static string.
For example, consider the following expression:
sddc-is a static string and
<sub_component>are the fields parsed from your selected log or metadata.
This expression evaluates to:
Click Verify to test the source tag configuration and then click Save.
A key-value pair sent to a metric store, which is used to filter the metrics in the chart.
Select one or more point tags for the metric from the drop-down menu. The point tags in the drop-down menu are populated by using text fields parsed from your selected log based on your grok expression and the metadata of the log.
- To configure more metrics, click Add Metric Value and repeat step 7.
- Click Save.