This topic describes how to create, modify, and delete a Metricstore in the Log Service console.


A project is created. For more information, see Create a project.

Create a Metricstore

  1. Log on to the Log Service console.
  2. In the Projects section, click the name of the project that you want to view.
  3. On the Time Series Storage > Metricstore tab, click the + icon.
  4. In the Create Metricstore panel, configure the following parameters and click OK.
    Parameter Description
    Metricstore Name The name of the Metricstore. The name must be unique in the project to which the Metricstore belongs. After the Metricstore is created, you cannot change its name.
    Permanent Storage If you turn on Permanent Storage, Log Service permanently stores the collected metrics.
    Note You can use an SDK to query the data retention period. If the value is 3650, the metrics are permanently stored.
    Data Retention Period The retention period of the collected metrics in the Metricstore. Valid values: 15 to 3000. Unit: days. When metrics are stored for a period that exceeds the value of this parameter, the metrics are automatically deleted.

    You can configure the Data Retention Period parameter only if you do not turn on Permanent Storage.

    Note If you shorten the data retention period, Log Service deletes all expired metrics within 1 hour. The data volume that is displayed for Storage Size(Log) on the homepage of the Log Service console is updated the next day. For example, if you change the value of the Data Retention Period parameter from 5 to 1, Log Service deletes the metrics of the previous four days within 1 hour.
    Shards The number of shards. Log Service provides shards that allow you to read and write data. Each shard supports a write speed of 5 MB/s, 500 write operations per second, a read speed of 10 MB/s, and 100 read operations per second. You can create up to 10 shards in each Metricstore. You can create up to 200 shards in each project. For more information, see Shard.

Modify the configurations of a Metricstore

  1. On the Time Series Storage > Metricstore tab, find the Metricstore whose configurations you want to modify and choose Modify Logstore > Modify.
  2. On the Metricstore Attribute page, click Modify.
    • Change the data retention period. For more information, see Create a Metricstore.
    • Manage shards.

      After a Metricstore is created, two shards are created in the Metricstore by default. You can split or merge the shards based on your business requirements. For more information, see Manage shards.

  3. Click Save.

Delete a Metricstore

  • Before you can delete a Metricstore, you must delete all Logtail configuration files that are associated with the Metricstore.
  • If the data shipping feature is enabled for the Metricstore, we recommend that you stop writing data to the Metricstore and make sure that all data in the Metricstore is shipped before you delete the Metricstore.
  • If you are not authorized to delete a Metricstore by using your Alibaba Cloud account, submit a ticket to contact technical support.
  1. On the Time Series Storage > Metricstore tab, find the Metricstore that you want to delete and choose Modify Logstore > Delete.
    Warning After you delete a Metricstore, all metrics in the Metricstore are deleted and cannot be restored. Proceed with caution.
  2. In the message that appears, click OK.