No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

The IP Prefix-based BGP Route-Policy Configured on an NE40E-X3 Does Not Take Effect

Publication Date:  2019-04-24 Views:  16 Downloads:  0
Issue Description

The IP prefix-based BGP route-policy configured on an NE40E-X3 does not take effect.
Device configuration:
bgp 100
group vdf external
peer 12.1.1.2 as-number 200
peer 12.1.1.2 group vdf
 #
ipv4-family unicast
  undo synchronization
  import-route direct
  peer vdf enable
  peer vdf ip-prefix 11 export
  peer 12.1.1.2 enable
  peer 12.1.1.2 group vdf
  peer 12.1.1.2 ip-prefix 12 export
#
ip ip-prefix 11 index 10 permit 10.0.0.0 24
ip ip-prefix 11 index 20 permit 10.0.1.0 24
ip ip-prefix 12 index 10 permit 10.0.2.0 24
#
Currently, the peer device can learn only the route destined for the IP address 10.0.2.0 24. After the peer 12.1.1.2 ip-prefix 12 export configuration is deleted, the peer device can learn all the direct routes, which is abnormal.
[Huawei]disp bgp rout peer 12.1.1.2 advertised-routes

BGP Local router ID is 1.1.1.1
 Status codes: * - valid, > - best, d - damped,
               h - history,  i - internal, s - suppressed, S - Stale
               Origin : i - IGP, e - EGP, ? - incomplete


Total Number of Routes: 5
      Network            NextHop        MED        LocPrf    PrefVal Path/Ogn

*>   1.1.1.0/24         12.1.1.1        0                     0      100?
*>   10.0.0.0/24        12.1.1.1        0                     0      100?
*>   10.0.1.0/24        12.1.1.1        0                     0      100?
*>   10.0.2.0/24        12.1.1.1        0                     0      100?
*>   12.1.1.0/24        12.1.1.1        0                     0      100?

Handling Process

1. Run the undo peer 12.1.1.2 ip-prefix 12 export command to check the BGP routes that have been sent to the peer device from the local device. It is found that all direct routes have been sent from the local device to the peer device. The route-policy for the vdf group does not take effect.
[Huawei]disp bgp rout peer 12.1.1.2 advertised-routes

BGP Local router ID is 1.1.1.1
 Status codes: * - valid, > - best, d - damped,
               h - history,  i - internal, s - suppressed, S - Stale
               Origin : i - IGP, e - EGP, ? - incomplete


Total Number of Routes: 5
      Network            NextHop        MED        LocPrf    PrefVal Path/Ogn

*>   1.1.1.0/24         12.1.1.1        0                     0      100?
*>   10.0.0.0/24        12.1.1.1        0                     0      100?
*>   10.0.1.0/24        12.1.1.1        0                     0      100?
*>   10.0.2.0/24        12.1.1.1        0                     0      100?
*>   12.1.1.0/24        12.1.1.1        0                     0      100?

2. Check documents. It is found that the IP address 12.1.1.2 belongs to the group vdf. After the peer 12.1.1.2 ip-prefix 12 export command is run, the BGP peer for 12.1.1.2 does not inherit policies (not only ip-prefix but policies such as route-policy) of the group vdf. However, other attributes need to be inherited. Therefore, the undo peer 12.1.1.2 ip-prefix 12 export command does not inherit policies of the group. Because the device is configured to import direct routes, all direct routes are sent to the peer.

Root Cause

The IP address 12.1.1.2 belongs to the group vdf. After the peer 12.1.1.2 ip-prefix 12 export command is run, the BGP peer for 12.1.1.2 does not inherit policies (not only ip-prefix but policies such as route-policy) of the group vdf. However, other attributes need to be inherited. Therefore, the undo peer 12.1.1.2 ip-prefix 12 export command does not inherit policies of the group.

Solution

Run the peer 12.1.1.2 ip-prefix 11 export command to configure the same ip-prefix policy as the group vdf.

END