OBD-2002: Failed to start 172.17.0.4 observer

【 使用环境 】测试环境
【 OB or 其他组件 】
【 使用版本 】Docker镜像 quay.io/oceanbase/oceanbase-ce:latest sha256:af8df7e7131c8c06ad70cb2319d163811bba65063b8ebeb5c1dccdfff5900830
【问题描述】OBD-2002: Failed to start 172.17.0.4 observer
【复现路径】原本启动成功并且导入了数据库并使用了 结果突然未响应 重新查看服务挂了 重启就报错OBD-2002: Failed to start 172.17.0.4 observer
【附件及日志】推荐使用OceanBase敏捷诊断工具obdiag收集诊断信息,详情参见链接(右键跳转查看):

【SOP系列 22 】——故障诊断第一步(自助诊断和诊断信息收集)

【docker启动命令】: sudo docker run -p 2881:2881 -p 2883:2883 -v D:/OcenBase/root/ob:/root/ob -v D:/OcenBase/root/.obd/cluster:/root/.obd/cluster --name obstandalone_local -e MODE=MINI -e OB_TENANT_PASSWORD=rootPWD123 -d Quay
【observer-template.yaml】:
oceanbase-ce:

servers:

  • ${OB_SERVER_IP}

global:

home_path: /root/ob/observer

mysql_port: 2881

rpc_port: 2882

zone: zone1

cluster_id: 1

appname: ${OB_CLUSTER_NAME}

memory_limit: 8G

system_memory: 3G

datafile_size: 5G

log_disk_size: 5G

root_password: ${OB_SYS_PASSWORD}

obconfig_url: ${OB_CONFIGURL}

scenario: ${OB_SCENARIO}

cpu_count: 16

production_mode: false

syslog_level: INFO

enable_syslog_wf: false

enable_syslog_recycle: true

max_syslog_file_count: 4

enable_rich_error_msg: true

【控制台日志】
sh-4.4# obd cluster start obcluster
Get local repositories ok
Load cluster param plugin ok
Open ssh connection ok
[WARN] OBD-1011: (172.17.0.4) The recommended value of fs.aio-max-nr is 1048576 (Current value: 65536)
[WARN] OBD-1007: (172.17.0.4) The recommended number of core file size is unlimited (Current value: 0)
[WARN] OBD-1007: (172.17.0.4) The recommended number of stack size is unlimited (Current value: 8192)
[WARN] OBD-1017: (172.17.0.4) The value of the “vm.max_map_count” must be within [327600, 1310720] (Current value: 262144, Recommended value: 655360)
[WARN] OBD-1017: (172.17.0.4) The value of the “vm.overcommit_memory” must be 0 (Current value: 1, Recommended value: 0)
cluster scenario: express_oltp
Start observer ok
observer program health check x
[WARN] OBD-2002: Failed to start 172.17.0.4 observer
See https://www.oceanbase.com/product/ob-deployer/error-codes .
Trace ID: 446492e8-69e9-11f0-ba2b-0242ac110004
If you want to view detailed obd logs, please run: obd display-trace 446492e8-69e9-11f0-ba2b-0242ac110004

【obd display-trace 详细日志】
[2025-07-26 06:25:07.124] [INFO] observer program health check
[2025-07-26 06:25:10.174] [DEBUG] – 172.17.0.4 program health check
[2025-07-26 06:25:10.174] [DEBUG] – root@172.17.0.4 execute: cat /root/ob/observer/run/observer.pid
[2025-07-26 06:25:10.188] [DEBUG] – exited code 0
[2025-07-26 06:25:10.188] [DEBUG] – root@172.17.0.4 execute: ls /proc/1043
[2025-07-26 06:25:10.257] [DEBUG] – exited code 2, error output:
[2025-07-26 06:25:10.257] [DEBUG] ls: cannot access ‘/proc/1043’: No such file or directory
[2025-07-26 06:25:10.257] [DEBUG]
[2025-07-26 06:25:10.302] [WARNING] OBD-2002: Failed to start 172.17.0.4 observer
[2025-07-26 06:25:10.302] [DEBUG] - sub health_check ref count to 0
[2025-07-26 06:25:10.302] [DEBUG] - export health_check
[2025-07-26 06:25:10.302] [DEBUG] - plugin oceanbase-ce-py_script_health_check-3.1.0 result: False
[2025-07-26 06:25:10.305] [DEBUG] - share lock /root/.obd/lock/mirror_and_repo release, count 1
[2025-07-26 06:25:10.305] [DEBUG] - share lock /root/.obd/lock/mirror_and_repo release, count 0
[2025-07-26 06:25:10.305] [DEBUG] - unlock /root/.obd/lock/mirror_and_repo
[2025-07-26 06:25:10.306] [DEBUG] - exclusive lock /root/.obd/lock/deploy_obcluster release, count 0
[2025-07-26 06:25:10.306] [DEBUG] - unlock /root/.obd/lock/deploy_obcluster
[2025-07-26 06:25:10.306] [DEBUG] - share lock /root/.obd/lock/global release, count 0
[2025-07-26 06:25:10.306] [DEBUG] - unlock /root/.obd/lock/global
[2025-07-26 06:25:10.306] [INFO] See https://www.oceanbase.com/product/ob-deployer/error-codes .
[2025-07-26 06:25:10.306] [INFO] Trace ID: 446492e8-69e9-11f0-ba2b-0242ac110004
[2025-07-26 06:25:10.306] [INFO] If you want to view detailed obd logs, please run: obd display-trace 446492e8-69e9-11f0-ba2b-0242ac110004

进行N次尝试
先不映射任何文件启动
sudo docker run
-p 2881:2881
-p 2883:2883
–name obstandalone
-e MODE=MINI
-e OB_TENANT_PASSWORD=rootPWD123
-d Quay

启动成功并且可以运行以及链接数据库导入导出数据都正常

随后使用docker cp拷贝root/ob文件夹至本地
删除原有容器并映射数据文件重新启动
sudo docker run
-p 2881:2881
-p 2883:2883
–name obstandalone
-e MODE=MINI
-e OB_TENANT_PASSWORD=rootPWD123
-v D:/docker_volumes/OcenBase/ob:/root/ob
-d Quay

启动失败
find obd deploy information, skip configuring…
start ob cluster …
[ERROR] Deploy “obcluster” is configured. You could not start an configured cluster.
See https://www.oceanbase.com/product/ob-deployer/error-codes .
Trace ID: bf17e670-6a0c-11f0-8007-0242ac110004
If you want to view detailed obd logs, please run: obd display-trace bf17e670-6a0c-11f0-8007-0242ac110004
Sat Jul 26 10:39:02 UTC 2025
boot success!

obd cluster list 显示obcluster节点configured状态

obd cluster start obcluster 启动失败
[ERROR] Deploy “obcluster” is configured. You could not start an configured cluster.
See https://www.oceanbase.com/product/ob-deployer/error-codes .
Trace ID: 904c2288-6a0d-11f0-a910-0242ac110004
If you want to view detailed obd logs, please run: obd display-trace 904c2288-6a0d-11f0-a910-0242ac110004

测试开发环境 我就想映射一下数据库持久化文件避免镜像损坏导致数据文件丢失 来来回回折腾N天了 :face_holding_back_tears:

666

log_disk_size参数设置太小了,建议为内存的3-4倍。
当前集群状态为configured么。