Hi,
My goal is to pull down the running config. At this point, I'm just trying to run some simple tests on HP 5400zl Series switches.
I'm using ansible 2.1.1.0 on Centos7.
I get different results depending on the connection type and both fail at a point I'm not sure how to troubleshoot.The only real clue I see here is "debug3: mux_client_read_packet: read header failed: Broken pipe". Any ideas on how to troubleshoot this more or other parameters to tweak? I do have "host_key_checking=false"
Thanks.
==============================================
USING "ansible_connection=paramiko"
ansible sw1 -u admin -m raw -a "show run" -vvvv
Using /etc/ansible/ansible.cfg as config file
Loaded callback minimal of type stdout, v2.0
<xxx.xxx.169.40> ESTABLISH CONNECTION FOR USER: admin on PORT 22 TO xxx.xxx.169.40
sw1 | UNREACHABLE! => {
"changed": false,
"msg": "Authentication failed.",
"unreachable": true
}
USING "ansible_connection=ssh/smart"
> ansible sw1 -u admin -m raw -a "show run" -vvvv
Using /etc/ansible/ansible.cfg as config file
Loaded callback minimal of type stdout, v2.0
<xxx.xxx.169.40> ESTABLISH SSH CONNECTION FOR USER: admin
<xxx.xxx.169.40> SSH: EXEC sshpass -d12 ssh -C -vvv -o ControlMaster=auto -o ControlPersist=60s -o User=admin -o ConnectTimeout=10 -o ControlPath=/root/.ansible/cp/ansible-ssh-%h-%p-%r -tt xxx.xxx.169.40 'show run'
sw1 | SUCCESS | rc=0 >>
SSH command execution is not supported.
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: auto-mux: Trying existing master
debug1: Control socket "/root/.ansible/cp/ansible-ssh-xxx.xxx.169.40-22-admin" does not exist
debug2: ssh_connect: needpriv 0
debug1: Connecting to xxx.xxx.169.40 [xxx.xxx.169.40] port 22.
debug2: fd 3 setting O_NONBLOCK
debug1: fd 3 clearing O_NONBLOCK
debug1: Connection established.
debug3: timeout: 9999 ms remain after connect
debug1: permanently_set_uid: 0/0
debug3: Incorrect RSA1 identifier
debug3: Could not load "/root/.ssh/id_rsa" as a RSA1 public key
debug1: identity file /root/.ssh/id_rsa type 1
debug1: identity file /root/.ssh/id_rsa-cert type -1
debug1: identity file /root/.ssh/id_dsa type -1
debug1: identity file /root/.ssh/id_dsa-cert type -1
debug1: identity file /root/.ssh/id_ecdsa type -1
debug1: identity file /root/.ssh/id_ecdsa-cert type -1
debug1: identity file /root/.ssh/id_ed25519 type -1
debug1: identity file /root/.ssh/id_ed25519-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 Mocana SSH 5.3.1
debug1: no match: Mocana SSH 5.3.1
debug2: fd 3 setting O_NONBLOCK
debug3: load_hostkeys: loading entries for host "xxx.xxx.169.40" from file "/root/.ssh/known_hosts"
debug3: load_hostkeys: found key type RSA in file /root/.ssh/known_hosts:22
debug3: load_hostkeys: loaded 1 keys
debug3: order_hostkeyalgs: prefer hostkeyalgs:
ssh-rsa-...@openssh.com,
ssh-rsa-...@openssh.com,ssh-rsa
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug2: kex_parse_kexinit:
curve255...@libssh.org,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-...@openssh.com,
ssh-rsa-...@openssh.com,ssh-rsa,
ecdsa-sha2-nis...@openssh.com,
ecdsa-sha2-nis...@openssh.com,
ecdsa-sha2-nis...@openssh.com,
ssh-ed2551...@openssh.com,
ssh-dss-...@openssh.com,
ssh-dss-...@openssh.com,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ssh-ed25519,ssh-dss
debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,
aes12...@openssh.com,
aes25...@openssh.com,
chacha20...@openssh.com,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,
rijnda...@lysator.liu.sedebug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,
aes12...@openssh.com,
aes25...@openssh.com,
chacha20...@openssh.com,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,
rijnda...@lysator.liu.sedebug2: kex_parse_kexinit:
hmac-m...@openssh.com,
hmac-s...@openssh.com,
umac-...@openssh.com,
umac-1...@openssh.com,
hmac-sha...@openssh.com,
hmac-sha...@openssh.com,
hmac-ripe...@openssh.com,
hmac-sha...@openssh.com,
hmac-md...@openssh.com,hmac-md5,hmac-sha1,
uma...@openssh.com,
umac...@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,
hmac-ri...@openssh.com,hmac-sha1-96,hmac-md5-96
debug2: kex_parse_kexinit:
hmac-m...@openssh.com,
hmac-s...@openssh.com,
umac-...@openssh.com,
umac-1...@openssh.com,
hmac-sha...@openssh.com,
hmac-sha...@openssh.com,
hmac-ripe...@openssh.com,
hmac-sha...@openssh.com,
hmac-md...@openssh.com,hmac-md5,hmac-sha1,
uma...@openssh.com,
umac...@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,
hmac-ri...@openssh.com,hmac-sha1-96,hmac-md5-96
debug2: kex_parse_kexinit:
zl...@openssh.com,zlib,none
debug2: kex_parse_kexinit:
zl...@openssh.com,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: diffie-hellman-group14-sha1,diffie-hellman-group1-sha1
debug2: kex_parse_kexinit: ssh-rsa
debug2: kex_parse_kexinit: aes256-ctr,aes256-cbc,
rijnda...@lysator.liu.se,aes192-ctr,aes192-cbc,aes128-ctr,aes128-cbc,3des-cbc
debug2: kex_parse_kexinit: aes256-ctr,aes256-cbc,
rijnda...@lysator.liu.se,aes192-ctr,aes192-cbc,aes128-ctr,aes128-cbc,3des-cbc
debug2: kex_parse_kexinit: hmac-sha1-96,hmac-md5,hmac-sha1,hmac-md5-96
debug2: kex_parse_kexinit: hmac-sha1-96,hmac-md5,hmac-sha1,hmac-md5-96
debug2: kex_parse_kexinit: none
debug2: kex_parse_kexinit: none
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 hmac-md5
debug1: kex: server->client aes128-ctr hmac-md5 none
debug2: mac_setup: setup hmac-md5
debug1: kex: client->server aes128-ctr hmac-md5 none
debug1: kex: diffie-hellman-group14-sha1 need=16 dh_need=16
debug1: kex: diffie-hellman-group14-sha1 need=16 dh_need=16
debug2: bits set: 1035/2048
debug1: sending SSH2_MSG_KEXDH_INIT
debug1: expecting SSH2_MSG_KEXDH_REPLY
debug1: Server host key: RSA 65:da:57:c1:c8:99:ba:e0:fa:65:78:41:d6:5a:9e:53
debug3: load_hostkeys: loading entries for host "xxx.xxx.169.40" from file "/root/.ssh/known_hosts"
debug3: load_hostkeys: found key type RSA in file /root/.ssh/known_hosts:22
debug3: load_hostkeys: loaded 1 keys
debug1: Host 'xxx.xxx.169.40' is known and matches the RSA host key.
debug1: Found key in /root/.ssh/known_hosts:22
debug2: bits set: 1042/2048
debug1: ssh_rsa_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: /root/.ssh/id_rsa (0x7fa066fc3e90),
debug2: key: /root/.ssh/id_dsa ((nil)),
debug2: key: /root/.ssh/id_ecdsa ((nil)),
debug2: key: /root/.ssh/id_ed25519 ((nil)),
debug3: input_userauth_banner
debug1: Authentications that can continue: password
debug3: start over, passed a different list password
debug3: preferred gssapi-keyex,gssapi-with-mic,publickey,keyboard-interactive,password
debug3: authmethod_lookup password
debug3: remaining preferred: ,gssapi-with-mic,publickey,keyboard-interactive,password
debug3: authmethod_is_enabled password
debug1: Next authentication method: password
debug3: packet_send2: adding 64 (len 60 padlen 4 extra_pad 64)
debug2: we sent a password packet, wait for reply
debug1: Authentication succeeded (password).
Authenticated to xxx.xxx.169.40 ([xxx.xxx.169.40]:22).
debug1: setting up multiplex master socket
debug3: muxserver_listen: temporary control path /root/.ansible/cp/ansible-ssh-xxx.xxx.169.40-22-admin.DDZxiRwjLNWQxWdm
debug2: fd 4 setting O_NONBLOCK
debug3: fd 4 is O_NONBLOCK
debug3: fd 4 is O_NONBLOCK
debug1: channel 0: new [/root/.ansible/cp/ansible-ssh-xxx.xxx.169.40-22-admin]
debug3: muxserver_listen: mux listener channel 0 fd 4
debug2: fd 3 setting TCP_NODELAY
debug3: packet_set_tos: set IP_TOS 0x08
debug1: control_persist_detach: backgrounding master process
debug2: control_persist_detach: background process is 21748
debug2: fd 4 setting O_NONBLOCK
debug1: forking to background
debug1: Entering interactive session.
debug2: set_control_persist_exit_time: schedule exit in 60 seconds
debug1: multiplexing control connection
debug2: fd 5 setting O_NONBLOCK
debug3: fd 5 is O_NONBLOCK
debug1: channel 1: new [mux-control]
debug3: channel_post_mux_listener: new mux channel 1 fd 5
debug3: mux_master_read_cb: channel 1: hello sent
debug2: set_control_persist_exit_time: cancel scheduled exit
debug3: mux_master_read_cb: channel 1 packet type 0x00000001 len 4
debug2: process_mux_master_hello: channel 1 slave version 4
debug2: mux_client_hello_exchange: master version 4
debug3: mux_client_forwards: request forwardings: 0 local, 0 remote
debug3: mux_client_request_session: entering
debug3: mux_client_request_alive: entering
debug3: mux_master_read_cb: channel 1 packet type 0x10000004 len 4
debug2: process_mux_alive_check: channel 1: alive check
debug3: mux_client_request_alive: done pid = 21750
debug3: mux_client_request_session: session request sent
debug3: mux_master_read_cb: channel 1 packet type 0x10000002 len 78
debug2: process_mux_new_session: channel 1: request tty 1, X 0, agent 0, subsys 0, term "xterm-256color", cmd "show run", env 1
debug3: process_mux_new_session: got fds stdin 6, stdout 7, stderr 8
debug2: fd 7 setting O_NONBLOCK
debug2: fd 8 setting O_NONBLOCK
debug1: channel 2: new [client-session]
debug2: process_mux_new_session: channel_new: 2 linked to control channel 1
debug2: channel 2: send open
debug2: callback start
debug2: client_session2_setup: id 2
debug2: channel 2: request pty-req confirm 1
debug1: Sending environment.
debug1: Sending env LANG = en_US.UTF-8
debug2: channel 2: request env confirm 0
debug1: Sending command: show run
debug2: channel 2: request exec confirm 1
debug3: mux_session_confirm: sending success reply
debug2: callback done
debug2: channel 2: open confirm rwindow 32768 rmax 32768
debug1: mux_client_request_session: master session id: 2
debug2: channel_input_status_confirm: type 99 id 2
debug2: PTY allocation request accepted on channel 2
debug2: channel_input_status_confirm: type 99 id 2
debug2: exec request accepted on channel 2
debug2: channel 2: rcvd eof
debug2: channel 2: output open -> drain
debug1: client_input_channel_req: channel 2 rtype exit-status reply 0
debug3: mux_exit_message: channel 2: exit message, exitval 0
debug2: channel 2: rcvd close
debug2: channel 2: close_read
debug2: channel 2: input open -> closed
debug3: channel 2: will not send data after close
debug1: channel 0: free: /root/.ansible/cp/ansible-ssh-xxx.xxx.169.40-22-admin, nchannels 3
debug3: channel 0: status: The following connections are open:
#2 client-session (t4 r85460946 i3/0 o1/0 fd -1/7 cc 1)
debug1: channel 1: free: mux-control, nchannels 2
debug3: channel 1: status: The following connections are open:
#2 client-session (t4 r85460946 i3/0 o1/0 fd -1/7 cc 1)
debug1: channel 2: free: client-session, nchannels 1
debug3: channel 2: status: The following connections are open:
#2 client-session (t4 r85460946 i3/0 o1/0 fd -1/7 cc 1)
debug3: fd 0 is not O_NONBLOCK
debug3: fd 1 is not O_NONBLOCK
debug1: fd 2 clearing O_NONBLOCK
Connection to xxx.xxx.169.40 closed by remote host.
debug3: mux_client_read_packet: read header failed: Broken pipe
Transferred: sent 2976, received 1600 bytes, in 0.2 seconds
Bytes per second: sent 15203.1, received 8173.7
debug1: Exit status -1
debug2: Received exit status from master 0
Shared connection to xxx.xxx.169.40 closed.
==============================================