In the previous video, we already learn how to configure multiple router at once, 2
which is we configure interface loopback0 on router 1 until router 5. 3
But the problem is, we still need to check the interface on each router one by one. 4
Now in this video, we are going to create a network automation script to check the interface 5
on all router at once. 6
This is easy, here after configuring ip address, we can type a command to show interface, 7
so here show ip interface brief exclude unassign. 8
Don’t forget to use \n or enter here. 9
Let’s also print a divider here, so the output will be good. 10
And for the loopback, let’s try to create loopback1, and the ip address let’s say 11
10.2.1.x. Here we also need to use time sleep. 12
Save, back to terminal, 13
Let’s execute the script. 14
Just enter enter here. 15
Here we can see that we get an error. 16
Invalid input detected. 17
Why this is error? 18
Because now we are in the configuration mode, so we need to use do. 19
Let’s add do here, and then let’s say we will create loopback 2, and the ip address is 3. 20
Save, back to terminal, and then let’s execute the script again. 21
Just enter enter here. 22
Okay this is success. 23
We are success to configure loopback2 with ip address 10.3.1.1 on router 1, 24
and here we can see that we already have loopback0 until loopback2 on router 1. 25
Router 2, we also have loopback0 until loopback2, the ip address is correct 26
Router 3, we also have loopback0 until 2, the ip address is correct. 27
Router 5 is also correct. 28
Okay so now we are success to doing looping to show interface on all router. 29
I think enough for this video 30
Thank you for watching and see you on the next video.