1 .. _bgp-user-guide-bgp-peering:
5 To exchange routing information between two BGP systems (peers), it is required to configure a peering on both BGP speakers first.
6 This mean that each BGP speaker has a white list of neighbors, representing remote peers, with which the peering is allowed.
7 The TCP connection is established between two peers and they exchange messages to open and confirm the connection parameters followed by routes exchange.
9 Here is a sample basic neighbor configuration:
11 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
19 **Content-Type:** ``application/xml``
25 :emphasize-lines: 2,5,6,11,12,17,19
27 <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
28 <neighbor-address>192.0.2.1</neighbor-address>
31 <hold-time>90</hold-time>
32 <connect-retry>10</connect-retry>
37 <remote-port>179</remote-port>
38 <passive-mode>false</passive-mode>
39 <!--<local-address>192.0.2.5</local-address>-->
43 <peer-type>INTERNAL</peer-type>
50 @line 2: IP address of the remote BGP peer. Also serves as an unique identifier of a neighbor in a list of neighbors.
52 @line 5: Proposed number of seconds for value of the Hold Timer. Default value is **90**.
54 @line 6: Time interval in seconds between attempts to establish session with the peer. Effective in active mode only. Default value is **30**.
56 @line 11: Remote port number to which the local BGP is connecting. Effective in active mode only. Default value **179**.
58 @line 12: Wait for peers to issue requests to open a BGP session, rather than initiating sessions from the local router. Default value is **false**.
60 @line 13: Optional Local IP (either IPv4 or IPv6) address used to establish connections to the remote peer. Effective in active mode only.
62 @line 17: Explicitly designate the peer as internal or external. Default value is **INTERNAL**.
64 @line 19: Enable families.
68 **Content-Type:** ``application/json``
74 :emphasize-lines: 4,7,8,13,14,18,20
79 "neighbor-address": "192.0.2.1",
89 "passive-mode": "false"
93 "peer-type": "INTERNAL"
100 @line 4: IP address of the remote BGP peer. Also serves as an unique identifier of a neighbor in a list of neighbors.
102 @line 7: Proposed number of seconds for value of the Hold Timer. Default value is **90**.
104 @line 8: Time interval in seconds between attempts to establish session with the peer. Effective in active mode only. Default value is **30**.
106 @line 13: Remote port number to which the local BGP is connecting. Effective in active mode only. Default value **179**.
108 @line 14: Wait for peers to issue requests to open a BGP session, rather than initiating sessions from the local router. Default value is **false**.
110 @line 18: Explicitly designate the peer as internal or external. Default value is **INTERNAL**.
112 @line 20: Enable families.
116 Once the remote peer is connected and it advertised routes to local BGP system, routes are stored in peer's RIBs.
117 The RIBs can be checked via REST:
119 **URL:** ``/restconf/operational/bgp-rib:bgp-rib/rib/bgp-example/peer/bgp:%2F%2F192.0.2.1``
121 **RFC8040 URL:** ``/rests/data/bgp-rib:bgp-rib/rib=bgp-example/peer=bgp%3A%2F%2F192.0.2.1?content=nonconfig``
133 :emphasize-lines: 8,13,35,40,62,66
135 <peer xmlns="urn:opendaylight:params:xml:ns:yang:bgp-rib">
136 <peer-id>bgp://192.0.2.1</peer-id>
138 <afi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:ipv4-address-family</afi>
139 <safi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:unicast-subsequent-address-family</safi>
141 <peer-role>ibgp</peer-role>
144 <afi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:ipv4-address-family</afi>
145 <safi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:unicast-subsequent-address-family</safi>
146 <ipv4-routes xmlns="urn:opendaylight:params:xml:ns:yang:bgp-inet">
149 <prefix>10.0.0.10/32</prefix>
159 <global>10.10.1.1</global>
165 <uptodate>true</uptodate>
171 <afi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:ipv4-address-family</afi>
172 <safi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:unicast-subsequent-address-family</safi>
173 <ipv4-routes xmlns="urn:opendaylight:params:xml:ns:yang:bgp-inet">
176 <prefix>10.0.0.10/32</prefix>
186 <global>10.10.1.1</global>
192 <uptodate>true</uptodate>
198 <afi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:ipv4-address-family</afi>
199 <safi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:unicast-subsequent-address-family</safi>
200 <ipv4-routes xmlns="urn:opendaylight:params:xml:ns:yang:bgp-inet"></ipv4-routes>
201 <attributes></attributes>
206 @line 8: **Adj-RIB-In** - Per-peer RIB, which contains unprocessed routes that has been advertised to local BGP speaker by the remote peer.
208 @line 13: Here is the reported route with destination *10.0.0.10/32* in Adj-RIB-In.
210 @line 35: **Effective-RIB-In** - Per-peer RIB, which contains processed routes as a result of applying inbound policy to Adj-RIB-In routes.
212 @line 40: Here is the reported route with destination *10.0.0.10/32*, same as in Adj-RIB-In, as it was not touched by import policy.
214 @line 62: **Adj-RIB-Out** - Per-peer RIB, which contains routes for advertisement to the peer by means of the local speaker's UPDATE message.
216 @line 66: The peer's Adj-RIB-Out is empty as there are no routes to be advertise from local BGP speaker.
224 :emphasize-lines: 12,18,42,48,72,76
229 "peer-id": "bgp://192.0.2.1",
231 "supported-tables": [
233 "afi": "bgp-types:ipv4-address-family",
234 "safi": "bgp-types:unicast-subsequent-address-family"
240 "afi": "bgp-types:ipv4-address-family",
241 "safi": "bgp-types:unicast-subsequent-address-family",
242 "bgp-inet:ipv4-routes":{
246 "prefix": "10.0.0.10/32",
255 "global": "10.10.1.1"
267 "effective-rib-in": {
270 "afi": "bgp-types:ipv4-address-family",
271 "safi": "bgp-types:unicast-subsequent-address-family",
272 "bgp-inet:ipv4-routes":{
276 "prefix": "10.0.0.11/32",
285 "global": "10.11.1.1"
300 "afi": "bgp-types:ipv4-address-family",
301 "safi": "bgp-types:unicast-subsequent-address-family"
309 @line 12: **Adj-RIB-In** - Per-peer RIB, which contains unprocessed routes that has been advertised to local BGP speaker by the remote peer.
311 @line 18: Here is the reported route with destination *10.0.0.10/32* in Adj-RIB-In.
313 @line 42: **Effective-RIB-In** - Per-peer RIB, which contains processed routes as a result of applying inbound policy to Adj-RIB-In routes.
315 @line 48: Here is the reported route with destination *10.0.0.10/32*, same as in Adj-RIB-In, as it was not touched by import policy.
317 @line 72: **Adj-RIB-Out** - Per-peer RIB, which contains routes for advertisement to the peer by means of the local speaker's UPDATE message.
319 @line 76: The peer's Adj-RIB-Out is empty as there are no routes to be advertise from local BGP speaker.
323 Also the same route should appeared in Loc-RIB now:
325 **URL:** ``/restconf/operational/bgp-rib:bgp-rib/rib/bgp-example/loc-rib/tables/bgp-types:ipv4-address-family/bgp-types:unicast-subsequent-address-family/ipv4-routes``
337 :emphasize-lines: 4,6,8,11,14
339 <ipv4-routes xmlns="urn:opendaylight:params:xml:ns:yang:bgp-inet">
342 <prefix>10.0.0.10/32</prefix>
352 <global>10.10.1.1</global>
358 @line 4: **Destination** - IPv4 Prefix Address.
360 @line 6: **AS_PATH** - mandatory attribute, contains a list of the autonomous system numbers through that routing information has traversed.
362 @line 8: **ORIGIN** - mandatory attribute, indicates an origin of the route - **ibgp**, **egp**, **incomplete**.
364 @line 11: **LOCAL_PREF** - indicates a degree of preference for external routes, higher value is preferred.
366 @line 14: **NEXT_HOP** - mandatory attribute, defines IP address of the router that should be used as the next hop to the destination.
374 :emphasize-lines: 6,8,10,13,16
377 "bgp-inet:ipv4-routes":{
381 "prefix": "10.0.0.10/32",
391 "global": "10.10.1.1"
399 @line 6: **Destination** - IPv4 Prefix Address.
401 @line 8: **AS_PATH** - mandatory attribute, contains a list of the autonomous system numbers through that routing information has traversed.
403 @line 10: **ORIGIN** - mandatory attribute, indicates an origin of the route - **ibgp**, **egp**, **incomplete**.
405 @line 13: **LOCAL_PREF** - indicates a degree of preference for external routes, higher value is preferred.
407 @line 16: **NEXT_HOP** - mandatory attribute, defines IP address of the router that should be used as the next hop to the destination.
411 There are much more attributes that may be carried along with the destination:
413 **BGP-4 Path Attributes**
415 * **MULTI_EXIT_DISC** (MED)
416 Optional attribute, to be used to discriminate among multiple exit/entry points on external links, lower number is preferred.
438 * **ATOMIC_AGGREGATE**
439 Indicates whether AS_SET was excluded from AS_PATH due to routes aggregation.
454 "atomic-aggregate": {
459 Optional attribute, contains AS number and IP address of a BGP speaker which performed routes aggregation.
468 <as-number>65000</as-number>
469 <network-address>192.0.2.2</network-address>
479 "network-address": "192.0.2.2"
484 Optional attribute, used to store optional attributes, unrecognized by a local BGP speaker.
492 <unrecognized-attributes>
493 <partial>true</partial>
494 <transitive>true</transitive>
496 <value>0101010101010101</value>
497 </unrecognized-attributes>
504 "unrecognized-attributes": {
508 "value": 0101010101010101
512 **Route Reflector Attributes**
515 Optional attribute, carries BGP Identifier of the originator of the route.
524 <originator>41.41.41.41</originator>
533 "originator": "41.41.41.41",
538 Optional attribute, contains a list of CLUSTER_ID values representing the path that the route has traversed.
547 <cluster>40.40.40.40</cluster>
556 "cluster": "41.41.41.41",
561 Optional attribute, may be used for policy routing.
570 <as-number>65000</as-number>
571 <semantics>30740</semantics>
585 **Extended Communities**
588 Identifies one or more routers that may receive a route.
596 <extended-communities>
597 <transitive>true</transitive>
599 <global-administrator>192.0.2.2</global-administrator>
600 <local-administrator>123</local-administrator>
602 </extended-communities>
603 <extended-communities>
604 <transitive>true</transitive>
605 <as-4-route-target-extended-community>
606 <as-4-specific-common>
607 <as-number>65000</as-number>
608 <local-administrator>123</local-administrator>
609 </as-4-specific-common>
610 </as-4-route-target-extended-community>
611 </extended-communities>
618 "extended-communities": [
621 "route-target-ipv4": {
622 "global-administrator": "192.0.2.2",
623 "local-administrator": 123
628 "as-4-route-target-extended-community": {
629 "as-4-specific-common": {
631 "local-administrator": 123
639 Identifies one or more routers that injected a route.
647 <extended-communities>
648 <transitive>true</transitive>
650 <global-administrator>192.0.2.2</global-administrator>
651 <local-administrator>123</local-administrator>
653 </extended-communities>
654 <extended-communities>
655 <transitive>true</transitive>
656 <as-4-route-origin-extended-community>
657 <as-4-specific-common>
658 <as-number>65000</as-number>
659 <local-administrator>123</local-administrator>
660 </as-4-origin-common>
661 </as-4-route-target-extended-community>
662 </extended-communities>
669 "extended-communities": [
672 "route-origin-ipv4": {
673 "global-administrator": "192.0.2.2",
674 "local-administrator": 123
679 "as-4-route-target-extended-community": {
680 "as-4-specific-common": {
682 "local-administrator": 123
690 Carries the cost to reach external neighbor.
698 <extended-communities>
699 <transitive>true</transitive>
700 <link-bandwidth-extended-community>
701 <bandwidth>BH9CQAA=</bandwidth>
702 </link-bandwidth-extended-community>
703 </extended-communities>
710 "extended-communities": {
712 "link-bandwidth-extended-community": {
713 "bandwidth": "BH9CQAA="
719 Optional attribute, carries accumulated IGP metric.
745 .. note:: When the remote peer disconnects, it disappear from operational state of local speaker instance and advertised routes are removed too.
747 External peering configuration
748 ''''''''''''''''''''''''''''''
749 An example above provided configuration for internal peering only.
750 Following configuration sample is intended for external peering:
752 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
760 **Content-Type:** ``application/xml``
768 <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
769 <neighbor-address>192.0.2.3</neighbor-address>
771 <peer-type>EXTERNAL</peer-type>
772 <peer-as>64999</peer-as>
776 @line 5: AS number of the remote peer.
780 **Content-Type:** ``application/json``
791 "neighbor-address": "192.0.2.3",
794 "peer-type": "EXTERNAL"
800 @line 6: AS number of the remote peer.
805 .. figure:: ./images/local-as.png
806 :alt: BGP eBGP with Local AS setup.
808 The local-AS feature allows a router(eBGP) to appear to be a member of a second autonomous system (AS), in addition to its real AS.
810 In above figure, R3 is eBGP router with configured local-as of 62, and peer-as of 63.
812 In updates sent from R3 to R2, the AS_SEQUENCE in the AS_PATH attribute contains "62 63". And updates sent from R2 to R3, the AS_SEQUENCE in the AS_PATH attribute contains "62 65".
814 AS 62 will be prepended to updates that are sent to and received from R3.
816 Following configuration sample is intended for external peering with Local AS:
818 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
826 **Content-Type:** ``application/xml``
832 :emphasize-lines: 5,6
834 <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
835 <neighbor-address>192.0.2.3</neighbor-address>
837 <peer-type>EXTERNAL</peer-type>
838 <peer-as>63</peer-as>
839 <local-as>62</local-as>
843 @line 5: AS number of the remote peer.
845 @line 6: Local AS number of the remote peer.
849 **Content-Type:** ``application/json``
855 :emphasize-lines: 7,8
860 "neighbor-address": "192.0.2.3",
862 "peer-type": "EXTERNAL",
870 @line 7: AS number of the remote peer.
872 @line 8: Local AS number of the remote peer.
874 Route reflector configuration
875 '''''''''''''''''''''''''''''
876 The local BGP speaker can be configured with a specific *cluster ID*.
877 Following example adds the cluster ID to the existing speaker instance:
879 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/global/config``
887 **Content-Type:** ``application/xml``
896 <router-id>192.0.2.2</router-id>
898 <route-reflector-cluster-id>192.0.2.1</route-reflector-cluster-id>
901 @line 4: Route-reflector cluster id to use when local router is configured as a route reflector.
902 The *router-id* is used as a default value.
906 **Content-Type:** ``application/json``
915 "bgp-openconfig-extensions:config": {
916 "router-id": "192.0.2.2",
918 "route-reflector-cluster-id": "192.0.2.1"
922 @line 5: Route-reflector cluster id to use when local router is configured as a route reflector.
923 The *router-id* is used as a default value.
927 Following configuration sample is intended for route reflector client peering:
929 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
937 **Content-Type:** ``application/xml``
945 <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
946 <neighbor-address>192.0.2.4</neighbor-address>
948 <peer-type>INTERNAL</peer-type>
952 <route-reflector-client>true</route-reflector-client>
957 @line 8: Configure the neighbor as a route reflector client. Default value is *false*.
961 **Content-Type:** ``application/json``
972 "neighbor-address": "192.0.2.4",
974 "peer-type": "INTERNAL"
978 "route-reflector-client": true
985 @line 10: Configure the neighbor as a route reflector client. Default value is *false*.
987 Route reflector and Multiple Cluster IDs
988 ''''''''''''''''''''''''''''''''''''''''
990 An optional non-transitive attribute called CLUSTER_LIST is modified when a route reflector reflects a prefix.
991 For loop prevention the route reflector adds its own cluster ID to, and discards any update containing router's own cluster ID.
992 Using multiple cluster IDs allows updates to propagate to nodes that reside in a different cluster.
995 .. figure:: ./images/MultipleClustersIds.png
996 :alt: BGP RR Multiple Cluster IDs setup.
998 Following configuration sample is intended for route reflector client peering using specific cluster id:
1000 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
1002 **Method:** ``POST``
1008 **Content-Type:** ``application/xml``
1014 :emphasize-lines: 8,9
1016 <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
1017 <neighbor-address>192.0.2.4</neighbor-address>
1019 <peer-type>INTERNAL</peer-type>
1023 <route-reflector-client>true</route-reflector-client>
1024 <route-reflector-cluster-id>192.0.2.4</route-reflector-cluster-id>
1029 @line 8: Configure the neighbor as a route reflector client. Default value is *false*.
1031 @line 9: Route-reflector cluster id to use for this specific neighbor when local router is configured as a route reflector.
1035 **Content-Type:** ``application/json``
1039 .. code-block:: json
1041 :emphasize-lines: 10,11
1046 "neighbor-address": "192.0.2.4",
1048 "peer-type": "INTERNAL"
1050 "route-reflector": {
1052 "route-reflector-client": true,
1053 "route-reflector-cluster-id":"192.0.2.4"
1060 @line 10: Configure the neighbor as a route reflector client. Default value is *false*.
1062 @line 11: Route-reflector cluster id to use for this specific neighbor when local router is configured as a route reflector.
1064 MD5 authentication configuration
1065 ''''''''''''''''''''''''''''''''
1066 The OpenDaylight BGP implementation is supporting TCP MD5 for authentication.
1067 Sample configuration below shows how to set authentication password for a peer:
1069 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
1071 **Method:** ``POST``
1077 **Content-Type:** ``application/xml``
1085 <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
1086 <neighbor-address>192.0.2.5</neighbor-address>
1088 <auth-password>topsecret</auth-password>
1092 @line 4: Configures an MD5 authentication password for use with neighboring devices.
1096 **Content-Type:** ``application/json``
1100 .. code-block:: json
1107 "neighbor-address": "192.0.2.5",
1109 "auth-password": "topsecret"
1115 @line 6: Configures an MD5 authentication password for use with neighboring devices.
1120 Allows the creation of a peer group configuration that applies to all peers configured as part of the group.
1122 A sample peer group configuration follows:
1124 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/peer-groups``
1126 **Method:** ``POST``
1132 **Content-Type:** ``application/xml``
1140 <peer-group xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
1141 <peer-group-name>internal-neighbor</peer-group-name>
1143 <peer-type>INTERNAL</peer-type>
1144 <peer-as>64496</peer-as>
1148 <remote-port>179</remote-port>
1149 <passive-mode>true</passive-mode>
1154 <hold-time>180</hold-time>
1155 <connect-retry>10</connect-retry>
1160 <route-reflector-client>false</route-reflector-client>
1165 <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
1166 <!--Advertise N Paths
1167 <receive>true</receive>
1168 <send-max>0</send-max>-->
1171 <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-UNICAST</afi-safi-name>
1174 <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-LABELLED-UNICAST</afi-safi-name>
1177 <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-LABELLED-UNICAST</afi-safi-name>
1180 <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L3VPN-IPV4-UNICAST</afi-safi-name>
1183 <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L3VPN-IPV6-UNICAST</afi-safi-name>
1186 <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L2VPN-EVPN</afi-safi-name>
1189 <afi-safi-name>LINKSTATE</afi-safi-name>
1192 <afi-safi-name>IPV4-FLOW</afi-safi-name>
1195 <afi-safi-name>IPV6-FLOW</afi-safi-name>
1198 <afi-safi-name>IPV4-L3VPN-FLOW</afi-safi-name>
1201 <afi-safi-name>IPV6-L3VPN-FLOW</afi-safi-name>
1206 @line 2: Peer Group Identifier.
1210 **Content-Type:** ``application/json``
1214 .. code-block:: json
1221 "peer-group-name": "internal-neighbor",
1224 "peer-type": "INTERNAL"
1229 "passive-mode": true
1238 "route-reflector": {
1240 "route-reflector-client": false
1246 "afi-safi-name": "openconfig-bgp-types:L2VPN-EVPN"
1249 "afi-safi-name": "openconfig-bgp-types:L3VPN-IPV6-UNICAST"
1252 "afi-safi-name": "bgp-openconfig-extensions:IPV6-FLOW"
1255 "afi-safi-name": "openconfig-bgp-types:IPV4-LABELLED-UNICAST"
1258 "afi-safi-name": "openconfig-bgp-types:L3VPN-IPV4-UNICAST"
1261 "afi-safi-name": "openconfig-bgp-types:IPV6-LABELLED-UNICAST"
1264 "afi-safi-name": "bgp-openconfig-extensions:LINKSTATE"
1267 "afi-safi-name": "openconfig-bgp-types:IPV6-UNICAST"
1270 "afi-safi-name": "bgp-openconfig-extensions:IPV4-L3VPN-FLOW"
1273 "afi-safi-name": "bgp-openconfig-extensions:IPV6-L3VPN-FLOW"
1276 "afi-safi-name": "openconfig-bgp-types:IPV4-UNICAST"
1279 "afi-safi-name": "bgp-openconfig-extensions:IPV4-FLOW"
1287 @line 4: Peer Group Identifier.
1291 A sample basic neighbor configuration using a peer group follows:
1293 **URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
1295 **Method:** ``POST``
1301 **Content-Type:** ``application/xml``
1309 <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
1310 <neighbor-address>192.0.2.1</neighbor-address>
1312 <peer-group>/bgp/neighbors/neighbor/bgp/peer-groups/peer-group[peer-group-name="internal-neighbor"]</peer-group>
1316 @line 4: Peer group identifier.
1320 **Content-Type:** ``application/json``
1324 .. code-block:: json
1331 "neighbor-address": "192.0.2.1",
1333 "peer-group": "/bgp/neighbors/neighbor/bgp/peer-groups/peer-group[peer-group-name=\"internal-neighbor\"]"
1339 @line 6: Peer group identifier.
1341 .. note:: Existing neighbor configuration can be reconfigured (change configuration parameters) anytime.
1342 As a result, established connection is dropped, peer instance is recreated with a new configuration settings and connection re-established.
1344 .. note:: The BGP configuration is persisted on OpendDaylight shutdown and restored after the re-start.