Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive

Querying Archived Traces

Updated on 2024-12-27 GMT+08:00

Scenarios

CTS periodically sends trace files to OBS buckets. A trace file is a collection of traces. CTS generates trace files based on services and transfer cycle, and adjusts the number of traces contained in each trace file as needed. CTS can also save audit logs to LTS log streams.

This section describes how to view historical operation records in trace files downloaded from OBS buckets and in LTS log streams.

Prerequisites

You have configured a tracker in CTS and enabled Transfer to OBS or Transfer to LTS. For details, see Configuring a Tracker.

Querying Traces Transferred to OBS

If you enable Transfer to OBS when configuring the tracker, traces will be periodically transferred to a specified OBS bucket as trace files for long-term storage.

  1. Log in to the management console.
  2. Click in the upper left corner and choose Management & Deployment > Cloud Trace Service. The CTS console is displayed.
  3. Choose Tracker List in the navigation pane on the left.
  4. Click a bucket in the OBS Bucket column.
  5. In the OBS bucket, locate the file storage path to view the desired trace, and click Download on the right to download the file to the default download path of the browser. If you need to save it to a custom path, click More > Download As on the right.
    • The trace file storage path is as follows:

      OBS bucket name > CloudTraces > Region > Year > Month > Day > Tracker name > Service directory

      An example is User-defined name > CloudTraces > region > 2016 > 5 > 19 > system > ECS.

    • The trace file naming format is as follows:

      Trace file prefix_CloudTrace_Region/Region-project_Time when the trace file was uploaded to OBS: Year-Month-DayTHour-Minute-SecondZ_Random characters.json.gz

      An example is File Prefix_CloudTrace_region-project_2016-05-30T16-20-56Z_21d36ced8c8af71e.json.gz.

    NOTE:

    The OBS bucket name and trace file prefix are user-defined, and other parameters are automatically generated.

    Downloading the file will incur request fees and traffic fees.

    For details about key fields in the CTS trace structure, see Trace Structure and Example Traces.

  6. Decompress the downloaded package to obtain a JSON file with the same name as the package, as shown inFigure 1. Open the JSON file using a text file editor to view traces.
    Figure 1 JSON file

Querying Traces Transferred to LTS

If you enable Transfer to LTS when configuring a tracker, traces will be transferred to the CTS/{Tracker Name} log stream for long-term storage. {Tracker Name} indicates the name of the current tracker. For example, the log stream path of the management tracker is CTS/system-trace.

  1. Log in to the management console.
  2. Click in the upper left corner and choose Management & Deployment > Cloud Trace Service. The CTS console is displayed.
  3. Choose Tracker List in the navigation pane on the left.
  4. Click an LTS log stream in the Storage column.
  5. On the Log Stream tab page in the CTS log group page, select the {Tracker name} log stream to view trace logs.

    For details about key fields in the CTS trace structure, see Trace Structure and Example Traces.

  6. Click to download the log file to your local PC.

    NOTE:

    Each time you can download up to 5,000 log events. If the number of selected log events exceeds 5000, you cannot download them directly from LTS. Transfer them to OBS and then download them from OBS.

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback