Skip to content

FAQs


Metrics Collection

How to check if metrics are successfully reported?

You can verify through the following methods:

  • Console: Go to Metrics > Metrics Management to check if the corresponding Measurement exists.
  • Command line: Execute datakit monitor to view the collector's running status.
  • Logs: Check DataKit logs tail -f /var/log/datakit/log.

What to do if metric data is not collected?

  1. Check DataKit running status: systemctl status datakit.
  2. Check if the collector configuration is correct: the corresponding collector configuration in the /usr/local/datakit/conf.d/ directory.
  3. Check network connectivity: whether DataKit can normally access the data source.
  4. Check DataKit logs to troubleshoot errors.

How to integrate Prometheus metrics into TrueWatch?

Three methods are supported:

  • Directly push to DataKit via Prometheus Remote Write.
  • Push via Prometheus Push Gateway.
  • Deploy Prometheus Exporter in Kubernetes, and let DataKit collect automatically.

Metrics Management

What is the impact of having too many Time Series?

The number of Time Series directly affects:

  • Storage Cost: More Time Series lead to higher storage costs.
  • Query Performance: A large number of Time Series may cause slower queries.

It is recommended to optimize tag design and avoid using high-cardinality tags (such as dynamic values like user_id, ip). Official tag specifications prohibit dynamic tags, allowing only static business tags (e.g., env, project).


How to modify the metric storage duration?

  • Global Setting: Management > Workspace Settings > Risky Operations > Change Data Storage Policy > Metrics.
  • Single Measurement Setting: Metrics > Metrics Management > Click the storage policy icon on the right side of the Measurement.

Each policy modification triggers immediate data deletion. Data for that Measurement under the original policy will be permanently deleted and cannot be recovered. The custom setting for a Measurement has higher priority than the workspace global setting.


How to modify metric units and descriptions?

Go to Metrics > Metrics Management, click the Measurement name to expand the metric list, then click the edit button in the Options column to modify units and descriptions. The units and descriptions customized in Metrics Management have higher priority than the default collected data.


Generated Metrics

Why can't I query data after generating metrics?

Possible reasons:

  • The generation rule is not enabled.
  • The data source has no data within the query time range.
  • Data delay exceeds 1 minute (Generated Metrics do not count data delayed by more than 1 minute).
  • You do not have the "Generated Metrics Configuration Management" permission.

How to choose the frequency for generating metrics?

  • 1 minute: Suitable for scenarios requiring high real-time performance (default).
  • 5 minutes: Suitable for basic objects and Resource Catalog (default).
  • 15 minutes: Suitable for trend analysis, scenarios not requiring high real-time performance.

Lower frequency results in fewer Time Series and lower storage costs.


Which data sources are supported for generating metrics?

Supports generating metrics from the following data sources:

  • LOG
  • APM
  • RUM
  • Metrics (calculate new metrics based on existing metrics)
  • Synthetic Tests
  • Basic Objects (HOST, CONTAINERS, etc.)
  • Resource Catalog

General Questions

How long is metric data retained?

Default retention is 7 days, customizable:

  • Commercial Plan: 3 days, 7 days, 14 days, 30 days, 180 days, 360 days, 720 days, 1080 days.
  • Deployment Plan: Supports any integer from 1 to 1800 days.

How to optimize metric storage costs?

  1. Reasonably set storage policies, shorten retention time for non-core metrics.
  2. Optimize tag design, avoid high-cardinality tags (follow the prohibition of dynamic tags specification).
  3. Use Generated Metrics to aggregate raw data, reducing the number of Time Series.
  4. Regularly clean up unused Measurements.

What is the difference between DQL and PromQL?

  • DQL: TrueWatch's self-developed query language, supports simple queries, expression queries, with concise syntax.
  • PromQL: Prometheus native query language, additionally supported for metric data.

Both can be used in metric analysis and visual charts.