You can manage Simple Log Service resources, such as projects and logstores, by using the console, APIs, SDKs, or the CLI.
Prerequisites
-
You have an Alibaba Cloud account. If you do not have one, see Create an Alibaba Cloud account.
-
To activate Simple Log Service, log on to the Simple Log Service console and follow the on-screen instructions.
NoteWhen you activate Simple Log Service, Simple Log Service automatically creates a service-linked role named
AliyunServiceRoleForSLSAudit. For more information, see Manage the AliyunServiceRoleForSLSAudit service-linked role. -
If you use APIs, SDKs, or the CLI to manage Simple Log Service, you must create an AccessKey. For more information, see Obtain an AccessKey.
-
If you use a RAM user to manage Simple Log Service, you must create a RAM user and grant it permissions. For more information, see Create a RAM user and grant permissions.
Resource management
A project is the top-level resource container in Simple Log Service. It can contain various types of stores, such as a logstore, metricstore, or eventstore, and serves as the access endpoint for Simple Log Service resources. Resource management allows you to adjust the resource quota at the project level to control costs and prevent resource idling, modify the number of shards at the store level to ensure service performance, group resources using resource groups and tags, and enable transfer acceleration for long-distance log transmission.
-
Create and manage projects.
-
You must first create a project in a specific region that suits your business needs. For more information, see Manage projects.
-
Simple Log Service allows you to dynamically adjust quotas for a project. If your resource quota is insufficient, you can increase it to meet your needs. For details, see Adjust resource quotas. To determine if a change is needed, see Resource throttling and solutions.
-
-
Create storage resources.
-
To store log data, create a logstore. For more information, see Create a basic logstore.
-
To store time-series data, create a metricstore. For more information, see Create a metricstore.
-
To store event data, create an eventstore. For more information, see Manage an eventstore.
-
-
Simple Log Service uses shards to control the read and write throughput of logstores, eventstores, and metricstores. You can adjust the number of shards to scale the service's read/write capacity. For more information, see Manage shards.
-
If you experience slow transmission when sending logs over long distances, such as from an overseas region to a region in the Chinese mainland, you can enable transfer acceleration to improve performance. For more information, see Manage transfer acceleration.
-
Simple Log Service allows you to use resource groups to isolate access permissions for different scenarios and manage them at the group level. For more information, see Set up a resource group and Manage tags.
Comparison of logstore, metricstore, and eventstore
|
Store type |
Data type |
Use cases |
Related links |
|
logstore |
General-purpose logs |
Used to store logs generated by applications or systems, such as error logs and access logs. |
|
|
metricstore |
Time-series data that follows the Prometheus data model, including conventions for metric naming, labeling, and data retention policies. |
Used to store performance metrics from systems or applications, such as CPU utilization and memory usage. |
|
|
eventstore |
Event data that conforms to the CloudEvents specification. |
Used to store events from systems or applications, such as user clicks and transaction records. |