summaryrefslogtreecommitdiffstats
path: root/tests/topotests/bgp_bmp
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2024-10-31 09:18:56 +0100
committerPhilippe Guibert <philippe.guibert@6wind.com>2024-12-11 11:29:37 +0100
commit96aea62fe2e84fc3ba74bf4a01305e30386f20a1 (patch)
tree287940a386a5b7aa6ccff49a6a9a52ae751a3c3f /tests/topotests/bgp_bmp
parentbgpd: bmp, add peer distinguisher support for peer up/down (diff)
downloadfrr-96aea62fe2e84fc3ba74bf4a01305e30386f20a1.tar.xz
frr-96aea62fe2e84fc3ba74bf4a01305e30386f20a1.zip
bgpd, topotests: bmp, fix wrong peer type for vrf route messages
When running the bgp_bmp_2 vrf test, peer route messages from the pre and post policy are received with a wrong peer type value > {"peer_type": "global instance", "policy": "pre-policy", "ipv6": false, > "peer_ip": "192.168.0.2", "peer_distinguisher": "0:0", "peer_asn": 65502, > "peer_bgp_id": "192.168.0.2", "timestamp": "2024-10-31 08:19:58.111963", > "bmp_log_type": "update", "origin": "IGP", "as_path": "65501 65502", > "bgp_nexthop": "192.168.0.2", "ip_prefix": "172.31.0.15/32", "seq": 15} In addition to global instance peers, RFC7854 defines RD instance peers. This value can be used for peers which are on a BGP VRF instance, for example with an L3VPN setup. When configuring a BGP VRF instance, the peer type should be seen as an RD instance peer. Fix this by modifying the BMP client: - update the peer type for vrf mirror and monitoring messages - modify bgp_bmp_2 vrf test to control the peer_type value > {"peer_type": "route distinguisher instance", "policy": "pre-policy", "ipv6": false, > "peer_ip": "192.168.0.2", "peer_distinguisher": "0:0", "peer_asn": 65502, > "peer_bgp_id": "192.168.0.2", "timestamp": "2024-10-31 08:19:58.111963", > "bmp_log_type": "update", "origin": "IGP", "as_path": "65501 65502", > "bgp_nexthop": "192.168.0.2", "ip_prefix": "172.31.0.15/32", "seq": 15} Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'tests/topotests/bgp_bmp')
-rw-r--r--tests/topotests/bgp_bmp/bmp1vrf/bmp-update-post-policy-step1.json4
-rw-r--r--tests/topotests/bgp_bmp/bmp1vrf/bmp-update-pre-policy-step1.json4
-rw-r--r--tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-post-policy-step1.json4
-rw-r--r--tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-pre-policy-step1.json4
4 files changed, 8 insertions, 8 deletions
diff --git a/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-post-policy-step1.json b/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-post-policy-step1.json
index d5d9d6518..18f40b16c 100644
--- a/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-post-policy-step1.json
+++ b/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-post-policy-step1.json
@@ -12,7 +12,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192.168.0.2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "post-policy"
},
"2111::1111/128": {
@@ -27,7 +27,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192:168::2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "post-policy",
"safi": 1
}
diff --git a/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-pre-policy-step1.json b/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-pre-policy-step1.json
index e11badc04..61ef0eab8 100644
--- a/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-pre-policy-step1.json
+++ b/tests/topotests/bgp_bmp/bmp1vrf/bmp-update-pre-policy-step1.json
@@ -12,7 +12,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192.168.0.2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "pre-policy"
},
"2111::1111/128": {
@@ -27,7 +27,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192:168::2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "pre-policy",
"safi": 1
}
diff --git a/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-post-policy-step1.json b/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-post-policy-step1.json
index de84307a4..c28ce851a 100644
--- a/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-post-policy-step1.json
+++ b/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-post-policy-step1.json
@@ -9,7 +9,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192.168.0.2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "post-policy"
},
"2111::1111/128": {
@@ -21,7 +21,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192:168::2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "post-policy",
"safi": 1
}
diff --git a/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-pre-policy-step1.json b/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-pre-policy-step1.json
index 1c34498b7..976c7d471 100644
--- a/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-pre-policy-step1.json
+++ b/tests/topotests/bgp_bmp/bmp1vrf/bmp-withdraw-pre-policy-step1.json
@@ -9,7 +9,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192.168.0.2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "pre-policy"
},
"2111::1111/128": {
@@ -21,7 +21,7 @@
"peer_bgp_id": "192.168.0.2",
"peer_distinguisher": "0:0",
"peer_ip": "192:168::2",
- "peer_type": "global instance",
+ "peer_type": "route distinguisher instance",
"policy": "pre-policy",
"safi": 1
}