パスワードなしの sftp はファイルを転送せずに接続を閉じる

パスワードなしの sftp はファイルを転送せずに接続を閉じる

パスワードなしの sftp でファイルを転送しようとしています。先週までは機能していて、同じキーを使用して、別のサーバーからファイルを転送できました。しかし、このコマンドを入力するとすぐに接続が閉じられます - sftp -v -oIdentityFile=/home/n123456/.ssh/id_rsa_ability[メールアドレス]公開鍵を使用して認証しています。詳細ログをPFBします。

OpenSSH_6.6.1, OpenSSL 1.0.1e-fips 11 Feb 2013
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 56: Applying options for *
debug1: Connecting to abc@xyz port 22.
debug1: Connection established.
debug1: permanently_set_uid: 0/0
debug1: identity file /home/n123456/.ssh/id_rsa_ability type 1
debug1: identity file /home/n123456/.ssh/id_rsa_ability-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.6.1
debug1: Remote protocol version 2.0, remote software version OpenSSH_7.4
debug1: match: OpenSSH_7.4 pat OpenSSH* compat 0x04000000
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-ctr hmac-sha2-256 none
debug1: kex: client->server aes128-ctr hmac-sha2-256 none
debug1: kex: ecdh-sha2-nistp256 need=32 dh_need=32
debug1: kex: ecdh-sha2-nistp256 need=32 dh_need=32
debug1: sending SSH2_MSG_KEX_ECDH_INIT
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ECDSA XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXxxxxxx
debug1: Host 'abc@xyz' is known and matches the ECDSA host key.
debug1: Found key in /root/.ssh/known_hosts:8
debug1: ssh_ecdsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password,keyboard-interactive
debug1: Next authentication method: gssapi-keyex
debug1: No valid Key exchange context
debug1: Next authentication method: gssapi-with-mic
debug1: Unspecified GSS failure.  Minor code may provide more information
Server not found in Kerberos database

debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password,keyboard-interactive
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/n123456/.ssh/id_rsa_ability
debug1: Server accepts key: pkalg ssh-rsa blen 279
debug1: key_parse_private2: missing begin marker
debug1: read PEM private key done: type RSA
debug1: Authentication succeeded (publickey).
Authenticated to xyz (xxxxxxx:22).
debug1: channel 0: new [client-session]
debug1: Requesting [email protected]
debug1: Entering interactive session.
debug1: client_input_global_request: rtype [email protected] want_reply 0
debug1: Sending environment.
debug1: Sending subsystem: sftp
debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
debug1: client_input_channel_req: channel 0 rtype [email protected] reply 0
debug1: channel 0: free: client-session, nchannels 1
debug1: fd 0 clearing O_NONBLOCK
Transferred: sent 3440, received 3072 bytes, in 0.1 seconds
Bytes per second: sent 37158.3, received 33183.2
debug1: Exit status 1
Connection closed

答え1

サーバーは SFTP サブシステムの初期化に失敗しました。

一般的に、これについてできることはあまりありません。サーバー管理者に連絡してサーバーを修復してもらってください。

これはおそらくキーとは何の関係もありません。

関連情報