send command "copy running-config tftp:\n %s\n\r" % Tftp_server"
See original GitHub issueDear all,
I used the following lines to backup a configuration from cisco sw to a tftp server
net_connect = ConnectHandler(**LoginInfo)
net_connect.enable()
command_ConfSave="copy running-config tftp:\n %s\n\r" % Tftp_server
result=net_connect.send_command_expect(command_ConfSave)
it works with Catalyst switch, but when with Nexus, always facing an error as following Exception in thread Thread-2:
Traceback (most recent call last):
File "C:\Program Files (x86)\Python36-32\lib\threading.py", line 916, in _bootstrap_inner
self.run()
File "C:\Program Files (x86)\Python36-32\lib\threading.py", line 864, in run
self._target(*self._args, **self._kwargs)
File "C:\Temp\workspace\Production\SWlogin\ExcuteCommandOnSW.py", line 61, in BBakC
result=net_connect.send_command_expect(command_ConfSave)
File "C:\Program Files (x86)\Python36-32\lib\site-packages\netmiko\base_connection.py", line 823, in send_command_expect
return self.send_command(*args, **kwargs)
File "C:\Program Files (x86)\Python36-32\lib\site-packages\netmiko\base_connection.py", line 815, in send_command
search_pattern))
seems the interaction between the netmiko and switch had an error, can not “#” from switch
Catalyst version 15.0(1)SE3 Nexus version 6.0(2)N2(2) Netmiko 1.4.1
My question: is there some way can help to see the realtime output from this ssh session? it may help to do some more trouble shooting on it
thanks a lot
Issue Analytics
- State:
- Created 6 years ago
- Comments:11 (5 by maintainers)
Top Results From Across the Web
How do I copy config to TFTP? - Cisco Community
The first, You should check your NVRAM or you have to find where start-config.cfe is being. please type the command:dir all: and then...
Read more >Copying a configuration file to or from a TFTP server
To initiate transfers of configuration files to or from a TFTP server using the CLI, enter one of the following commands: copy startup-config ......
Read more >Copying a configuration file to or from a TFTP server
To initiate transfers of configuration files to or from a TFTP server using the CLI, enter one of the following commands: copy startup-config...
Read more >Schedule Cisco config backups with kron and archive - YouTube
With just a few CLI commands you can automate the backup of your Cisco networks. Use Kron and archive to back up configs...
Read more >Transferring switch configurations
This command can copy a designated config file in the switch to a TFTP server. For more information, see "Multiple Configuration Files" in...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@ktbyers Thanks for the help! Much appreciated!
Probably try:
Note, by default
send_command
will wait 100 seconds, so delay_factor=4 will wait 400 seconds. If you need longer than this, you can increase it to a bigger value.