同一台机第二次扩容报错

为提高效率,请提供以下信息,问题描述清晰能够更快得到解决:
【 TiDB 使用环境】
【概述】场景+问题概述
【背景】做过哪些操作
服务器坏了,新服务器扩容tikv正常,再扩容tidb、pd报错
【现象】业务和数据库现象
【业务影响】
【TiDB 版本】
V4.0.0
【附件】

  1. TiUP Cluster Display 信息

  2. TiUP Cluster Edit Config 信息

  3. TiDB- Overview 监控

  • 对应模块日志(包含问题前后1小时日志)
  • [ Serial ] - ScaleConfig: cluster=test-cluster, user=tidb, host=192.168.0.246, service=pd-2379.service, deploy_dir=/home/tidb/deploy3/pd, data_dir=[/home/tidb/deploy3/pd/data], log_dir=/home/tidb/deploy3/pd/log, cache_dir=
    script path: /home/tidb/.tiup/storage/cluster/clusters/test-cluster/config-cache/run_pd_192.168.0.246_2379.sh
    script path: /templates/scripts/run_pd_scale.sh.tpl
  • Check status
    Enabling component pd
    Enabling instance pd 192.168.0.246:2379
    Enable pd 192.168.0.246:2379 success
    Enabling component node_exporter
    Failed to execute operation: No such file or directory

Error: failed to enable: pd 192.168.0.246:2379, please check the instance’s log(/home/tidb/deploy3/pd/log) for more detail.: executor.ssh.execute_failed: Failed to execute command over SSH for ‘tidb@192.168.0.246:34512’ {ssh_stderr: Failed to execute operation: No such file or directory
, ssh_stdout: , ssh_command: export LANG=C; PATH=$PATH:/usr/bin:/usr/sbin sudo -H bash -c “systemctl enable node_exporter-9100.service”}, cause: Process exited with status 1

Verbose debug logs has been written to /home/tidb/.tiup/logs/tiup-cluster-debug-2021-09-24-12-56-58.log.
Error: run /home/tidb/.tiup/components/cluster/v1.3.6/tiup-cluster (wd:/home/tidb/.tiup/data/Sjtx4df) failed: exit status 1

2 个赞

这个可以手动从其他节点,copy 一份 node-exporter 服务相关的东西,你的这台服务上,有其他节点服务不

2 个赞

升级tidb可以吗?v4.0.11版本没这个问题

2 个赞

这个和集群版本没关系,不过你可以升级 tiup ,tiup update --self,你的问题是:第一次扩容后,你缩容后,把相关的服务下线了,第二次扩容时,应该还有其他服务,以为不需要部署这个 node-expoter 服务了,就启动报错了(猜的)

2 个赞

或者你可以 搜一下其他的帖子,有类似情况

2 个赞

对,就是这种情况,大牛经验丰富。
cd /etc/systemd/system
scp -P 34512 exporter root@192.168.0.246:/etc/systemd/system

2 个赞

:+1::+1::+1:

2 个赞

学到了~:+1:

3 个赞

这是在搞极限操作测试么~ :+1:

2 个赞

:rofl:又被大佬发现了~

3 个赞

扩容成功了,扩容后的服务火焰图没有显示

2 个赞

火焰图还是监控?

2 个赞

grafana

1 个赞

此话题已在最后回复的 1 分钟后被自动关闭。不再允许新回复。