
5
4. Now it’s time to assign IP addresses. Veth1 will be changed from the default IP address to
192.0.2.199/24. Veth2 will be assigned 192.168.100.1/24.
Router(config)# interface veth1
Router(config-if-veth1)# ?
arp Set arp timeout
description Interface specific description
end End current mode and change to enable mode
exit Exit current mode and down to previous mode
help Description of the interactive help system
ip Interface Internet Protocol config commands
no Negate a command or set its defaults
quit Exit current mode and down to previous mode
shutdown Shutdown the selected interface
Router(config-if-veth1)# ip ?
address Set the IP address of an interface
dvmrp DVMRP interface command
helper-address Specify a destination address for UDP broadcasts
igmp IGMP interface commands
irdp ICMP Router Discovery Protocol
multicast IP multicast interface commands
ospf OSPF interface commands
redirects Enable sending ICMP Redirect messages
rip Routing Information Protocol
unreachables Enable sending ICMP Unreachable messages
vrrp Interface VRRP config commands
Router(config-if-veth1)# ip address 192.0.2.199/24
Router(config-if-veth1)# exit
Router(config)# interface veth2
Router(config-if-veth2)# ip address 192.168.100.1/24
Router(config-if-veth2)# end
Router# show interface virtual
Interface VLAN Pri IP Address SwitchPort Members
--------- ---- ------------------ ------------------
veth1 1 192.0.2.199/24 eth1, eth2, eth3, eth4
eth5, eth6, eth7, eth8
eth9, eth10, eth11, eth12
eth15, eth16
veth2 2 192.168.100.1/24 eth13, eth14
Router#
5. Now each sub-network has an IP address. In order to connect to other routers on the network, you
must turn on a routing protocol. Here, we enable the Routing Information Protocol (RIP) so that
routing updates can be sent to a connected network once the switch starts sending RIP packets.
Then RIP (both version 1 and version 2) will be enabled.
Router(config)# router rip
Router(config-rip-router)# network ?
A.B.C.D/M IP prefix <network>/<length>, e.g., 35.0.0.0/8
Router(config-rip-router)# network 192.0.2.0/24
Router(config-rip-router)#
Router(config-rip-router)# redistribute ?
bgp Border Gateway Protocol (BGP)
connected Connected
kernel Kernel routes
ospf Open Shortest Path First (OSPF)
static Static routes
rip Routing Information Protocol (RIP)
Router(config-rip-router)# redistribute connected