DevNet 105: Network Automation Using Nornir
Network Automation Using Nornir : Topology: Create hosts.yaml file: --- IOSv-L2-1: hostname: '192.168.17.3' port: 22 username: 'admin' password: 'cisco' platform: 'cisco_ios' groups: - 'cisco_ios' IOSv-L2-2: hostname: '192.168.17.4' port: 22 username: 'admin' password: 'cisco' platform: 'cisco_ios' groups: - 'cisco_ios' Create group.yaml file: --- # groups.yaml file cisco_ios: platform: 'cisco_ios' First Lab by Nornir: Create simple python script: from nornir import InitNornir nr = InitNornir() Now let's execute Python program and inspect the inventory: root@kali:/home/nornir# python3 -m pdb simple_test.py > /home/nornir/simple_test.py(1)<module>() -> from nornir import InitNornir (Pdb) list 1 -> from nornir import InitNornir 2 nr = InitNornir() [EOF] (Pdb) n...