Got it

Example for configuring NQA for static IPv4 routes

Latest reply: Jan 18, 2021 08:29:56 4546 7 0 0 1

Hello, Community members!

This post features an example for configuring NQA for static IPv4 routes. Please have a look below.


APPLICABILITY


This example applies to all versions and AR routers.


NETWORKING REQUIREMENTS


NQA for static IPv4 routes can quickly detect network faults and control advertisement of static routes. As shown in Figure 7-2, RouterA connects to RouterB via GE2/0/0 and connects to RouterC via GE1/0/0. Two links are available from RouterA to RouterD: RouterA --> RouterB --> RouterD (primary link) and RouterA --> RouterC --> RouterD (backup link). Configure an NQA ICMP test instance on RouterA to detect the active link. When the active link becomes faulty, packets sent from RouterA to RouterD are switched to the standby link.


Figure 7-2. Networking diagram of configuring NQA for static IPv4 routes

6d1f88bf1f734542be74402e774f0db0


PROCEDURE


1. Configure RouterA.


#
sysname RouterA
#
interface GigabitEthernet1/0/0
ip address 192.168.1.1 255.255.255.0
#
interface GigabitEthernet2/0/0
ip address 192.168.4.1 255.255.255.0
#
interface GigabitEthernet3/0/0
ip address 192.168.6.1 255.255.255.0
#ip route-static 192.168.2.0 255.255.255.0 192.168.1.2ip route-static 192.168.3.0 255.255.255.0 192.168.4.2ip route-static 192.168.5.0 255.255.255.0 192.168.1.2 preference 100  //Set the preference of static routes to 100 so that the static routes can be used as backup routes.ip route-static 192.168.5.0 255.255.255.0 GigabitEthernet2/0/0 192.168.4.2 track nqa admin icmp  //Configure a static route to associate it with an NQA test instance.
#nqa test-instance admin icmp  //Configure an NQA test instance named admin icmp. test-type icmp  //Set the test type to ICMP. destination-address ipv4 192.168.3.1  //Set the destination address of the NQA test instance to 192.168.3.1. frequency 10  //Set the interval between two NQA tests to 10s. probe-count 2  //Set the number of test probes of an NQA test instance to 2. start now  //Start the NQA test instance immediately.
#

   

2. Configure RouterB.


#
sysname RouterB
#
interface GigabitEthernet1/0/0
ip address 192.168.3.2 255.255.255.0
#
interface GigabitEthernet2/0/0
ip address 192.168.4.2 255.255.255.0
#ip route-static 192.168.5.0 255.255.255.0 192.168.3.1ip route-static 192.168.6.0 255.255.255.0 192.168.4.1#

  

3. Configure RouterC.


#
sysname RouterC
#
interface GigabitEthernet1/0/0
ip address 192.168.1.2 255.255.255.0
#
interface GigabitEthernet2/0/0
ip address 192.168.2.1 255.255.255.0
#ip route-static 192.168.5.0 255.255.255.0 192.168.2.2ip route-static 192.168.6.0 255.255.255.0 192.168.1.1#

   

4. Configure RouterD.


#
sysname RouterD
#
interface GigabitEthernet1/0/0
ip address 192.168.3.1 255.255.255.0
#
interface GigabitEthernet2/0/0
ip address 192.168.2.2 255.255.255.0
#
interface GigabitEthernet3/0/0
ip address 192.168.5.1 255.255.255.0
#ip route-static 192.168.1.0 255.255.255.0 192.168.2.1ip route-static 192.168.4.0 255.255.255.0 192.168.3.2ip route-static 192.168.6.0 255.255.255.0 192.168.3.2ip route-static 192.168.6.0 255.255.255.0 192.168.2.1#

   

5. Verify the configuration.


Run the display nqa results test-instance admin icmp command on RouterA to view the NQA test result. The command output displays 'Lost packet ratio: 0 %', indicating that the link status is normal. Run the display ip routing-table command on RouterA to view the IP routing table. The routing table contains the static route with destination network segment 192.168.5.0/24 and next-hop address 192.168.4.2. There is no static route with preference 100 in the routing table.


Run the shutdown command in the view of GE1/0/0 or GE2/0/0 on RouterB to simulate a link failure. Run the display nqa results test-instance admin icmp command on RouterA to view the NQA test result. The command output displays 'Completion:failed' and 'Lost packet ratio: 100 %', indicating that a link failure has been detected. Then run the display ip routing-table command on RouterA to view the IP routing table. The routing table contains the static route with preference 100. There is no static route with destination network segment 192.168.5.0/24 and next-hop address 192.168.4.2.


CONFIGURATION NOTES


  • The static route associated with an NQA test instance is deleted from the routing table only when the NQA test fails. You can run the display nqa results command to view the NQA test result.


  • Before modifying the configuration of an NQA test instance, stop the NQA test instance.


  • If the static route associated with one NQA test instance is associated with another NQA test instance, the association between the static route and the former NQA test instance is removed.


  • Only the NQA ping test instance is used so that RouterA switches services based on the test result. There is no requirement for the peer device configuration.

thank you
View more
  • x
  • convention:

thank you
View more
  • x
  • convention:

this is very helpful.
View more
  • x
  • convention:

this is very helpful.
View more
  • x
  • convention:

Hi Bro,
Can we tracking to 2 destinations for one static-route or not?
Thanks
View more
  • x
  • convention:

this is very helpful, thanks!
View more
  • x
  • convention:

Very helpful. Thanks for sharing
View more
  • x
  • convention:

Comment

You need to log in to comment to the post Login | Register
Comment

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " User Agreement."

My Followers

Login and enjoy all the member benefits

Login

Block
Are you sure to block this user?
Users on your blacklist cannot comment on your post,cannot mention you, cannot send you private messages.
Reminder
Please bind your phone number to obtain invitation bonus.