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

CCE Dashboard Templates

Updated on 2024-11-18 GMT+08:00

CCE provides highly scalable, high-performance, enterprise-class Kubernetes clusters.

CCE dashboard templates support Viewing CCE Logs: Node Operations, Viewing CCE Logs Kubernetes Object Operations, Viewing CCE Logs Kubernetes Event Queries, Viewing CCE Logs Kubernetes Event Center, Viewing CCE Logs Aggregation Search, Viewing CCE Logs Account Operations, and Viewing CCE Audit Log Center.

Prerequisites

Viewing CCE Logs: Node Operations

  1. Log in to the LTS console. In the navigation pane, choose Dashboards.
  2. Choose CCE dashboard templates under Dashboard Templates and click CCE Logs: Node Operations to view the chart details.

    • Filter by node name. The associated query and analysis statement is:
      select distinct("objectRef.name")
    • Filter by user. The associated query and analysis statement is:
      select distinct("user.username")
    • Filter by status code. The associated query and analysis statement is:
      select distinct("responseStatus.code")
    • Filter by operation type. The associated query and analysis statement is:
      select distinct("verb")
    • Node Quantity Trend. The associated query and analysis statement is:
      SELECT  time_series( TIME_PARSE(LEFT(requestReceivedTimestamp, 23),'yyyy-MM-dd''T''HH:mm:ss.SSS'), 'PT1H', 'yyyy-MM-dd HH', '0' ) as "dt",  count(DISTINCT("objectRef.name")) as "Nodes" where "objectRef.resource" = 'nodes'  and "objectRef.subresource" = 'status'  and "verb" in ('update', 'patch') and "user.username" = 'system:node' group by   "dt" order by  "dt" desc limit  10000
    • Non-System User Operation Trend. The associated query and analysis statement is:
      SELECT time_series( TIME_PARSE(LEFT(requestReceivedTimestamp, 23),'yyyy-MM-dd''T''HH:mm:ss.SSS'), 'PT1H', 'yyyy-MM-dd HH', '0' ) as "dt", count(*) as "Requests", "user.username"  where "objectRef.resource" = 'nodes' and "user.username" not in ( 'kube-controller-manager','kube-apiserver-kubelet-client','apiserver') and "user.username" not like  'system:%' and "verb" in ('create','delete','update','patch') group by "dt", "user.username" order by "dt","Requests" desc limit 10000
    • create Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "objectRef.resource" = 'nodes' and "verb" = 'create' group by "Status code"
    • delete Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "objectRef.resource" = 'nodes' and "verb" = 'delete' group by "Status code"
    • patch Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "objectRef.resource" = 'nodes' and "verb" = 'patch' group by "Status code"
    • update Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "objectRef.resource" = 'nodes' and "verb" = 'update' group by "Status code"
    • Node Blocking/Unblocking Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*)  as "count" where "requestObject" in ('{"spec":{"unschedulable":false}}','{"spec":{"unschedulable":true}}')  group by "Status code"
    • Label Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where  "objectRef.resource" = 'nodes' and "verb" in ('patch','update') and "requestObject" = 'labels' and "requestObject" = 'metadata' group by "Status code"
    • Taint Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "objectRef.resource" = 'nodes' and "verb" in ('patch','update') and "requestObject" = 'taints' group by "Status code"
    • Eviction Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "objectRef.subresource" = 'eviction' and "objectRef.resource" = 'pods' and "verb" = 'create' group by "Status code"
    • Node Addition/Deletions. The associated query and analysis statement is:
      select  "auditID" AS "Audit ID", "objectRef.name" AS "Node", "verb" AS "Operation", "stageTimestamp" AS "Occurred", "user.username" AS "Operator", "responseStatus.code" AS "Status Code"  where "objectRef.resource" = 'nodes' and "verb" in ('create','delete')
    • Taint Operations. The associated query and analysis statement is:
      select  "auditID" AS "Audit ID", "objectRef.name" AS "Node","requestObject" AS "Taints",  "requestReceivedTimestamp" AS "Occurred", "user.username" AS "Operator", "responseStatus.code" AS "Status Code"  where "objectRef.resource" = 'nodes' and "verb" = 'patch' and "requestObject" = 'taints'
    • Eviction Operations. The associated query and analysis statement is:
      select  "auditID" AS "Audit ID", "objectRef.name" AS "pod", "sourceIPs" AS "Source IP",  "requestReceivedTimestamp" AS "Occurred", "user.username" AS "Operator", "responseStatus.code" AS "Status Code"  where "objectRef.resource" = 'pods' and "verb" = 'create' and "objectRef.subresource" = 'eviction'
    • Label Operations. The associated query and analysis statement is:
      select  "auditID" AS "Audit ID", "objectRef.name" AS "Node", "requestObject" AS "Label", "requestReceivedTimestamp" AS "Occurred", "user.username" AS "Operator", "responseStatus.code" AS "Status Code"  where "objectRef.resource" = 'nodes' and "verb" = 'patch' and "requestObject" = 'labels'
    • Blocking Operations. The associated query and analysis statement is:
      select "auditID" AS "Audit ID", "objectRef.name" AS "Node",  "requestReceivedTimestamp" AS "Occurred", "user.username" AS "Operator", "responseStatus.code" AS "Status Code" where "verb" = 'patch' and "objectRef.resource" = 'nodes' and "requestObject" ='true' and "requestObject" = 'unschedulable'
    • Unblocking Operations. The associated query and analysis statement is:
      select "auditID" AS "Audit ID", "objectRef.name" AS "Node",  "requestReceivedTimestamp" AS "Occurred", "user.username" AS "Operator", "responseStatus.code" AS "Status Code" where "verb" = 'patch' and "objectRef.resource" = 'nodes' and "requestObject" not in ('true','taints','unschedulable')

Viewing CCE Logs Kubernetes Object Operations

  1. Log in to the LTS console. In the navigation pane, choose Dashboards.
  2. Choose CCE dashboard templates under Dashboard Templates and click CCE Logs Kubernetes Object Operations to view the chart details.

    • Filter by namespace. The associated query and analysis statement is:
      select distinct("objectRef.namespace")
    • Filter by operation type. The associated query and analysis statement is:
      select distinct("verb")
    • Filter by status code. The associated query and analysis statement is:
      select distinct("responseStatus.code")
    • Filter by resource object. The associated query and analysis statement is:
      select distinct("objectRef.name")
    • Filter by resource type. The associated query and analysis statement is:
      select distinct("objectRef.resource")
    • Filter by user. The associated query and analysis statement is:
      select distinct("user.username")
    • Major Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(requestReceivedTimestamp, 16),'T',' ') AS "dt", "verb" as "Operation Type", count(*)  as "count" where "verb" in ('create','delete','update','patch') and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by "dt","Operation Type" order by "dt" limit 10000
    • Non-System User Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(requestReceivedTimestamp, 16),'T',' ') AS "dt", count(*) as "Requests ","user.username" WHERE "user.username" not in ('kube-controller-manager','kube-apiserver-kubelet-client','apiserver') and "user.username" not like 'system:%'  and  "verb" in ('create','delete','update','patch')  and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresss','configmaps','secrets','pvcs')  group by "dt", "user.username"  limit 10000
    • create Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource type", count(*) as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • delete Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource Type", count(*) as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • update Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource Type", count(*) as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • patch Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource Type", count(*) as "count" where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • create Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*)  as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • delete Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*) as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • update Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*)  as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"select "user.username" as "User", count(*)  as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • patch Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*)  as "count"  where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • create Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • delete Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • update Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • patch Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*)  as "count" where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • create Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*)  as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000
    • delete Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*)  as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000
    • update Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*) as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000
    • patch Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*)  as "count" where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000

Viewing CCE Logs Kubernetes Event Queries

  1. Log in to the LTS console. In the navigation pane, choose Dashboards.
  2. Choose CCE dashboard templates under Dashboard Templates and click CCE Logs Kubernetes Event Queries to view the chart details.

    • Filter by namespace. The associated query and analysis statement is:
      select distinct("objectRef.namespace")
    • Filter by operation type. The associated query and analysis statement is:
      select distinct("verb")
    • Filter by status code. The associated query and analysis statement is:
      select distinct("responseStatus.code")
    • Filter by resource object. The associated query and analysis statement is:
      select distinct("objectRef.name")
    • Filter by resource type. The associated query and analysis statement is:
      select distinct("objectRef.resource")
    • Filter by user. The associated query and analysis statement is:
      select distinct("user.username")
    • Major Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(requestReceivedTimestamp, 16),'T',' ') AS "dt", "verb" as "Operation Type", count(*)  as "count" where "verb" in ('create','delete','update','patch') and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by "dt","Operation Type" order by "dt" limit 10000
    • Non-System User Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(requestReceivedTimestamp, 16),'T',' ') AS "dt", count(*) as "Requests ","user.username" WHERE "user.username" not in ('kube-controller-manager','kube-apiserver-kubelet-client','apiserver') and "user.username" not like 'system:%'  and  "verb" in ('create','delete','update','patch')  and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresss','configmaps','secrets','pvcs')  group by "dt", "user.username"  limit 10000
    • create Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource type", count(*) as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • delete Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource Type", count(*) as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • update Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource Type", count(*) as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • patch Resources. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource Type", count(*) as "count" where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by  "objectRef.resource"
    • create Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*)  as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • delete Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*) as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • update Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*)  as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"select "user.username" as "User", count(*)  as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • patch Users. The associated query and analysis statement is:
      select "user.username" as "User", count(*)  as "count"  where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "user.username"
    • create Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • delete Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • update Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*) as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • patch Codes. The associated query and analysis statement is:
      select cast("responseStatus.code" as varchar) as "Status code", count(*)  as "count" where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims') group by  "responseStatus.code"
    • create Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*)  as "count" where "verb" = 'create' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000
    • delete Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*)  as "count" where "verb" = 'delete' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000
    • update Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*) as "count" where "verb" = 'update' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000
    • patch Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*)  as "count" where "verb" = 'patch' and "objectRef.resource" in ('deployments','statefulsets','cronjobs','daemonsets','jobs','pods','services','ingresses','configmaps','configmaps','persistentvolumeclaims')  group by dt, "objectRef.resource" order by dt limit 10000

Viewing CCE Logs Kubernetes Event Center

  1. Log in to the LTS console. In the navigation pane, choose Dashboards.
  2. Choose CCE dashboard templates under Dashboard Templates and click CCE Logs Kubernetes Event Center to view the chart details.

    • Event Severity: The options are Warning and Normal.
    • Filter by event type. The associated query and analysis statement is:
      select distinct("name")
    • Filter by cluster ID. The associated query and analysis statement is:
      select distinct("cluster_id")
    • Filter by namespace. The associated query and analysis statement is:
      select distinct("namespace") 
    • Filter by name. The associated query and analysis statement is:
      select distinct("resource_name")
    • Conntrack Full. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'ConntrackFull'  ) )
    • Event Sync Error. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'NTPIsDown') )
    • Insufficient Node PIDs. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name" in ('PIDPressure','NodeHasPIDPressure') ) )
    • Insufficient Node FDs. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'NodeHasFDPressure') )
    • Insufficient Node Disk Space. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'NodeHasDiskPressure') )
    • Pod OOM. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where   "reason" in ('OOMKilling','PodOOMKilling')) )
    • DockerHung. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'Failed' and "reason" = 'DockerHung') )
    • Node Restart. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'NodeRebooted') )
    • Pull Image Failed. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'Failed' and "reason" = 'ImagePullBackOff') )
    • Node OOM. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name" = 'SystemOOM') )
    • Start Pod Failed. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( "total", 3600) as diff from( select count(1) as "total" from log where  "name"= 'Failed' and "resource_kind" = 'Pod' and  "reason" = 'ImagePullBackOff') )
    • Event Distribution. The associated query and analysis statement is:
      select "type", count(*) as "Events" group by "type"
    • Warning Event Trend. The associated query and analysis statement is:
      select time_series(__time, 'PT1H', 'yyyy-MM-dd HH', '0') as "dt",count(1) as "count"  from log  where "type" = 'Warning'  group by "dt" order by "dt"
    • Error Event Trend. The associated query and analysis statement is:
      select time_series(__time, 'PT1H', 'yyyy-MM-dd HH', '0') as "dt",count(1) as "count" from log  where "type" = 'Error' group by "dt" order by "dt"
    • Pod OOM Events. The associated query and analysis statement is:
      select TIME_FORMAT( __time, 'yyyy-MM-dd HH:mm:ss', '+08:00') as "Time", "resource_kind" as "Event Target", "name" as "Type", "resource_name" as "Target Name", "reason" as "Details" from log where "name" in ('OOMKilling','PodOOMKilling') order by __time desc limit 100
    • Pod Drive Event List. The associated query and analysis statement is:
      select TIME_FORMAT( __time, 'yyyy-MM-dd HH:mm:ss', '+08:00' ) as "Time", "resource_kind" as "Event Target", "name" as "Type", "resource_name" as "Target Name", "reason" as "Details" from log where "name" = 'NodeControllerEviction' order by __time desc limit 100
    • Major Events. The associated query and analysis statement is:
      select TIME_FORMAT( __time, 'yyyy-MM-dd HH:mm:ss', '+08:00' ) as "Time", "type" as "Level", "resource_kind" as "Event Target", "name" as "Type", "resource_name" as "Target Name", "reason" as "Details" from log where "type" in ('Warning','Error') order by __time desc limit 100

Viewing CCE Logs Aggregation Search

  1. Log in to the LTS console. In the navigation pane, choose Dashboards.
  2. Choose CCE dashboard templates under Dashboard Templates and click CCE Logs Aggregation Search to view the chart details.

    • Filter by namespace. The associated query and analysis statement is:
      select distinct("objectRef.namespace")
    • Filter by user. The associated query and analysis statement is:
      select distinct("user.username")
    • Filter by status code. The associated query and analysis statement is:
      select distinct("responseStatus.code")
    • Filter by operation type. The associated query and analysis statement is:
      select distinct("verb")
    • Filter by resource object. The associated query and analysis statement is:
      select distinct("objectRef.name")
    • Filter by resource type. The associated query and analysis statement is:
      select distinct("objectRef.resource")
    • Filter by request URL. The associated query and analysis statement is:
      select distinct("requestURI")
    • Filter by userAgent. The associated query and analysis statement is:
      select distinct("userAgent")
    • User Distribution Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "user.username" as "User", count(*) as "count" group by dt, "user.username" order by dt limit 10000
    • Namespace Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.namespace" as "Namespace", count(*) as "count"  group by dt, "objectRef.namespace" order by dt limit 10000
    • Operation Type Distribution Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.namespace" as "Namespace", count(*) as "count"  group by dt, "objectRef.namespace" order by dt limit 10000
    • Status Code Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, cast("responseStatus.code" as varchar) as "Return code", count(*)  as "count" group by dt, "Return code" order by dt limit 10000
    • Resource Type Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*) as "count" group by dt, "objectRef.resource" order by dt limit 10000	SELECT REPLACE(LEFT(stageTimestamp, 16),'T',' ') AS dt, "objectRef.resource" as "Resource type", count(*) as "count" group by dt, "objectRef.resource" order by dt limit 10000
    • Major Operations. The associated query and analysis statement is:
      select  "auditID" AS "Audit ID", "verb" AS "Operation Type", "requestReceivedTimestamp" AS "Started", "stageTimestamp" AS "Ended", "user.username" AS "Operator", "sourceIPs" AS "Operation Source","userAgent","objectRef.namespace" AS "Namespace", CONCAT(CONCAT("objectRef.resource", '/'), "objectRef.subresource") AS "Operation Object", "objectRef.name" AS "Resource Name", "responseStatus.code" AS "Return Code"

Viewing CCE Logs Account Operations

  1. Log in to the LTS console. In the navigation pane, choose Dashboards.
  2. Choose CCE dashboard templates under Dashboard Templates and click CCE Logs Account Operations to view the chart details.

    • Filter by username. The associated query and analysis statement is:
      select distinct("user.username")
    • Filter by namespace. The associated query and analysis statement is:
      select distinct("objectRef.namespace")
    • Filter by status code. The associated query and analysis statement is:
      select distinct("responseStatus.code")
    • Resources Created. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(1) as total from log where "verb" = 'create') )
    • Resources Modified. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(*)   as "total" from log where "verb" in ('update','patch')) )
    • Resources Deleted. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(*)   as "total" from log where "verb" = 'delete') )
    • Affected Namespaces. The associated query and analysis statement is:
      select case when "objectRef.namespace" is null then '_all__' else "objectRef.namespace" end as ns, count(1) as total group by  ns  limit 10000
    • Deleted Resource. The associated query and analysis statement is:
      SELECT "objectRef.resource" as "resource", count(1) as "count" where  "verb" = 'delete' group by "resource"
    • Operation History. The associated query and analysis statement is:
      select case  when "Operation" is null then 'None' else "Operation" end as "Operation", "Time", v from  (select concat(CASE WHEN "objectRef.subresource" is null then "objectRef.resource" else "objectRef.subresource"  end, '[', verb, ']'  ) as "Operation", time_series(__time, 'PT1H', 'yyyy-MM-dd HH', '0') as "Time", count(1) as v  from  log where "verb" in ('create', 'patch',  'update', 'delete')  group by "Operation", "Time" order by "Time" desc  limit  10000  )
    • Resource Operations. The associated query and analysis statement is:
      select CASE WHEN "objectRef.subresource" is null then "objectRef.resource" else "objectRef.subresource" end as "Resource", verb as "Operation", count(1) as total where "verb" in ('create','update','patch','delete') group by "Resource", "Operation" limit 10000
    • Created Resources. The associated query and analysis statement is:
      SELECT "auditID" as "Event ID", time_format("__time",'yyyy-MM-dd HH:mm:ss') as "Occurred", "requestURI" as "Resource", "objectRef.name" as "Resource Name", "responseStatus.code" as "Status Code","sourceIPs" as "Source IP", "requestObject" as "Details" where "verb" = 'create' order by __time desc limit 1000
    • Modified Resources. The associated query and analysis statement is:
      SELECT auditID as "Event ID", time_format("__time",'yyyy-MM-dd HH:mm:ss') as "Occurred","requestURI" as "Resource", "objectRef.name" as "Resource Name", "responseStatus.code" as "Status Code","sourceIPs" as "Source IP", requestObject as "Details" where "verb" in ('upate','patch') order by __time desc limit 1000 
    • Accessed Resources. The associated query and analysis statement is:
      SELECT auditID as "Event ID", time_format("__time",'yyyy-MM-dd HH:mm:ss') as "Occurred", "requestURI" as "Resource", "objectRef.name" as "Resource Name", "responseStatus.code" as "Status Code","sourceIPs" as "Source IP", requestObject as "Details" where "verb" in ('get','list') order by __time desc limit 1000
    • Deleted Resources. The associated query and analysis statement is:
      SELECT auditID as "Event ID", time_format("__time",'yyyy-MM-dd HH:mm:ss') as "Occurred", "requestURI" as "Resource", "objectRef.name" as "Resource Name", "responseStatus.code" as "Status Code","sourceIPs" as "Source IP", requestObject as "Details" where "verb" = 'delete' order by __time desc limit 1000

Viewing CCE Audit Log Center

  1. Log in to the LTS console. In the navigation pane, choose Dashboards.
  2. Choose CCE dashboard templates under Dashboard Templates and click CCE Audit Log Center to view the chart details.

    • Filter by namespace. The associated query and analysis statement is:
      select distinct("objectRef.namespace")
    • Filter by user. The associated query and analysis statement is:
      select distinct("user.username")
    • Filter by operation type. The associated query and analysis statement is:
      select distinct("verb")
    • Filter by status code. The associated query and analysis statement is:
      select distinct("responseStatus.code")
    • Filter by resource object. The associated query and analysis statement is:
      select distinct("objectRef.name")
    • Filter by resource type. The associated query and analysis statement is:
      select distinct("objectRef.resource")
    • Filter by request URL. The associated query and analysis statement is:
      select distinct("requestURI")
    • Filter by UserAgent. The associated query and analysis statement is:
      select distinct("userAgent")
    • Total Audit Records. The associated query and analysis statement is:
      select diff[1] as "total" , round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(1) as total from log ) )
    • The query analysis statements associated with the Number of Operators chart are as follows:
      select diff[1] as "total" , round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc"  from (select compare( total , 86400) as diff from( select count(distinct("user.username")) as total from log ) )
    • Active Nodes. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(DISTINCT "user.username") as total     from log where "objectRef.resource" = 'nodes' and "objectRef.subresource" = 'status' and "verb" in ('update','put','patch') and "user.username" in ('node','system')) )
    • Abnormal Visits. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(1) as total from log where "responseStatus.code" >= 400) )
    • Sensitive Operations. The associated query and analysis statement is:
      select diff[1] as "total" , round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(1)  as "total" from log where ("verb" = 'create' AND "objectRef.subresource" = 'exec') OR ("verb" = 'create' AND "objectRef.subresource" = 'attach' AND "objectRef.resource" = 'pods') OR ("objectRef.resource" = 'secrets' AND "verb"= 'get' AND ( "user.username" != 'apiserver') AND ("user.username" not like 'system:node:%')) OR ("verb"= 'delete' AND ( "user.username" not like 'system:node:%') AND ( "user.username" not like 'system:serviceaccount:kube-system:%') AND ( "user.username" != 'system:apiserve') AND ( "user.username" != 'system:apiserve') AND ( "user.username" != 'system:kube-scheduler') AND ("user.username" != 'system:kube-controller-manager'))) )
    • Creation Operations. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(1) as total from log where verb = 'create') )
    • Update Operations. The associated query and analysis statement is:
      select diff[1] as "total" , round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc"  from (select compare( total , 86400) as diff from( select count(1) as total from log where verb in ('update','patch')) )
    • Deletion Operations. The associated query and analysis statement is:
      select diff[1] as "total", round((diff[1] - diff[2]) / diff[2] * 100 , 2 ) as "inc" from (select compare( total , 86400) as diff from( select count(1) as total from log where verb = 'delete') )
    • Operators. The associated query and analysis statement is:
      select "user.username" as "Username", count(*) as "count"  group by "Username" order by "count" desc
    • Namespaces. The associated query and analysis statement is:
      select "objectRef.namespace" as "Namespace", count(*) as "count"  group by "Namespace"
    • Resource Types. The associated query and analysis statement is:
      select "objectRef.resource" as "Resource type", count(*) as "count"  group by "Resource type" order by "count" desc limit 20
    • Operation Types. The associated query and analysis statement is:
      select verb as "Operation type", count(*) as "count" group by "Operation type" order by "count" desc
    • Node Operations. The associated query and analysis statement is:
      select "verb" as "Operation type", count(*) as "count" where  "objectRef.resource" = 'nodes' AND ("verb" in ('create','delete') ) group by "Operation type" order by "count" desc
    • Workload Operations. The associated query and analysis statement is:
      select "verb" as "Operation type", count(*) as "count" where "verb" in ('create', 'delete') and "objectRef.resource" in ('deployments','statefulsets','daemonsets','jobs','cronjobs') group by "Operation type" order by "count" desc
    • Service/Ingress Operations. The associated query and analysis statement is:
      select "verb" as "Operation type", count(*) as "count" where "verb" in ('create', 'delete') and "objectRef.resource" in ('ingressess','services') group by "verb"  order by "count" desc
    • Major Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT("stageTimestamp", 16),'T',' ') AS "dt", "verb", count(*) as "count" where "verb" in ('create','delete','update','patch') group by "dt", "verb" order by "dt" limit 10000
    • Non-System User Operation Trend. The associated query and analysis statement is:
      SELECT REPLACE(LEFT("stageTimestamp", 16),'T',' ') AS "dt", count(*) as "count", "user.username" as "Username" where "user.username" not in ('kube-controller-manager','kube-apiserver-kubelet-client','system','apiserver') group by "dt", "Username" order by "dt" limit 10000

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