2016-04-21 65 views
-1

我试图用ansible来ping服务器,但我得到了一些错误信息无法使用AWS使用关键ansible达到SSH远程主机

[[email protected] kafka-scripts]$ ansible zook1 -m ping -vvv 

Using /home/ec2-user/kafka-scripts/ansible.cfg as config file 
<172.30.0.113> ESTABLISH SSH CONNECTION FOR USER: None 
<172.30.0.113> SSH: EXEC ssh -C -q -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/ec2-user/kafka-scripts/keys/kafka_broker.pem"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/ec2-user/.ansible/cp/ansible-ssh-%h-%p-%r -tt 172.30.0.113 '/bin/sh -c '"'"'(umask 22 && mkdir -p "` echo $HOME/.ansible/tmp/ansible-tmp-1461268838.85-234429685988133 `" && echo "` echo $HOME/.ansible/tmp/ansible-tmp-1461268838.85-234429685988133 `")'"'"'' 
zook1 | UNREACHABLE! => { 
    "changed": false, 
    "msg": "SSH encountered an unknown error during the connection. We recommend you re-run the command using -vvvv, which will enable SSH debugging output to help diagnose the issue", 
    "unreachable": true 
} 

与-vvvv

[[email protected] kafka-scripts]$ ansible zookservers -m ping -vvvv 
Using /home/ec2-user/kafka-scripts/ansible.cfg as config file 
Loaded callback minimal of type stdout, v2.0 
<172.30.0.113> ESTABLISH SSH CONNECTION FOR USER: None 
<172.30.0.113> SSH: EXEC ssh -C -vvv -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/ec2-user/kafka-scripts/keys/kafka_broker.pem"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/ec2-user/.ansible/cp/ansible-ssh-%h-%p-%r -tt 172.30.0.113 '/bin/sh -c '"'"'(umask 22 && mkdir -p "` echo $HOME/.ansible/tmp/ansible-tmp-1461270664.7-212192719472156 `" && echo "` echo $HOME/.ansible/tmp/ansible-tmp-1461270664.7-212192719472156 `")'"'"'' 
zook1 | UNREACHABLE! => { 
"changed": false, 
"msg": "SSH encountered an unknown error. The output was:\nOpenSSH_6.6.1, OpenSSL 1.0.1e-fips 11 Feb 2013\r\ndebug1: Reading configuration data /etc/ssh/ssh_config\r\ndebug1: /etc/ssh/ssh_config line 56: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug1: Control socket \"/home/ec2-user/.ansible/cp/ansible-ssh-172.30.0.113-22-ec2-user\" does not exist\r\ndebug2: ssh_connect: needpriv 0\r\ndebug1: Connecting to 172.30.0.113 [172.30.0.113] port 22.\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug1: fd 3 clearing O_NONBLOCK\r\ndebug1: Connection established.\r\ndebug3: timeout: 10000 ms remain after connect\r\ndebug3: Incorrect RSA1 identifier\r\ndebug3: Could not load \"/home/ec2-user/kafka-scripts/keys/kafka_broker.pem\" as a RSA1 public key\r\ndebug1: identity file /home/ec2-user/kafka-scripts/keys/kafka_broker.pem type -1\r\ndebug1: identity file /home/ec2-user/kafka-scripts/keys/kafka_broker.pem-cert type -1\r\ndebug1: Enabling compatibility mode for protocol 2.0\r\ndebug1: Local version string SSH-2.0-OpenSSH_6.6.1\r\ndebug1: Remote protocol version 2.0, remote software version OpenSSH_6.6.1\r\ndebug1: match: OpenSSH_6.6.1 pat OpenSSH_6.6.1* compat 0x04000000\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug3: load_hostkeys: loading entries for host \"172.30.0.113\" from file \"/home/ec2-user/.ssh/known_hosts\"\r\ndebug3: load_hostkeys: found key type ECDSA in file /home/ec2-user/.ssh/known_hosts:1\r\ndebug3: load_hostkeys: loaded 1 keys\r\ndebug3: order_hostkeyalgs: prefer hostkeyalgs: [email protected],[email protected],[email protected],ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521\r\ndebug1: SSH2_MSG_KEXINIT sent\r\ndebug1: SSH2_MSG_KEXINIT received\r\ndebug2: kex_parse_kexinit: [email protected],ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1\r\ndebug2: kex_parse_kexinit: [email protected],[email protected],[email protected],ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,[email protected],[email protected],[email protected],[email protected],[email protected],ssh-ed25519,ssh-rsa,ssh-dss\r\ndebug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected]\r\ndebug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected]\r\ndebug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96\r\ndebug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96\r\ndebug2: kex_parse_kexinit: [email protected],zlib,none\r\ndebug2: kex_parse_kexinit: [email protected],zlib,none\r\ndebug2: kex_parse_kexinit: \r\ndebug2: kex_parse_kexinit: \r\ndebug2: kex_parse_kexinit: first_kex_follows 0 \r\ndebug2: kex_parse_kexinit: reserved 0 \r\ndebug2: kex_parse_kexinit: [email protected],ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1\r\ndebug2: kex_parse_kexinit: ssh-rsa,ecdsa-sha2-nistp256,ssh-ed25519\r\ndebug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected]\r\ndebug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected]\r\ndebug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96\r\ndebug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96\r\ndebug2: kex_parse_kexinit: none,[email protected]\r\ndebug2: kex_parse_kexinit: none,[email protected]\r\ndebug2: kex_parse_kexinit: \r\ndebug2: kex_parse_kexinit: \r\ndebug2: kex_parse_kexinit: first_kex_follows 0 \r\ndebug2: kex_parse_kexinit: reserved 0 \r\ndebug2: mac_setup: setup [email protected]\r\ndebug1: kex: server->client aes128-ctr [email protected] [email protected]\r\ndebug2: mac_setup: setup [email protected]\r\ndebug1: kex: client->server aes128-ctr [email protected] [email protected]\r\ndebug1: kex: [email protected] need=16 dh_need=16\r\ndebug1: kex: [email protected] need=16 dh_need=16\r\ndebug1: sending SSH2_MSG_KEX_ECDH_INIT\r\ndebug1: expecting SSH2_MSG_KEX_ECDH_REPLY\r\ndebug1: Server host key: ECDSA 55:88:b1:5a:cd:bb:87:ff:dd:54:b0:36:39:c7:e2:ea\r\ndebug3: load_hostkeys: loading entries for host \"172.30.0.113\" from file \"/home/ec2-user/.ssh/known_hosts\"\r\ndebug3: load_hostkeys: found key type ECDSA in file /home/ec2-user/.ssh/known_hosts:1\r\ndebug3: load_hostkeys: loaded 1 keys\r\ndebug1: Host '172.30.0.113' is known and matches the ECDSA host key.\r\ndebug1: Found key in /home/ec2-user/.ssh/known_hosts:1\r\ndebug1: ssh_ecdsa_verify: signature correct\r\ndebug2: kex_derive_keys\r\ndebug2: set_newkeys: mode 1\r\ndebug1: SSH2_MSG_NEWKEYS sent\r\ndebug1: expecting SSH2_MSG_NEWKEYS\r\ndebug2: set_newkeys: mode 0\r\ndebug1: SSH2_MSG_NEWKEYS received\r\ndebug1: SSH2_MSG_SERVICE_REQUEST sent\r\ndebug2: service_accept: ssh-userauth\r\ndebug1: SSH2_MSG_SERVICE_ACCEPT received\r\ndebug2: key: /home/ec2-user/kafka-scripts/keys/kafka_broker.pem ((nil)), explicit\r\ndebug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic\r\ndebug3: start over, passed a different list publickey,gssapi-keyex,gssapi-with-mic\r\ndebug3: preferred gssapi-with-mic,gssapi-keyex,hostbased,publickey\r\ndebug3: authmethod_lookup gssapi-with-mic\r\ndebug3: remaining preferred: gssapi-keyex,hostbased,publickey\r\ndebug3: authmethod_is_enabled gssapi-with-mic\r\ndebug1: Next authentication method: gssapi-with-mic\r\ndebug1: Unspecified GSS failure. Minor code may provide more information\nNo Kerberos credentials available\n\r\ndebug1: Unspecified GSS failure. Minor code may provide more information\nNo Kerberos credentials available\n\r\ndebug1: Unspecified GSS failure. Minor code may provide more information\n\n\r\ndebug1: Unspecified GSS failure. Minor code may provide more information\nNo Kerberos credentials available\n\r\ndebug2: we did not send a packet, disable method\r\ndebug3: authmethod_lookup gssapi-keyex\r\ndebug3: remaining preferred: hostbased,publickey\r\ndebug3: authmethod_is_enabled gssapi-keyex\r\ndebug1: Next authentication method: gssapi-keyex\r\ndebug1: No valid Key exchange context\r\ndebug2: we did not send a packet, disable method\r\ndebug3: authmethod_lookup publickey\r\ndebug3: remaining preferred: ,publickey\r\ndebug3: authmethod_is_enabled publickey\r\ndebug1: Next authentication method: publickey\r\ndebug1: Trying private key: /home/ec2-user/kafka-scripts/keys/kafka_broker.pem\r\[email protected]@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r\[email protected]   WARNING: UNPROTECTED PRIVATE KEY FILE!   @\r\[email protected]@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r\nPermissions 0777 for '/home/ec2-user/kafka-scripts/keys/kafka_broker.pem' are too open.\r\nIt is required that your private key files are NOT accessible by others.\r\nThis private key will be ignored.\r\nbad permissions: ignore key: /home/ec2-user/kafka-scripts/keys/kafka_broker.pem\r\ndebug2: we did not send a packet, disable method\r\ndebug1: No more authentication methods to try.\r\nPermission denied (publickey,gssapi-keyex,gssapi-with-mic).\r\n", 
"unreachable": true 
} 

SSH调试输出:

SSH encountered an unknown error. The output was:\nOpenSSH_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: auto-mux: Trying existing master 
debug1: Control socket "/home/ec2-user/.ansible/cp/ansible-ssh-172.30.0.113-22-ec2-user" does not exist 
debug2: ssh_connect: needpriv 0 
debug1: Connecting to 172.30.0.113 [172.30.0.113] port 22. 
debug2: fd 3 setting O_NONBLOCK 
debug1: fd 3 clearing O_NONBLOCK 
debug1: Connection established. 
debug3: timeout: 10000 ms remain after connect 
debug3: Incorrect RSA1 identifier 
debug3: Could not load "/home/ec2-user/kafka-scripts/keys/kafka_broker.pem" as a RSA1 public key 
debug1: identity file /home/ec2-user/kafka-scripts/keys/kafka_broker.pem type -1 
debug1: identity file /home/ec2-user/kafka-scripts/keys/kafka_broker.pem-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_6.6.1 
debug1: match: OpenSSH_6.6.1 pat OpenSSH_6.6.1* compat 0x04000000 
debug2: fd 3 setting O_NONBLOCK 
debug3: load_hostkeys: loading entries for host "172.30.0.113" from file "/home/ec2-user/.ssh/known_hosts" 
debug3: load_hostkeys: found key type ECDSA in file /home/ec2-user/.ssh/known_hosts:1 
debug3: load_hostkeys: loaded 1 keys 
debug3: order_hostkeyalgs: prefer hostkeyalgs: [email protected],[email protected],[email protected],ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521 
debug1: SSH2_MSG_KEXINIT sent 
debug1: SSH2_MSG_KEXINIT received 
debug2: kex_parse_kexinit: [email protected],ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1 
debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,[email protected],[email protected],[email protected],[email protected],[email protected],ssh-ed25519,ssh-rsa,ssh-dss 
debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] 
debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] 
debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 
debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 
debug2: kex_parse_kexinit: [email protected],zlib,none 
debug2: kex_parse_kexinit: [email protected],zlib,none 
debug2: kex_parse_kexinit: 
debug2: kex_parse_kexinit: 
debug2: kex_parse_kexinit: first_kex_follows 0 
debug2: kex_parse_kexinit: reserved 0 
debug2: kex_parse_kexinit: [email protected],ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1 
debug2: kex_parse_kexinit: ssh-rsa,ecdsa-sha2-nistp256,ssh-ed25519 
debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] 
debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,[email protected],[email protected],[email protected],aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,[email protected] 
debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 
debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-md5,hmac-sha1,[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96 
debug2: kex_parse_kexinit: none,[email protected] 
debug2: kex_parse_kexinit: none,[email protected] 
debug2: kex_parse_kexinit: 
debug2: kex_parse_kexinit: 
debug2: kex_parse_kexinit: first_kex_follows 0 
debug2: kex_parse_kexinit: reserved 0 
debug2: mac_setup: setup [email protected] 
debug1: kex: server->client aes128-ctr [email protected] [email protected] 
debug2: mac_setup: setup [email protected] 
debug1: kex: client->server aes128-ctr [email protected] [email protected] 
debug1: kex: [email protected] need=16 dh_need=16 
debug1: kex: [email protected] need=16 dh_need=16 
debug1: sending SSH2_MSG_KEX_ECDH_INIT 
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY 
debug1: Server host key: ECDSA 55:88:b1:5a:cd:bb:87:ff:dd:54:b0:36:39:c7:e2:ea 
debug3: load_hostkeys: loading entries for host "172.30.0.113" from file "/home/ec2-user/.ssh/known_hosts" 
debug3: load_hostkeys: found key type ECDSA in file /home/ec2-user/.ssh/known_hosts:1 
debug3: load_hostkeys: loaded 1 keys 
debug1: Host '172.30.0.113' is known and matches the ECDSA host key. 
debug1: Found key in /home/ec2-user/.ssh/known_hosts:1 
debug1: ssh_ecdsa_verify: signature correct 
debug2: kex_derive_keys 
debug2: set_newkeys: mode 1 
debug1: SSH2_MSG_NEWKEYS sent 
debug1: expecting SSH2_MSG_NEWKEYS 
debug2: set_newkeys: mode 0 
debug1: SSH2_MSG_NEWKEYS received 
debug1: SSH2_MSG_SERVICE_REQUEST sent 
debug2: service_accept: ssh-userauth 
debug1: SSH2_MSG_SERVICE_ACCEPT received 
debug2: key: /home/ec2-user/kafka-scripts/keys/kafka_broker.pem ((nil)), explicit 
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic 
debug3: start over, passed a different list publickey,gssapi-keyex,gssapi-with-mic 
debug3: preferred gssapi-with-mic,gssapi-keyex,hostbased,publickey 
debug3: authmethod_lookup gssapi-with-mic 
debug3: remaining preferred: gssapi-keyex,hostbased,publickey 
debug3: authmethod_is_enabled gssapi-with-mic 
debug1: Next authentication method: gssapi-with-mic 
debug1: Unspecified GSS failure. Minor code may provide more information\nNo Kerberos credentials available\n 
debug1: Unspecified GSS failure. Minor code may provide more information\nNo Kerberos credentials available\n 
debug1: Unspecified GSS failure. Minor code may provide more information\n\n 
debug1: Unspecified GSS failure. Minor code may provide more information\nNo Kerberos credentials available\n 
debug2: we did not send a packet, disable method 
debug3: authmethod_lookup gssapi-keyex 
debug3: remaining preferred: hostbased,publickey 
debug3: authmethod_is_enabled gssapi-keyex 
debug1: Next authentication method: gssapi-keyex 
debug1: No valid Key exchange context 
debug2: we did not send a packet, disable method 
debug3: authmethod_lookup publickey 
debug3: remaining preferred: ,publickey 
debug3: authmethod_is_enabled publickey 
debug1: Next authentication method: publickey 
debug1: Trying private key: /home/ec2-user/kafka-scripts/keys/kafka_broker.pem 
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 
@   WARNING: UNPROTECTED PRIVATE KEY FILE!   @ 
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 
Permissions 0777 for '/home/ec2-user/kafka-scripts/keys/kafka_broker.pem' are too open. 
It is required that your private key files are NOT accessible by others. 
This private key will be ignored. 
bad permissions: ignore key: /home/ec2-user/kafka-scripts/keys/kafka_broker.pem 
debug2: we did not send a packet, disable method 
debug1: No more authentication methods to try. 
Permission denied (publickey,gssapi-keyex,gssapi-with-mic). 
+2

那么当你“使用-vvvv重新运行命令”时会发生什么情况? –

+0

我添加到帖子中,请检查它 –

回答

1

正如在错误消息中所写的,您的密钥文件未被保护,因为它应该。

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 
@   WARNING: UNPROTECTED PRIVATE KEY FILE!   @ 
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 
Permissions 0777 for '/home/ec2-user/kafka-scripts/keys/kafka_broker.pem' are too open. 
It is required that your private key files are NOT accessible by others. 

运行以下命令应该通过删除其他人读取密钥文件的授权来解决您的问题。

chmod 600 /home/ec2-user/kafka-scripts/keys/kafka_broker.pem 
+0

以前不是777它是700和问题发生在我玩耍的时候我把它改为777。无论如何,我试图从头开始重新创建所有的东西。我会在之后让你知道。顺便说一下,ansible.co给出的RHEL步骤中的安全安装不起作用。您是否有任何线索如何在RHEL上安装ansible –

+1

除非您确切知道自己在做什么,否则不应该减少对私钥的限制。如果它能解决您的问题,请不要伪造起来并接受问题。请打开另一个问题来询问您的安装问题。 –

相关问题