Sending async command to wait on file transfer

[ Edited ]
Posts: 9
6491     0

Hello all,

I'm working on a python script to download a new version of IOS onto devices. The problem I'm running into is that NetMRI will say the command completed as OK while the file transfer is still ongoing. I was looking in the python library and found async command, but I can't get it to work. 



Is it possible to use this to make NetMRI wait until the device returns some specified text (seconds)?

How do I kill a long running async job? Now I can't run any more scripts on my test device because it says a command is still running?


If so, how can I make that work? Here's my command:


easy.send_async_command("copy scp://USERSmiley TongueASS@SERVER/{} {}:.format(New_Code_Version,Location_Clean), (360), (""))


Any help would be much appreciated!

Re: Sending async command to wait on file transfer

Posts: 395
6492     0

You need to use the following


import time






NetMRI has a builtin as well



This will tell it to sleep for 60 seconds 

Follow me on LinkedIn:

Re: Sending async command to wait on file transfer

Posts: 1
6492     0

Importing time and setting certain value appeared to be very easy. Thank you!



Showing results for 
Search instead for 
Do you mean 

Recommended for You