Configuration of static and default rout
I. configuration of static routes
The following experiment configures the topology diagram
Experimental goal: to configure static routes to achieve interworking across the network
1. Configure router R1
Enter interface f0max 0, configure IP, and turn it on.
Enter interface f0max 1, configure IP, and turn it on.
Set up a static route.
Conf t
Int f0/0
Ip address 192.168.20.1 255.255.255.0
No shut
Int f0/1
Ip add 192.168.10.1 255.255.255.0
No shut
Exit
Ip route 192.168.30.0 255.255.255.0 192.168.20.2
View the routing table of PC1
Do show ip route
2. Configure router R2
Enter interface f0max 0, configure IP, and turn it on.
Enter interface f0max 1, configure IP, and turn it on.
Set up a static route.
Conf t
Int f0/0
Ip address 192.168.20.2 255.255.255.0
No shut
Int f0/1
Ip add 192.168.30.1 255.255.255.0
No shut
Exit
Ip route 192.168.10.0 255.255.255.0 192.168.20.1
View the routing table of PC2
Do show ip route
3. Configure the IP address and gateway of PC1
Ip 192.168.10.10 192.168.10.1
4. Configure the IP address and gateway of PC2
Ip 192.168.30.30 192.168.30.1
5. Test the interworking between PC1,PC2.
Ping 192.168.10.10
6 set the route pattern of R1 as the default route
7. Check the connection of PC1\ PC2