Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Hot standby routing Protocol (HSRP) configuration

2025-02-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >

Share

Shulou(Shulou.com)06/01 Report--

-configuration of PC-

PC#configure terminal

PC (config) # no ip routing

PC (config) # ip default-gateway 192.168.1.100

PC (config) # interface e0Universe 0

PC (config-if) # ip address 192.168.1.200 255.255.255.0

PC (config-if) # no shutdown

PC (config-if) # end

-configuration of R1-

R1#configure terminal

R1 (config) # interface f0bin0

R1 (config-if) # ip address 192.168.1.1 255.255.255.0

R1 (config-if) # no shutdown

R1 (config-if) # standby 1 ip 192.168.1.100

R1 (config-if) # standby 1 priority 120

R1 (config-if) # standby 1 preempt

R1 (config-if) # standby 1 track s1ap0 30

R1 (config-if) # exit

R1 (config-if) # interface s1and0

R1 (config-if) # ip address 13.13.13.1 255.255.255.0

R1 (config-if) # no shutdown

R1 (config-if) # end

-configuration of R2-

R2#configure terminal

R2 (config) # interface f0and0

R2 (config-if) # ip address 192.168.1.2 255.255.255.0

R2 (config-if) # no shutdown

R2 (config-if) # standby 1 ip 192.168.1.100

R2 (config-if) # standby 1 priority 100

R2 (config-if) # standby 1 preempt

R2 (config-if) # interface S1 Compact 1

R2 (config-if) # ip address 23.23.23.2 255.255.255.0

R2 (config-if) # no shutdown

R2 (config-if) # end

-configuration of R3-

R3#configure terminal

R3 (config) # interface s1ap0

R3 (config-if) # ip address 13.13.13.3 255.255.255.0

R3 (config-if) # no shutdown

R3 (config-if) # interface s1Action1

R3 (config-if) # ip address 23.23.23.3 255.255.255.0

R3 (config-if) # no shutdown

R3 (config-if) # exit

R3 (config-if) # interface loopback 0

R3 (config-if) # ip address 202.101.18.8 255.255.255.0

R3 (config-if) # end

Quick configuration method

-configuration of PC-

Configure terminal

No ip routing

Ip default-gateway 192.168.1.100

Interface e0/0

Ip address 192.168.1.200 255.255.255.0

No shutdown

End

-configuration of R1-

Configure terminal

Interface f0/0

Ip address 192.168.1.1 255.255.255.0

No shutdown

Standby 1 ip 192.168.1.100

Standby 1 priority 120

Standby 1 preempt

Standby 1 track s1/0 30

Interface s1/0

Ip address 13.13.13.1 255.255.255.0

No shutdown

End

-configuration of R2-

Configure terminal

Interface f0/0

Ip address 192.168.1.2 255.255.255.0

No shutdown

Standby 1 ip 192.168.1.100

Standby 1 priority 100

Standby 1 preempt

Interface s1/0

Ip address 23.23.23.2 255.255.255.0

No shutdown

End

-configuration of R3-

Configure terminal

Interface s1/0

Ip address 13.13.13.3 255.255.255.0

No shutdown

Interface s1/1

Ip address 23.23.23.3 255.255.255.0

No shutdown

Interface loopback 0

Ip address 202.101.18.8 255.255.255.0

End

Description: if you want to see the results of the configuration, you can enter a command on R1

R1#show standby

You can see the following information

Virtual IP address is 192.168.1.100 configured

Active router is local

Standby router is 192.168.1.2 expires in 7.900

It indicates that 192.168.1.2 is the Standby status.

If port S1 / 0 of R1 is disabled

R1#configure terminal

R1 (config) # interface s1and0

R1 (config-if) # shutdown

R1#show standby

You can see the following information:

Virtual IP address is 192.168.1.100 configured

Active router is 192.168.1.2, priority 100 expires in 7.940

Standby router is local

It indicates that 192.168.1.2 is the Active status.

Of course, if you want to traceroute 202.101.18.8 on PC, you must configure a routing protocol.

If you do not want R1 and R2 to discover each other through the RIP routing protocol, you can configure it like this

R1 (config) # router rip

R1 (config-router) # network 13.13.13.0

R1 (config-router) # network 192.168.1.0

R1 (config-router) # passive-interface f0bin0

R2 (config) # router rip

R1 (config-router) # network 23.23.23.0

R1 (config-router) # network 192.168.1.0

R2 (config-router) # passive-interface f0and0

Now, you can try the traceroute command on PC

PC#traceroute 202.101.18.8

Type escape sequence to abort.

Tracing the route to 202.101.18.8

1 192.168.1.1 52 msec 68 msec 20 msec

2 13.13.13.3 28 msec * 12 msec

PC#

Close the port of S1gamo on R1 and try again.

PC#traceroute 202.101.18.8

Type escape sequence to abort.

Tracing the route to 202.101.18.8

1 192.168.1.2 68 msec 109 msec 32 msec

2 23.23.3 64 msec * 0 msec

PC#

The correctness of the results can be seen from the two outputs.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Network Security

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report