laitimes

Beginners in dynamic routing experiments: Quickly master the core knowledge points

author:Network Engineer - Director Guo

Hello everyone, this is G-LAB IT. Today, I will take you to learn about Huawei's dynamic routing experimental configuration, get started for novices, and quickly master the core knowledge points!

01. Experimental topology

Beginners in dynamic routing experiments: Quickly master the core knowledge points

02. Experimental requirements

1. Run the corresponding routing protocol according to the topology

2. Each router has its own loopback port, and the declared area is not limited

3. Reduce the size of the routing table as much as possible in RIP

4. From the loopback port of R3 to the loopback port of R6 pinging (note that there is no learning redistribution, use static to solve the problem)

5.RS go to R6 and go straight from R6 instead of R7

03. Experimental procedures

a. Basic interface address configuration

R1:

[R1]int lo0

[R1-LoopBack0]ip add 11.1.1.1 24

[R1]int g0/0/0

[R1-GigabitEthernet0/0/0]ip add 13.1.1.1 24

[R1]int g0/0/1

[R1-GigabitEthernet0/0/1]ip add 12.1.1.1 24

R2:

[R2]int lo0

[R2-LoopBack0]ip add 22.1.1.1 24

[R2]int g0/0/0

[R2-GigabitEthernet0/0/0]ip add 12.1.1.2 24

[R2]int g0/0/1

[R2-GigabitEthernet0/0/1]ip add 24.1.1.2 24

[R2]int g0/0/2

[R2-GigabitEthernet0/0/2]ip add 25.1.1.2 24

R3:

[R3]int lo0

[R3-LoopBack0]ip add 33.1.1.1 24

[R3]int g0/0/0

[R3-GigabitEthernet0/0/0]ip add 13.1.1.3 24

[R3]int g0/0/1

[R3-GigabitEthernet0/0/1]ip add 34.1.1.3 24

R4:

[R4]int lo0

[R4-LoopBack0]ip add 44.1.1.1 24

[R4]int lo1

[R4-LoopBack1]ip add 172.16.11.1 24

[R4]int lo2

[R4-LoopBack2]ip add 172.16.12.1 24

[R4]int g0/0/0

[R4-GigabitEthernet0/0/0]ip add 24.1.1.4 24

[R4]int g0/0/1

[R4-GigabitEthernet0/0/1]ip add 34.1.1.4 24

R5:

[R5]int lo0

[R5-LoopBack0]ip add 55.1.1.1 24

[R5]int g0/0/0

[R5-GigabitEthernet0/0/0]ip add 57.1.1.5 24

[R5]int g0/0/1

[R5-GigabitEthernet0/0/1]ip add 25.1.1.5 24

[R5]int s1/0/0

[R5-Serial1/0/0]ip add 56.1.1.5 24

R6:

[R6]int lo0

[R6-LoopBack0]ip add 66.1.1.1 24

[R6]int g0/0/0

[R6-GigabitEthernet0/0/0]ip add 67.1.1.6 24

[R6]int s1/0/0

[R6-Serial1/0/0]ip add 56.1.1.6 24

R7:

[R7]int lo0

[R7-LoopBack0]ip add 77.1.1.1 24

[R7]int g0/0/0

[R7-GigabitEthernet0/0/0]ip add 67.1.1.7 24

[R7]int g0/0/1

[R7-GigabitEthernet0/0/1]ip add 57.1.1.7 24

b. Run the corresponding dynamic routing protocol

R1:

[R1]rip (运行RIP路由协议)

[R1-rip-1]version 2 (版本2)

[R1-rip-1]undo summary (关闭自动汇总)

[R1-rip-1]network 11.0.0.0 (主类宣告)

[R1-rip-1]network 12.0.0.0

[R1-rip-1]network 13.0.0.0

R2:

[R2]rip (运行RIP路由协议)

[R2-rip-1]version 2 (版本2)

[R2-rip-1]undo summary (关闭自动汇总)

[R2-rip-1]network 22.0.0.0 (主类宣告)

[R2-rip-1]network 12.0.0.0

[R2-rip-1]network 24.0.0.0

R3:

[R3]rip (运行RIP路由协议)

[R3-rip-1]version 2 (版本2)

[R3-rip-1]undo summary (关闭自动汇总)

[R3-rip-1]network 33.0.0.0 (主类宣告)

[R3-rip-1]network 13.0.0.0

[R3-rip-1]network 34.0.0.0

R4:

[R4]rip (运行RIP路由协议)

[R4-rip-1]version 2 (版本2)

[R4-rip-1]undo summary (关闭自动汇总)

[R4-rip-1]network 44.0.0.0 (主类宣告)

[R4-rip-1]network 172.16.0.0

[R4-rip-1]network 24.0.0.0

[R4-rip-1]network 34.0.0.0

At this point, R2 should be able to receive 7 rip routes (5 loopbacks, 2 physical links):

Beginners in dynamic routing experiments: Quickly master the core knowledge points

R5:

[R5] ospf 1 (running OSPF protocol)

[R5-ospf-1]area 1

[R5-ospf-1-area-0.0.0.1]network 55.1.1.0 0.0.0.255

[R5-ospf-1-area-0.0.0.1]network 56.1.1.0 0.0.0.255

(Roundabout, S1/0/0 announced into zone 1)

[R5-ospf-1]area 2

[R5-ospf-1-area-0.0.0.2]network 57.1.1.0 0.0.0.255

(G0/0/0 port declared into Zone 2)

R6:

[R6] ospf 1 (running OSPF protocol)

[R6-ospf-1]ar 0

[R6-ospf-1-area-0.0.0.0]network 66.1.1.0 0.0.0.255

[R6-ospf-1-area-0.0.0.0]network 67.1.1.0 0.0.0.255

(Roundabout port, G0/0/0 port announced into area 0)

[R6-ospf-1]area 1

[R6-ospf-1-area-0.0.0.1]network 56.1.1.0 0.0.0.255

(S1/0/0 port announced into Zone 1)

R7:

[R7] ospf 1 (running OSPF protocol)

[R7-ospf-1]area 0

[R7-ospf-1-area-0.0.0.0]network 77.1.1.0 0.0.0.255

[R7-ospf-1-area-0.0.0.0]network 67.1.1.0 0.0.0.255

(Roundabout and G0/0/0 ports are declared into zone 0)

[R7-ospf-1]area 2

[R7-ospf-1-area-0.0.0.2]network 57.1.1.0 0.0.0.255

(G0/0/1 is declared in Zone 2)

In this case, R5 should have 2 OSPF neighbors and be able to learn 3 OSPF routes (2 loopback ports and 1 physical link):

Beginners in dynamic routing experiments: Quickly master the core knowledge points
Beginners in dynamic routing experiments: Quickly master the core knowledge points

c. RIP thin routing table

R2 can learn 7 RIP routes through RIP, of which routes 172.16.11.0/24 and 172.16.12.0/24 can be manually aggregated into one route.

R4:

[R4]int g0/0/0

[R4-GigabitEthernet0/0/0]rip summary-address 172.16.8.0 255.255.248.0

[R4]int g0/0/1

[R4-GigabitEthernet0/0/1]rip summary-address 172.16.8.0 255.255.248.0

(Configure RIP manual summary on a physical interface)

In this case, six RIP routes can be learned through RIP on R2, and the original routes 172.16.11.0/24 and 172.16.12.0/24 can be manually summarized into one route, 172.16.8.0/21.

Beginners in dynamic routing experiments: Quickly master the core knowledge points

d.R3和R6的环回口通信

We found that there is no connection between the two routing protocols, and the border routers R2 and R5 of the two routing protocols do not have routes for the peer protocol, so we first use static routes to solve the communication problem that the border routes do not pass through the protocol:

[R2]ip route-static 0.0.0.0 0.0.0.0 25.1.1.5

[R5]ip route-static 0.0.0.0 0.0.0.0 25.1.1.2

Static routes can only solve the routing problem of the border router, but R3 and R6 only have routes of their own protocols, and there are no routes on the other side, so we need to configure the dynamic routing protocol to deliver the default route, so that R3 and R6 can drop the route to the peer to the border router.

R2:

[R2]rip

[R2-rip-1]default-route originate

R1/R3/R4上都会多出一条RIP的默认路由:

Beginners in dynamic routing experiments: Quickly master the core knowledge points

R5:

[R5]ospf 1

[R5-ospf-1]default-route-advertise

(Since there is a default route on R5, there is no need to add always)

On R6 and R7, there will be an additional default route for OSPF:

Beginners in dynamic routing experiments: Quickly master the core knowledge points

At this time, the loopback communication between R3 and R6 is as follows:

Beginners in dynamic routing experiments: Quickly master the core knowledge points

e.R5和R6的环回口通信

In this case, the loopback route from R5 to R6 is from R7, because the OSPF route selection is only related to the cost of the inbound interface of the route flow direction, the default cost of Huawei's S port is 48, the default cost of the Ethernet port is 1, the default cost of the loopback port is 0, the cost of the loopback route directly from R6 is 48, and the cost of the R6 loopback route learned from R7 is 2, so it is preferable to learn from R7.

Beginners in dynamic routing experiments: Quickly master the core knowledge points
Beginners in dynamic routing experiments: Quickly master the core knowledge points

If you want R5 to go directly from R6 to the loopback port of R6, you only need to modify the cost of the inbound interface (for example, the cost of the g0/0/0 interface of R5 is greater than 47):

R5:

[R5]int g0/0/0

[R5-GigabitEthernet0/0/0]ospf cost 48

In this case, R5 learns that the next hop of the loopback route of R6 is R6, and the cost of the route is 48.

The above is the experimental configuration that Huawei Junior High School needs to learn

Beginners in dynamic routing experiments: Quickly master the core knowledge points

G-LAB IT LAB COURSE

Beginners in dynamic routing experiments: Quickly master the core knowledge points

Read on