The page has been translated by Gen AI.

Custom metrics and logs

ServiceWatch can collect custom metrics defined by the user and can collect log files from resources created by the user.

There are two ways to collect custom metrics and logs.

The first method is to install the ServiceWatch Agent directly on the resource, configure the resources to be collected, and then collect them.
The second method allows you to collect custom metrics and logs via the OpenAPI/CLI provided by ServiceWatch.

Reference
Custom metric/log collection via the ServiceWatch Agent is currently available only on Samsung Cloud Platform For Enterprise. It will also be available in other offerings in the future.
Caution

The ServiceWatch metrics API incurs a cost per call. Collecting metrics via the ServiceWatch Agent also operates on an OpenAPI basis, so there is a cost associated with metric API calls.
Caution is required to avoid excessive API calls for metric and log collection. The billing target metric APIs are listed below.

APIExplanation
ListMetricDataRetrieve metric data list.
  • Since multiple metrics can be requested in a single API call, a fee is charged per 1,000 metric requests
DownloadMetricDataImageIndicator data widget image download.
  • Since multiple indicators can be requested in a single API call, a fee is charged per 1,000 requested indicators
ListMetricInfosMetric data retrieval.
  • This API incurs a charge per 1,000 calls
CreateCustomMetricMetasCreate custom metric metadata
  • This API is charged per 1,000 calls
CreateCustomMetricsCustom metric data creation (transmission)
  • This API incurs a charge per 1,000 calls
ShowDashboardDashboard view
  • This API incurs a charge per 1,000 calls
ListDashboardsRetrieve dashboard list
  • This API incurs a charge per 1,000 calls
CreateDashboardCreate dashboard
  • This API is charged per 1,000 calls
SetDashboardDashboard edit
  • This API is charged per 1,000 calls
DeleteBulkDashboardsDelete dashboard
  • This API is charged per 1,000 calls
표. 지표 API 과금 안내

Since logs incur charges based on the amount collected, there are no additional fees for API calls.

※ For detailed pricing information, refer to the ServiceWatch pricing details on the Samsung Cloud Platform Service Portal.

ServiceWatch Agent

You can install the ServiceWatch Agent on user resources such as Virtual Server, GPU Server, Bare Metal Server, etc., to collect custom metrics and logs.

ServiceWatch Agent Constraints

ServiceWatch Agent Network Environment

The ServiceWatch Agent is designed to collect data using OpenAPI by default, and therefore, to be installed and used on server resources, it must be able to communicate externally via the Internet. Please create an Internet Gateway in the VPC where the resources are located and configure a NAT IP for the server resources so they can communicate with the external network.

ServiceWatch Agent supported OS Image

The OS images available for the ServiceWatch Agent are as follows.

OS Image versionEOS Date
Alma Linux 8.102029-05-31
Alma Linux 9.62025-11-17
Oracle Linux 8.102029-07-31
Oracle Linux 9.62025-11-25
RHEL 8.102029-05-31
RHEL 9.42026-04-30
RHEL 9.62027-05-31
Rocky Linux 8.102029-05-31
Rocky Linux 9.62025-11-30
Ubuntu 22.042027-06-30
Ubuntu 24.042029-06-30
Windows 20192029-01-09
Windows 20222031-10-14
Table. OS Images Supported by ServiceWatch Agent

It is provided identically to the OS image provided by the Virtual Server. Please refer to the Virtual Server > OS Image 제공 버전.

Quick Guide for Using ServiceWatch Agent

Below, we introduce a quick guide for collecting OS metrics and logs of a Virtual Server in a Linux environment.

Installing and Configuring Node Exporter

  1. Refer to Node Exporter 설치 to install Node Exporter on the server for collecting custom metrics.
    • When you install Node Exporter, you can collect OS metrics through Node Exporter in addition to the metrics provided by ServiceWatch’s default monitoring.
  2. Refer to ServiceWatch Agent 설정, download the ServiceWatch_Agent archive, and then configure and run ServiceWatch Manager.
    • By referring to the examples/os-metric-min-examples folder in the archive, you can run the ServiceWatch Agent by configuring at least two metrics.
Caution

Collecting metrics through the ServiceWatch Agent is classified as custom metrics, and unlike the default metrics gathered from each service, it incurs charges, so you should be careful not to configure unnecessary metric collection. Make sure to configure it so that only the metrics that need to be collected are collected.

  • Free provision is available up to 10 per Account/region.
Reference
For detailed information on using the ServiceWatch Agent, refer to the How-to guides > ServiceWatch Agent 사용하기.

ServiceWatch custom metrics and logs API

You can collect custom metrics and logs using the OpenAPI/CLI provided by ServiceWatch.

You can deliver custom metric data and custom logs to ServiceWatch via the ServiceWatch OpenAPI/CLI, and view the visualized information in the Console.

Caution

Collecting metrics through ServiceWatch OpenAPI/CLI is classified as custom metrics, and unlike the default metrics gathered from each service, it incurs charges, so you should be careful not to configure unnecessary metric collection. Make sure to configure it so that only the metrics that need to be collected are collected.

  • Free provision is available up to 10 per Account/region.

Create custom metric metadata

To collect metric data generated from a user’s resources or applications—not the metrics provided by Samsung Cloud Platform services (e.g., Virtual Server)—into ServiceWatch, you must create custom metric metadata.

ParameterExplanation
namespaceUsers can define a namespace in ServiceWatch that distinguishes it from other metrics
  • The namespace must be 3 to 128 characters long, consisting of letters, numbers, spaces, and special characters (_-/), and must start with a letter.
metricMetas > metricNameSet the name of the metric to be collected. The metric name must be 3 to 128 characters long, consisting of letters, numbers, and special characters (_), and must start with a letter.
  • Example: custom_cpu_seconds_total
metricMetas > storageResolutionSet the collection interval for the relevant metric. The default is 60 (1 minute) and can be configured in seconds.
metricMetas > unitAbility to set the unit of the metric
  • Example: Bytes, Count, etc
metricMetas > dimensionsYou can set dimensions to identify custom metric data and visualize it in the Console. When visualizing collected metrics in the Console, they are displayed in combinations based on the dimension (dimensions) settings.
metricMetas > descriptionKoKorean description of the collected metrics
metricMetas > descriptionEnEnglish description of the metrics being collected
표. 사용자 정의 지표 메타 데이터 파라미터 설명

For detailed information on creating custom metric metadata, see CreateCustomMetricMetas.

Create custom metric

After generating custom metric metadata, you can deliver the resulting metric data to ServiceWatch using the CreateCustomMetrics API.

The transmitted metric data can be queried, separated by the configured namespace.

For detailed information on generating custom metric data, see CreateCustomMetrics.

Indicator Data Query

Metric data, including custom metrics, can be retrieved using the Console and the ListMetricInfos, ListMetricInfos API.

For detailed information on retrieving metric data, refer to ListMetricInfos and ListMetricData.

Create log stream

A ServiceWatch log group is required for custom log collection. Log groups can only be created in the Console. You can create a log stream for delivery to ServiceWatch by first creating a log group and then using the log stream creation API.

For detailed information on creating a log stream, refer to CreateCustomLogStream.

Create log event

To collect custom logs, after creating a log group and log stream, we use the log event creation API to deliver individual log messages (log events) to ServiceWatch.

For detailed information on creating log events, refer to CreateCustomLogEvents.

ServiceWatch integration service
How-to guides