-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
hard code gather scene add gather observer.base
- Loading branch information
Showing
2 changed files
with
72 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
info_en: "[cluster base info]" | ||
info_cn: "[集群基础信息]" | ||
command: obdiag gather scene run --scene=observer.base | ||
task: | ||
- version: "[2.0.0.0, 4.0.0.0]" | ||
steps: | ||
- type: sql | ||
sql: "show variables like 'version_comment';" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.v$ob_cluster" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.__all_zone WHERE name='idc';" | ||
global: true | ||
- type: sql | ||
sql: "select svr_ip,zone,with_rootserver,status,block_migrate_in_time,start_service_time,stop_time,build_version from oceanbase.__all_server order by zone;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT zone, concat(svr_ip, ':', svr_port) observer, cpu_capacity, cpu_total, cpu_assigned, cpu_assigned_percent, mem_capacity, mem_total, mem_assigned, mem_assigned_percent, unit_Num, round(`load`, 2) `load`, round(cpu_weight, 2) cpu_weight, round(memory_weight, 2) mem_weight, leader_count FROM oceanbase.__all_virtual_server_stat ORDER BY zone,svr_ip;" | ||
global: true | ||
- type: sql | ||
sql: "select tenant_id,tenant_name,primary_zone,compatibility_mode from oceanbase.__all_tenant;" | ||
global: true | ||
- type: sql | ||
sql: "show parameters like '%syslog_level%';" | ||
global: true | ||
- type: sql | ||
sql: "show parameters like '%syslog_io_bandwidth_limit%';" | ||
global: true | ||
- type: sql | ||
sql: "select count(*),tenant_id,zone_list,unit_count from oceanbase.__all_resource_pool group by tenant_id,zone_list,unit_count;" | ||
global: true | ||
- type: sql | ||
sql: "show parameters" | ||
global: true | ||
- version: "[4.0.0.0, *]" | ||
steps: | ||
- type: sql | ||
sql: "show variables like 'version_comment';" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.DBA_OB_ZONES;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.DBA_OB_SERVERS;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.GV$OB_SERVERS;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.DBA_OB_UNIT_CONFIGS;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.DBA_OB_RESOURCE_POOLS;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT * FROM oceanbase.DBA_OB_TENANTS;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT c.TENANT_ID, e.TENANT_NAME, concat(c.NAME, ': ', d.NAME) `pool:conf`,concat(c.UNIT_COUNT, ' unit: ', d.min_cpu, 'C/', ROUND(d.MEMORY_SIZE/1024/1024/1024,0), 'G') unit_info FROM oceanbase.DBA_OB_RESOURCE_POOLS c, oceanbase.DBA_OB_UNIT_CONFIGS d, oceanbase.DBA_OB_TENANTS e WHERE c.UNIT_CONFIG_ID=d.UNIT_CONFIG_ID AND c.TENANT_ID=e.TENANT_ID AND c.TENANT_ID>1000 ORDER BY c.TENANT_ID;" | ||
global: true | ||
- type: sql | ||
sql: "SELECT a.TENANT_NAME,a.TENANT_ID,b.SVR_IP FROM oceanbase.DBA_OB_TENANTS a, oceanbase.GV$OB_UNITS b WHERE a.TENANT_ID=b.TENANT_ID;" | ||
global: true | ||
- type: sql | ||
sql: "show parameters" | ||
global: true |