mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-06-03 02:57:47 +00:00
tests: zebra_fec_nexthop_resolution improve
a) timers are really large preventing convergence in 30 seconds b) The same configuration does not need to be initiated 60 times when things are not working properly. Once is enough. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
parent
2a94de8af2
commit
6a945b4104
@ -1,5 +1,6 @@
|
||||
!
|
||||
router bgp 65500
|
||||
timers bgp 3 9
|
||||
bgp router-id 192.0.2.1
|
||||
neighbor 192.0.2.3 remote-as 65500
|
||||
neighbor 192.0.2.3 update-source lo
|
||||
@ -7,6 +8,7 @@ router bgp 65500
|
||||
neighbor 192.0.2.7 ttl-security hops 10
|
||||
neighbor 192.0.2.7 disable-connected-check
|
||||
neighbor 192.0.2.7 update-source lo
|
||||
neighbor 192.0.2.7 timers connect 5
|
||||
!
|
||||
address-family ipv4 unicast
|
||||
network 192.0.2.1/32
|
||||
|
@ -1,4 +1,5 @@
|
||||
router bgp 65500
|
||||
timers bgp 3 9
|
||||
bgp router-id 192.0.2.2
|
||||
neighbor 192.0.2.1 remote-as 65500
|
||||
neighbor 192.0.2.1 update-source lo
|
||||
|
@ -1,4 +1,5 @@
|
||||
router bgp 65500
|
||||
timers bgp 3 9
|
||||
bgp router-id 192.0.2.3
|
||||
neighbor 192.0.2.1 remote-as 65500
|
||||
neighbor 192.0.2.1 update-source lo
|
||||
|
@ -1,5 +1,6 @@
|
||||
!
|
||||
router bgp 65500
|
||||
timers bgp 3 9
|
||||
bgp router-id 192.0.2.4
|
||||
neighbor 192.0.2.1 remote-as 65500
|
||||
neighbor 192.0.2.1 ttl-security hops 10
|
||||
|
@ -1,4 +1,5 @@
|
||||
router bgp 65500
|
||||
timers bgp 3 9
|
||||
bgp router-id 192.0.2.5
|
||||
neighbor 192.0.2.3 remote-as 65500
|
||||
neighbor 192.0.2.3 update-source lo
|
||||
|
@ -1,10 +1,12 @@
|
||||
!
|
||||
router bgp 65500
|
||||
timers bgp 3 9
|
||||
bgp router-id 192.0.2.7
|
||||
neighbor 192.0.2.1 remote-as 65500
|
||||
neighbor 192.0.2.1 ttl-security hops 10
|
||||
neighbor 192.0.2.1 disable-connected-check
|
||||
neighbor 192.0.2.1 update-source lo
|
||||
neighbor 192.0.2.1 timers connect 5
|
||||
neighbor 192.0.2.5 remote-as 65500
|
||||
neighbor 192.0.2.5 update-source lo
|
||||
!
|
||||
|
@ -156,16 +156,17 @@ def test_zebra_fec_nexthop_resolution_bgp():
|
||||
def _check_bgp_session():
|
||||
r1 = tgen.gears["r1"]
|
||||
|
||||
tgen.gears["r3"].vtysh_cmd("config \n no mpls fec nexthop-resolution \n end")
|
||||
tgen.gears["r3"].vtysh_cmd("config \n mpls fec nexthop-resolution \n end")
|
||||
tgen.gears["r5"].vtysh_cmd("config \n no mpls fec nexthop-resolution \n end")
|
||||
tgen.gears["r5"].vtysh_cmd("config \n mpls fec nexthop-resolution \n end")
|
||||
output = json.loads(r1.vtysh_cmd("show bgp summary json"))
|
||||
|
||||
if output["ipv4Unicast"]["peers"]["192.0.2.7"]["state"] == "Established":
|
||||
return None
|
||||
return False
|
||||
|
||||
tgen.gears["r3"].vtysh_cmd("config \n no mpls fec nexthop-resolution \n end")
|
||||
tgen.gears["r3"].vtysh_cmd("config \n mpls fec nexthop-resolution \n end")
|
||||
tgen.gears["r5"].vtysh_cmd("config \n no mpls fec nexthop-resolution \n end")
|
||||
tgen.gears["r5"].vtysh_cmd("config \n mpls fec nexthop-resolution \n end")
|
||||
|
||||
test_func1 = functools.partial(_check_bgp_session)
|
||||
_, result1 = topotest.run_and_expect(test_func1, None, count=60, wait=0.5)
|
||||
assert result1 is None, "Failed to verify the fec_nexthop_resolution: bgp session"
|
||||
|
Loading…
Reference in New Issue
Block a user