Skip to content

Regarding the behavior change of the BGP network feature. #18375

@zice312963205

Description

@zice312963205

Description

The current BGP network import-check feature causes BGP to subscribe to Zebra for all networks in a next-hop subscription manner. Due to a previous modification, Zebra can no longer distinguish whether this subscribed RNH (Resolved Next Hop) is used as a next hop in routes or for BGP networks. This introduces an implicit functional difference: Previously, the subscription behavior for network import-check did not attempt to match the contents of 'ip nht bgp route-map xxx'. Therefore, all network routes only checked for the existence of the route in Zebra. After the modification, the subscription behavior triggered by these networks attempts to match the contents of 'ip nht bgp route-map xxx', leading to behavioral differences in networks after upgrading FRR versions. This behavior cannot be corrected through any command.

From the perspective of the BGP network feature itself, it seems inappropriate to match the contents of 'ip nht bgp route-map xxx'. This route-map should be used solely for BGP next-hop iteration. Is this logic correct, and should we address this issue?

r1(config)# do show ip nht
VRF default:
Resolve via default: off
1.1.1.1
resolved via static, prefix 1.1.1.1/32
unreachable (blackhole), weight 1
Client list: bgp(fd 19)(filtered)
r1(config)#

config:
ip prefix-list nht seq 5 permit 2.2.2.2/32 ge 32 le 32
!
route-map nht permit 10
match ip address prefix-list nht
exit
!
route-map nht deny 20
exit
!

router bgp 65001
bgp router-id 192.0.2.1
no bgp ebgp-requires-policy
no bgp enforce-first-as
no bgp hard-administrative-reset
no bgp default ipv4-unicast
no bgp graceful-restart notification
!
address-family ipv4 unicast
network 1.1.1.1/32
exit-address-family
!
exit
!
ip nht bgp route-map nht
!

Version

FRRouting 10.3

How to reproduce

config:
ip prefix-list nht seq 5 permit 2.2.2.2/32 ge 32 le 32
!
route-map nht permit 10
match ip address prefix-list nht
exit
!
route-map nht deny 20
exit
!

router bgp 65001
bgp router-id 192.0.2.1
no bgp ebgp-requires-policy
no bgp enforce-first-as
no bgp hard-administrative-reset
no bgp default ipv4-unicast
no bgp graceful-restart notification
!
address-family ipv4 unicast
network 1.1.1.1/32
exit-address-family
!
exit
!
ip nht bgp route-map nht
!

Expected behavior

please see the description

Actual behavior

please see the description

Additional context

No response

Checklist

  • I have searched the open issues for this bug.
  • I have not included sensitive information in this report.

Metadata

Metadata

Assignees

No one assigned

    Labels

    triageNeeds further investigation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions