# junos\_scp not working

**URL:** <https://forum.ansible.com/t/junos-scp-not-working/30363>\
**Category:** Ansible Project\
**Tags:** ansible-project\
**Created:** [May 18, 2019, 3:07am UTC](https://forum.ansible.com/t/junos-scp-not-working/30363 "2019-05-18T03:07:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ganeshrn](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/ganeshrn/32/1021_2.png) [@ganeshrn](https://forum.ansible.com/u/ganeshrn)\
**Post date:** [May 18, 2019, 3:07am UTC](https://forum.ansible.com/t/junos-scp-not-working/30363/1 "2019-05-18T03:07:36Z")

</div>

Based on the logs it seems you have not set the value of provider argument in the task.  
junos\_scp module requires the provider key to be set. More details refer the module documentation  
[https://docs.ansible.com/ansible/latest/modules/junos\_scp\_module.html](https://docs.ansible.com/ansible/latest/modules/junos_scp_module.html)

---

<div class="post-metadata">

**Author:** ![Yan\_Sun](https://avatars.discourse-cdn.com/v4/letter/y/bbe5ce/32.png) [@Yan\_Sun](https://forum.ansible.com/u/Yan_Sun)\
**Post date:** [May 20, 2019, 4:02pm UTC](https://forum.ansible.com/t/junos-scp-not-working/30363/2 "2019-05-20T16:02:55Z")

</div>

Thanks!  
The provider has be deprecated since Ansible 2.5. In my case, Ansible server has NETCONF connection setup with password, but, it fails on junos\_scp. If I replace juno\_scp with junos\_command, there are no this kinds of issue at all.

---

<div class="post-metadata">

**Author:** ![ganeshrn](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/ganeshrn/32/1021_2.png) [@ganeshrn](https://forum.ansible.com/u/ganeshrn)\
**Post date:** [May 21, 2019, 1:59am UTC](https://forum.ansible.com/t/junos-scp-not-working/30363/3 "2019-05-21T01:59:42Z")

</div>

junos\_scp module relies on[junos-eznc](https://pypi.org/project/junos-eznc/) library for file transfer to a JUNOS device, that’s the reason provider argument is required. The provider deprecation warning for junos\_scp module is not correct and needs to be fixed. Please raise an issue on Github to track it.

junos\_command module uses Ansible netconf connection type hence provider is no longer required for the junos\_command module.

Also FYI you can use[net\_put](https://docs.ansible.com/ansible/latest/modules/net_put_module.html) and [net\_get](https://docs.ansible.com/ansible/latest/modules/net_get_module.html) modules in Ansible which should work with JUNOS device for file transfer and doesn’t require provider argument.
