
Raspbian Buster(machine2)を実行しているRaspberry Pi 3B +に接続されているUbuntu Server 18.04.3(machine1)システムがあります。
sshfsを使って何かを設定しています。 sshfsを使用する前に、通常のsshを使用して設定を確認しましたが、機能しません。 machine1のuser1、machine2のuser1、machine1のuser2、およびmachine1のルートでmachine2にログインできるようにしたいです。
だから
user1@machine1: ssh -p 123 user2@machine2
これはうまくいきます。
root@machine1: ssh -p 123 user2@machine2
動作しません。すぐに接続拒否メッセージが表示され、machine2のauth.logには何も表示されません。
これが.Xsessionファイルに問題があるかどうか疑問に思います。しかし、デバッグ出力には何も見つかりません。 machine1のルートとuser1はどちらも、machine2にあるuser2の~/.ssh/authorized_keysファイルにあるAuthorized_keysにrsaキーを生成しました。キーを削除しても状況は同じです(パスワードの入力を求められません)。私が知っている限り、ルートの試みは決してmachine1を離れません。
machine1のログには何も見つかりません。どんな提案にも感謝します!これはmachine1の/ etc / ssh / ssh_configです(コメントなし)。
Host *
ForwardAgent yes
ForwardX11 yes
ForwardX11Trusted yes
SendEnv LANG LC_*
HashKnownHosts yes
GSSAPIAuthentication yes
GSSAPIDelegateCredentials no
編集1:
すべてのホストに ~/.ssh/config ファイルはありません。すべてのユーザーのすべてのホストにはid_rsaとid_rsa.pubがあり(私の標準的な慣行)、user2のmachine2にはAuthorized_hostsがあります。 user1とrootにもKnown_hostsがあります。
要求コマンドの出力は次のとおりです。
root@machine1:~# ssh -p 123 -vvv user1@machine2
OpenSSH_7.6p1 Ubuntu-4ubuntu0.3, OpenSSL 1.0.2n 7 Dec 2017
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: resolving "machine2" port 123
debug2: ssh_connect_direct: needpriv 0
debug1: Connecting to machine2 [machine2] port 123.
debug1: connect to address machine2 port 123: Connection refused
ssh: connect to host machine2 port 123: Connection refused