-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SCP failure #14
Comments
Does it work if you try: enable_scp: True |
No does not work |
@sakabio Okay, I will need to try to reproduce this. |
Thanks so much. |
@sakabio At a higher-level what are you trying to accomplish i.e. what is the purpose of the file transfer? |
Trying to upload IOS images to 1224 switches and dont want to do it manually. They need upgrading. |
Nice! |
Make sure you increase the number of forks using the |
@sakabio Testing this now... |
You're the man, worked like a charm. |
Let me know how your OS upgrade goes. |
@ktbyers Hello there, can you make the destination file system a variable so it can be specified. I would like to loop through a switch stack and load the IOS images to the individual members. |
There already is a variable for this:
It defaults to the above, but you can set it. Does that accomplish what you are looking for? |
I tried setting it and got an error.
|
Here is what
Can you post the part of your playbook where you set |
This is what I wanted to do.
This allows me to loop through each stack and uplod the file, this works on the 3750 stacks however fail on WS-C3650-48PD. I also notice I get this error when a copy is completed for bulk switches.
I was able to do a 183 switches in 3 hours will 50 flows. Currently running copy for 314 switches. For 3750 Stacks I am able to copy to a max of 3 stacks then it times out. Started with ansible just last thursday. I am a great fan of your work, will take a class soon. |
The The error you have above is:
So it sounds like the remote switch closed either the SSH or the SCP channel (or they were never open). You might want to test a manual SCP on this device and see if it works properly (to isolate whether something is not right with the SCP process versus the module code). |
OS Ubuntu 16.04
ansible 2.3.2.0
got an scp error using the module.
"msg": "value of enable_scp must be one of: y,yes,on,1,true,1,True,n,no,off,0,false,0,False, got: True"
fatal: [1.2.3.4]: FAILED! => {
"changed": false,
"failed": true,
"invocation": {
"module_args": {
"dest_file": "upload.txt",
"dest_file_system": "flash:",
"enable_scp": "True",
"host": "1.2.3.4",
"overwrite": "True",
"password": "cisoco",
"port": "22",
"source_file": "/etc/ansible/playbooks/test.txt",
"username": "cisco"
}
},
"msg": "value of enable_scp must be one of: y,yes,on,1,true,1,True,n,no,off,0,false,0,False, got: True"
}
playbook:
--
name: TEST file upload
hosts: mea-ve-2960
connection: local
gather_facts: false
tasks:
cisco_file_transfer:
source_file: "/etc/ansible/playbooks/test.txt"
dest_file: upload.txt
enable_scp: true
host: 1.2.3.4
username: cisco
password: cisoco
The text was updated successfully, but these errors were encountered: