マスター サーバーは 2 つのスレーブ サーバーに接続できませんが、2 つのスレーブ サーバーはマスター サーバーに接続できます。
Tue Jul 25 00:57:19 2023 - [warning] Global configuration file /etc/masterha_default.cnf not found. Skipping.
Tue Jul 25 00:57:19 2023 - [info] Reading application default configuration from /etc/mha/mha.cnf..
Tue Jul 25 00:57:19 2023 - [info] Reading server configuration from /etc/mha/mha.cnf..
Tue Jul 25 00:57:19 2023 - [info] Starting SSH connection tests..
Tue Jul 25 00:57:19 2023 - [error][/usr/local/share/perl5/MHA/SSHCheck.pm, ln63]
Tue Jul 25 00:57:19 2023 - [debug] Connecting via SSH from [email protected](192.168.64.131:22) to [email protected](192.168.64.133:22)..
Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password).
Tue Jul 25 00:57:19 2023 - [error][/usr/local/share/perl5/MHA/SSHCheck.pm, ln111] SSH connection from [email protected](192.168.64.131:22) to [email protected](192.168.64.133:22) failed!
Tue Jul 25 00:57:36 2023 - [debug]
Tue Jul 25 00:57:20 2023 - [debug] Connecting via SSH from [email protected](192.168.64.135:22) to [email protected](192.168.64.131:22)..
Tue Jul 25 00:57:25 2023 - [debug] ok.
Tue Jul 25 00:57:25 2023 - [debug] Connecting via SSH from [email protected](192.168.64.135:22) to [email protected](192.168.64.133:22)..
Tue Jul 25 00:57:36 2023 - [debug] ok.
Tue Jul 25 00:57:36 2023 - [debug]
Tue Jul 25 00:57:19 2023 - [debug] Connecting via SSH from [email protected](192.168.64.133:22) to [email protected](192.168.64.131:22)..
Tue Jul 25 00:57:25 2023 - [debug] ok.
Tue Jul 25 00:57:25 2023 - [debug] Connecting via SSH from [email protected](192.168.64.133:22) to [email protected](192.168.64.135:22)..
Tue Jul 25 00:57:36 2023 - [debug] ok.
SSH Configuration Check Failed!
原因分析:
3 つのサーバーは相互に SSH 通信をテストしましたが、依然として接続できませんでした。
--三台服务器之间相互测试
ssh <服务器IP> date
[MHA] 接続するときは、まず自分自身との接続をテストします。
解決:
マスターサーバー上:
--给主服务器设置建立自己免密登录
ssh-copy-id <主服务器IP>