Friday, October 15, 2021

Having issues running a script using Ciscoconfparse, need help/feedback

Hello, I constructed a script using netmiko and ciscoconfparse to pull a running config, edit the config, and copy it back to the running-config of a swtich. I want to scan the config for misconfigured ports on all interfaces and change them.The problem is that ciscoconfparse performs inconsistently and will sometimes add erroneous text or add commands twice. Also, when I copy the config file to the switch using tftp, some interfaces remain unchanged, even though the new config text has the correct commands. I'm new to automation so please tell me if I missed something obvious and if there there better alternatives for what I'm trying to do. Here is a link to the code.



No comments:

Post a Comment