# Using module junos\_install\_os through ssh tunnel to Jump server (Paramiko transport failed)

**URL:** <https://forum.ansible.com/t/using-module-junos-install-os-through-ssh-tunnel-to-jump-server-paramiko-transport-failed/21450>\
**Category:** Ansible Project\
**Created:** [May 16, 2016, 11:05pm UTC](https://forum.ansible.com/t/using-module-junos-install-os-through-ssh-tunnel-to-jump-server-paramiko-transport-failed/21450 "2016-05-16T23:05:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![cdassy.ccs](https://avatars.discourse-cdn.com/v4/letter/c/71e660/32.png) [@cdassy.ccs](https://forum.ansible.com/u/cdassy.ccs)\
**Post date:** [May 16, 2016, 11:05pm UTC](https://forum.ansible.com/t/using-module-junos-install-os-through-ssh-tunnel-to-jump-server-paramiko-transport-failed/21450/1 "2016-05-16T23:05:55Z")

</div>

Hello guys,

I’m deploying a new playbook in order to provision some devices and working with netconify is working fine, but when i want to upgrade the junos through the jump server i’m having issues with paramiko authentication. It is failing no matter is I use keys or password it just doesn’t work.

I have a ssh tunnel to the device using ./.ssh/config like this

Host tunnel  
Hostname jumpbox  
ForwardX11Trusted yes  
LocalForward 8001 [10.210.0.157:22](http://10.210.0.157:22)  
ControlPath ~/.ssh/master-%l-%r@jumpbox:%p  
ControlMaster auto

Host distant  
User local  
Hostname localhost  
Port 8001  
ForwardX11Trusted yes

Host \*  
ForwardAgent yes  
Protocol 2  
StrictHostKeyChecking no  
UserKnownHostsFile=/dev/null

On the jump box my ./.ssh/config is like this

Host \*  
ForwardX11Trusted yes  
ForwardAgent yes  
Protocol 2

SO basically I want to use the module junos\_install\_os in order to upgrade the switches. The module junos\_install\_config is working fine it load merges the configuration and commits with no issue through the ssh tunnel and the playboom looks like this.

- name: Load merge a configuration to a device running Junos OS  
hosts: local  
roles:
- Juniper.junos  
connection: local  
gather\_facts: no

vars:  
user: local,  
password: pass  
hostname: distanthost  
hostnameip: 127.0.0.1  
port: 8001

tasks:

- name: load merge a configuration file  
junos\_install\_config:  
host={{ hostnameip }}  
file=/Users/lab/Documents/Ansible-Configs/{{ hostname }}.txt  
user={{ user }}  
passwd={{ password }}  
port={{ port }}  
overwrite=true  
logfile=/usr/local/etc/ansible/logs/{{ hostname }}.log

Like I said this one is working just fine. So when I try to use the module junos\_install\_os to upgrade the junos I have the issue.

The playbook looks like this
