我执行的时候 会有输出 [WARN] no such option: -c,但是最后也没有阻止我执行,这点不合理啊,不存在的参数就应该阻止用户执行(我个人的想法)
输出如下
obd cluster reload ob_01 -c alertmanager
[WARN] no such option: -c
Get local repositories and plugins ok
Load cluster param plugin ok
Open ssh connection ok
Connect to observer x.x.x.183:2881 ok
Connect to obproxy ok
Connect to Obagent ok
Reload obagent ok
[WARN] seekdb_monitor_status no in obd_agent_mapper.yaml, skip
[WARN] seekdb_monitor_status no in obd_agent_mapper.yaml, skip
[WARN] seekdb_monitor_status no in obd_agent_mapper.yaml, skip
Connect to Prometheus ok
Reload prometheus ok
Connect to grafana ok
Reload Grafana ok
Connect to Alertmanager ok
Reload alertmanager ok
wait observer usable ok
Reload observer ok
ob_01 reload
Trace ID: 24a6a1c2-ee17-11f1-899c-0afff617e029
If you want to view detailed obd logs, please run: obd display-trace 24a6a1c2-ee17-11f1-899c-0afff617e029
疑问3 什么时候用reload,什么时候用restart -c --wp这样的方式呢
bd cluster restart ob_01 -c alertmanager --wp
Get local repositories and plugins ok
Load cluster param plugin ok
[ERROR] Configurations are changed and must be applied to all components and servers.
Trace ID: 11458ae4-ee17-11f1-9b2c-0afff617e029
If you want to view detailed obd logs, please run: obd display-trace 11458ae4-ee17-11f1-9b2c-0afff617e029
我尝试着用restart -c --wp 发现不行
老师,我感觉有的时候好奇怪 我重启下prometheus ,我是重启按理来说先停后起,为什么还是显示端口被占用
obd cluster restart ob_01 -c prometheus
Get local repositories and plugins ok
Load cluster param plugin ok
Open ssh connection ok
Cluster status check ok
Load cluster param plugin ok
Cluster status check ok
Check before start prometheus x
[ERROR] OBD-1001: 172.x.x.11:9090 port is already used, Please choose another unoccupied port or terminate the process occupying the port
[ERROR] OBD-1001: 172.x.x9090 port is already used
手动关闭都不行 ,你看 最后kill 才OK
obd cluster stop ob_01 -c prometheus
Get local repositories ok
Get local repositories and plugins ok
Open ssh connection ok
Stop prometheus ok
Trace ID: 5784d58c-ee21-11f1-ac73-0afff617e029
If you want to view detailed obd logs, please run: obd display-trace 5784d58c-ee21-11f1-ac73-0afff617e029
obd cluster start ob_01 -c prometheus
Get local repositories ok
Load cluster param plugin ok
Cluster status check ok
Check before start prometheus x
[ERROR] OBD-1001: 172.x.x.11:9090 port is already used, Please choose another unoccupied port or terminate the process occupying the port
[ERROR] OBD-1001: 172.x.x.11:9090 port is already used
See 错误码及解决方案 - ob-deployer - OceanBase .
Trace ID: 5c98254c-ee21-11f1-811a-0afff617e029
If you want to view detailed obd logs, please run: obd display-trace 5c98254c-ee21-11f1-811a-0afff617e029