【 使用环境 】生产环境
【 OCP Express 】
【 使用版本 】4.2.2-20240108
【 问题描述 】OCP Express 集群预览页面不显示集群CPU、内存、磁盘和租户资源使用Top3等信息
【 复现路径 】按此贴(一键安装包obd黑屏部署OB4.3.5后找不到ocp租户密码 - #25,来自 辞霜)设置ocp租户密码后就不再显示,设置ocp租户密码前正常,常识重启OCP Express和tsc_ob集群无效。不知是否需要在哪里同步设置ocp租户密码,谢谢!
【 附件及日志 】
目前ocp express不建议使用了 如果以后生产环境 建议部署ocp 查看一下 看看是不是时钟的的问题
https://www.oceanbase.com/docs/common-oceanbase-database-cn-1000000000642558?_gl=1162azb3_gaMTI2ODUxMDY3NC4xNzM5OTQzNTg5_ga_T35KTM57DZ*MTc0MDYyMDA2MS4xNS4xLjE3NDA2MjE1OTEuNjAuMC4w
确认时钟没问题,集群所有节点NTP同步均正常。
看看obagent进行在不在。ps -ef |grep agent 一般express使用的是obgaent
你把yaml配置文件发一下
obd cluster list --查看集群信息
obd cluster edit-config {集群名} --保存在文本里 提供一下
[root@ocp ~]# ps -ef | grep agent
root 1049 1 0 2月06 ? 00:10:47 /usr/bin/qemu-ga --method=virtio-serial --path=/dev/virtio-ports/org.qemu.guest_agent.0 --blacklist= -F/etc/qemu-ga/fsfreeze-hook
root 1077 1 0 2月06 ? 00:18:04 /usr/local/zstack/zwatch-vm-agent/zwatch-vm-agent -conf /usr/local/zstack/zwatch-vm-agent/conf.yaml
root 1189 1 0 2月06 ? 01:07:47 /usr/local/zstack/zwatch-vm-agent/node_exporter --web.listen-address 127.0.0.1:9110
root 1200 1 0 2月06 ? 00:27:55 /usr/local/zstack/zwatch-vm-agent/collectd_exporter -collectd.listen-address :25827 -web.listen-address 127.0.0.1:9113
root 1204 1 0 2月06 ? 00:00:00 /usr/local/zstack/zwatch-vm-agent/collectd/collectdmon -c /usr/local/zstack/zwatch-vm-agent/collectd/collectd -- -C /usr/local/zstack/zwatch-vm-agent/collectd/collectd.conf -P /usr/local/zstack/zwatch-vm-agent/collectd/collectd.pid -f
root 1243 1204 0 2月06 ? 00:08:10 /usr/local/zstack/zwatch-vm-agent/collectd/collectd -C /usr/local/zstack/zwatch-vm-agent/collectd/collectd.conf -P /usr/local/zstack/zwatch-vm-agent/collectd/collectd.pid -f
root 4045795 4021656 0 15:52 pts/0 00:00:00 grep --color=auto agent
[root@ocp ~]# obd cluster list
+------------------------------------------------------+
| Cluster List |
+--------+---------------------------+-----------------+
| Name | Configuration Path | Status (Cached) |
+--------+---------------------------+-----------------+
| tsc_ob | /root/.obd/cluster/tsc_ob | running |
+--------+---------------------------+-----------------+
Trace ID: d43d841c-f4df-11ef-b2cf-fab313495300
If you want to view detailed obd logs, please run: obd display-trace d43d841c-f4df-11ef-b2cf-fab313495300
OCP_Express_Overview.txt (33.3 KB)
看着obagent进程没有,所以监控这个页面就没有数据。
如果你还要使用ocp express 你看看这个文档 没有部署obagent 看看怎么使用 不建议使用ocp express了 建议部署ocp使用
https://www.oceanbase.com/docs/community-obd-cn-1000000002023450
编辑配置后要求重载集群,但是重载集群报错ocp-express未运行,尝试启动ocp-express又让重载集群,加–wop参数也不行,陷入死循环了
[root@ocp ~]# obd cluster reload tsc_ob
Get local repositories and plugins ok
Load cluster param plugin ok
Open ssh connection ok
[WARN] 192.168.8.46 ocp-express is not running
Load cluster param plugin ok
Cluster status check ok
Check before start obagent ok
Check before start ocp-express x
[ERROR] <function start_check_pre.<locals>.error at 0x153c6e335ca0>
[ERROR] OBD-1005: Some of the servers in the cluster have been stopped
See https://www.oceanbase.com/product/ob-deployer/error-codes .
Trace ID: f3a5a2fc-f4fe-11ef-bca1-fab313495300
If you want to view detailed obd logs, please run: obd display-trace f3a5a2fc-f4fe-11ef-bca1-fab313495300
[root@ocp ~]# obd cluster start tsc_ob -c ocp-express
[ERROR] Deploy need reload.
Use `obd cluster reload tsc_ob` to make changes take effect.
If you still need to start the cluster, use the `obd cluster start tsc_ob --wop` option to start the cluster without loading parameters.
See https://www.oceanbase.com/product/ob-deployer/error-codes .
Trace ID: 0e2a2a4e-f4ff-11ef-a16b-fab313495300
If you want to view detailed obd logs, please run: obd display-trace 0e2a2a4e-f4ff-11ef-a16b-fab313495300
[root@ocp ~]# obd cluster start tsc_ob --wop -c ocp-express
Get local repositories ok
Load cluster param plugin ok
Cluster status check ok
Check before start ocp-express x
[ERROR] <function start_check_pre.<locals>.error at 0x14c11a2634c0>
See https://www.oceanbase.com/product/ob-deployer/error-codes .
Trace ID: fbbc8d52-f4fe-11ef-af8f-fab313495300
If you want to view detailed obd logs, please run: obd display-trace fbbc8d52-f4fe-11ef-af8f-fab313495300
[root@ocp ~]# obd display-trace 0e2a2a4e-f4ff-11ef-a16b-fab313495300
[2025-02-27 19:36:16.326] [DEBUG] - cmd: ['tsc_ob']
[2025-02-27 19:36:16.326] [DEBUG] - opts: {'servers': None, 'components': 'ocp-express', 'force_delete': None, 'strict_check': None, 'without_parameter': None}
[2025-02-27 19:36:16.327] [DEBUG] - mkdir /root/.obd/lock/
[2025-02-27 19:36:16.327] [DEBUG] - unknown lock mode
[2025-02-27 19:36:16.327] [DEBUG] - try to get share lock /root/.obd/lock/global
[2025-02-27 19:36:16.327] [DEBUG] - share lock `/root/.obd/lock/global`, count 1
[2025-02-27 19:36:16.327] [DEBUG] - Get Deploy by name
[2025-02-27 19:36:16.328] [DEBUG] - mkdir /root/.obd/cluster/
[2025-02-27 19:36:16.328] [DEBUG] - mkdir /root/.obd/config_parser/
[2025-02-27 19:36:16.328] [DEBUG] - try to get exclusive lock /root/.obd/lock/deploy_tsc_ob
[2025-02-27 19:36:16.328] [DEBUG] - exclusive lock `/root/.obd/lock/deploy_tsc_ob`, count 1
[2025-02-27 19:36:16.337] [DEBUG] - Deploy status judge
[2025-02-27 19:36:16.337] [ERROR] Deploy need reload.
[2025-02-27 19:36:16.337] [ERROR] Use `obd cluster reload tsc_ob` to make changes take effect.
[2025-02-27 19:36:16.337] [ERROR] If you still need to start the cluster, use the `obd cluster start tsc_ob --wop` option to start the cluster without loading parameters.
[2025-02-27 19:36:16.341] [DEBUG] - exclusive lock /root/.obd/lock/deploy_tsc_ob release, count 0
[2025-02-27 19:36:16.341] [DEBUG] - unlock /root/.obd/lock/deploy_tsc_ob
[2025-02-27 19:36:16.342] [DEBUG] - share lock /root/.obd/lock/global release, count 0
[2025-02-27 19:36:16.342] [DEBUG] - unlock /root/.obd/lock/global
[2025-02-27 19:36:16.342] [INFO] See https://www.oceanbase.com/product/ob-deployer/error-codes .
[2025-02-27 19:36:16.342] [INFO] Trace ID: 0e2a2a4e-f4ff-11ef-a16b-fab313495300
[2025-02-27 19:36:16.342] [INFO] If you want to view detailed obd logs, please run: obd display-trace 0e2a2a4e-f4ff-11ef-a16b-fab313495300
你把你当前yaml参数提供一下,修改了哪些也标注一下
详细的链接配置文件是不是配置出问题了
[root@ocp ~]# obd cluster edit-config tsc_ob
## Only need to configure when remote login is required
user:
username: root
password: ********
# key_file: /root/.ssh/id_rsa
port: 22
timeout: 30
oceanbase-ce:
servers:
- name: ob1
ip: 192.168.8.47
- name: ob2
ip: 192.168.8.48
- name: ob3
ip: 192.168.8.49
global:
production_mode: true
# Starting from observer version 4.2, the network selection for the observer is based on the 'local_ip' parameter, and the 'devname' parameter is no longer mandatory.
# If the 'local_ip' parameter is set, the observer will first use this parameter for the configuration, regardless of the 'devname' parameter.
# If only the 'devname' parameter is set, the observer will use the 'devname' parameter for the configuration.
# If neither the 'devname' nor the 'local_ip' parameters are set, the 'local_ip' parameter will be automatically assigned the IP address configured above.
# devname: eth0
# if current hardware's memory capacity is smaller than 50G, please use the setting of "mini-single-example.yaml" and do a small adjustment.
memory_limit: 50G # The maximum running memory for an observer
# The reserved system memory. system_memory is reserved for general tenants. The default value is 30G.
system_memory: 8G
datafile_size: 143G # Size of the data file.
datafile_next: 160G
datafile_maxsize: 2T
log_disk_size: 143G # The size of disk space used by the clog files.
enable_syslog_wf: false # Print system logs whose levels are higher than WARNING to a separate log file. The default value is true.
max_syslog_file_count: 30 # The maximum number of reserved log files before enabling auto recycling. The default value is 0.
# Cluster name for OceanBase Database. The default value is obcluster. When you deploy OceanBase Database and obproxy, this value must be the same as the cluster_name for obproxy.
appname: tsc_ob
home_path: /home/tsc_ob
root_password: ********
# proxyro_password: # proxyro user pasword, consistent with obproxy's observer_sys_password, can be empty
proxyro_password: ********
# ocp_meta_db: ocp_express # The database name of ocp express meta
# ocp_meta_username: meta # The username of ocp express meta
# ocp_meta_password: '' # The password of ocp express meta
# ocp_agent_monitor_password: '' # The password for obagent monitor user
ocp_agent_monitor_password: ********
ocp_meta_tenant: # The config for ocp express meta tenant
tenant_name: ocp
max_cpu: 2
memory_size: 4G
log_disk_size: 7680M # The recommend value is (4608 + (expect node num + expect tenant num) * 512) M.
# In this example , support multiple ob process in single node, so different process use different ports.
# If deploy ob cluster in multiple nodes, the port and path setting can be same.
cluster_id: 1737017987
ob1:
mysql_port: 2881 # External port for OceanBase Database. The default value is 2881. DO NOT change this value after the cluster is started.
rpc_port: 2882 # Internal port for OceanBase Database. The default value is 2882. DO NOT change this value after the cluster is started.
obshell_port: 2886 # Operation and maintenance port for Oceanbase Database. The default value is 2886. This parameter is valid only when the version of oceanbase-ce is 4.2.2.0 or later.
# The working directory for OceanBase Database. OceanBase Database is started under this directory. This is a required field.
home_path: /home/tsc_ob
# The directory for data storage. The default value is $home_path/store.
# data_dir: /data
# The directory for clog, ilog, and slog. The default value is the same as the data_dir value.
# redo_dir: /redo
zone: zone1
ob2:
mysql_port: 2881 # External port for OceanBase Database. The default value is 2881. DO NOT change this value after the cluster is started.
rpc_port: 2882 # Internal port for OceanBase Database. The default value is 2882. DO NOT change this value after the cluster is started.
obshell_port: 2886 # Operation and maintenance port for Oceanbase Database. The default value is 2886. This parameter is valid only when the version of oceanbase-ce is 4.2.2.0 or later.
# The working directory for OceanBase Database. OceanBase Database is started under this directory. This is a required field.
home_path: /home/tsc_ob
# The directory for data storage. The default value is $home_path/store.
# data_dir: /data
# The directory for clog, ilog, and slog. The default value is the same as the data_dir value.
# redo_dir: /redo
zone: zone2
ob3:
mysql_port: 2881 # External port for OceanBase Database. The default value is 2881. DO NOT change this value after the cluster is started.
rpc_port: 2882 # Internal port for OceanBase Database. The default value is 2882. DO NOT change this value after the cluster is started.
obshell_port: 2886 # Operation and maintenance port for Oceanbase Database. The default value is 2886. This parameter is valid only when the version of oceanbase-ce is 4.2.2.0 or later.
# The working directory for OceanBase Database. OceanBase Database is started under this directory. This is a required field.
home_path: /home/tsc_ob
# The directory for data storage. The default value is $home_path/store.
# data_dir: /data
# The directory for clog, ilog, and slog. The default value is the same as the data_dir value.
# redo_dir: /redo
zone: zone3
obproxy-ce:
# Set dependent components for the component.
# When the associated configurations are not done, OBD will automatically get the these configurations from the dependent components.
depends:
- oceanbase-ce
servers:
- 192.168.8.46
global:
listen_port: 2883 # External port. The default value is 2883.
prometheus_listen_port: 2884 # The Prometheus port. The default value is 2884.
rpc_listen_port: 2885
home_path: /home/tsc_ob/obproxy
# oceanbase root server list
# format: ip:mysql_port;ip:mysql_port. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.
rs_list: 192.168.8.47:2881;192.168.8.48:2881;192.168.8.49:2881
enable_cluster_checkout: false
# observer cluster name, consistent with oceanbase-ce's appname. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.
cluster_name: tsc_ob
skip_proxy_sys_private_check: true
enable_strict_kernel_release: false
# obproxy_sys_password: # obproxy sys user password, can be empty. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.
# observer_sys_password: # proxyro user pasword, consistent with oceanbase-ce's proxyro_password, can be empty. When a depends exists, OBD gets this value from the oceanbase-ce of the depends.
obproxy_root_password: ********
obagent:
depends:
- oceanbase-ce
servers:
- name: ob1
ip: 192.168.8.47
- name: ob2
ip: 192.168.8.48
- name: ob3
ip: 192.168.8.49
global:
home_path: /home/tsc_ob/obagent
http_basic_auth_password: ********
ocp-express:
depends:
- oceanbase-ce
- obproxy-ce
- obagent
servers:
- 192.168.8.46
global:
# The working directory for prometheus. prometheus is started under this directory. This is a required field.
home_path: /home/tsc_ob/ocp-express
# log_dir: /home/oceanbase/ocp-express/log # The log directory of ocp express server. The default value is {home_path}/log.
memory_size: 2G # The memory size of ocp-express server. The recommend value is 512MB * (expect node num + expect tenant num) * 60MB.
logging_file_total_size_cap: 10G # The total log file size of ocp-express server
logging_file_max_history: 7 # The maximum of retention days the log archive log files to keep. The default value is unlimited
admin_passwd: ********
ocp_root_password: ********