Deleting to swap chapter 13 and 14
This commit is contained in:
@@ -1,20 +0,0 @@
|
|||||||
from netmiko import ConnectHandler
|
|
||||||
|
|
||||||
cisco_rtr = {
|
|
||||||
"device_type": "cisco_ios",
|
|
||||||
"host": "172.16.2.50",
|
|
||||||
"username": "root",
|
|
||||||
"password": "rootroot",
|
|
||||||
}
|
|
||||||
|
|
||||||
def main():
|
|
||||||
commands = ["int Lo0", "description my custom description", "commit"]
|
|
||||||
# commands =["logging buffered 100000"]
|
|
||||||
with ConnectHandler(**cisco_rtr) as net_connect:
|
|
||||||
output = net_connect.send_config_set(commands)
|
|
||||||
|
|
||||||
print(output)
|
|
||||||
print()
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
|
||||||
main()
|
|
||||||
@@ -1,20 +0,0 @@
|
|||||||
from netmiko import ConnectHandler
|
|
||||||
|
|
||||||
cisco_rtr = {
|
|
||||||
"device_type": "cisco_ios",
|
|
||||||
"host": "172.16.2.50",
|
|
||||||
"username": "root",
|
|
||||||
"password": "rootroot",
|
|
||||||
}
|
|
||||||
|
|
||||||
def main():
|
|
||||||
command = "show ip int brief"
|
|
||||||
with ConnectHandler(**cisco_rtr) as net_connect:
|
|
||||||
print(net_connect.find_prompt())
|
|
||||||
print(net_connect.enable())
|
|
||||||
output = net_connect.send_command(command)
|
|
||||||
|
|
||||||
print(output)
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
|
||||||
main()
|
|
||||||
Reference in New Issue
Block a user