BGPCEP: BMP docs 64/27764/4 readthedocs
authorMilos Fabian <milfabia@cisco.com>
Thu, 1 Oct 2015 19:06:57 +0000 (21:06 +0200)
committerColin Dixon <colin@colindixon.com>
Fri, 1 Apr 2016 20:58:32 +0000 (16:58 -0400)
odl-bgpcep-bmp feature user and dev guide

Change-Id: I3c32b9be92d0aa94ecf6c768c5bb23cb33f73eb3
Signed-off-by: Milos Fabian <milfabia@cisco.com>
manuals/developer-guide/src/main/asciidoc/bgpcep/odl-bgpcep-bmp-dev.adoc [new file with mode: 0644]
manuals/developer-guide/src/main/asciidoc/bk-developers-guide.adoc
manuals/user-guide/src/main/asciidoc/bgpcep/odl-bgpcep-bmp-user.adoc [new file with mode: 0644]
manuals/user-guide/src/main/asciidoc/bk-user-guide.adoc

diff --git a/manuals/developer-guide/src/main/asciidoc/bgpcep/odl-bgpcep-bmp-dev.adoc b/manuals/developer-guide/src/main/asciidoc/bgpcep/odl-bgpcep-bmp-dev.adoc
new file mode 100644 (file)
index 0000000..88d20e1
--- /dev/null
@@ -0,0 +1,149 @@
+== BGP Monitoring Protocol Developer Guide
+
+=== Overview
+This section provides an overview of *feature odl-bgpcep-bmp*. This
+feature will install everything needed for BMP (BGP Monitoring Protocol)
+including establishing the connection, processing messages, storing
+information about monitored routers, peers and their Adj-RIB-In
+(unprocessed routing information) and Post-Policy Adj-RIB-In
+and displaying data in BGP RIBs overview.
+The OpenDaylight BMP plugin plays the role of a monitoring station.
+
+=== Key APIs and Interfaces
+
+==== Session handling
+
+_32-bmp.xml_ defines only bmp-dispatcher the parser should be
+using (global-bmp-extensions).
+
+[source,xml]
+----
+ <module>
+  <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">prefix:bmp-dispatcher-impl</type>
+  <name>global-bmp-dispatcher</name>
+   <bmp-extensions>
+    <type xmlns:bmp-spi="urn:opendaylight:params:xml:ns:yang:controller:bmp:spi">bmp-spi:extensions</type>
+    <name>global-bmp-extensions</name>
+   </bmp-extensions>
+   <boss-group>
+    <type xmlns:netty="urn:opendaylight:params:xml:ns:yang:controller:netty">netty:netty-threadgroup</type>
+    <name>global-boss-group</name>
+   </boss-group>
+   <worker-group>
+    <type xmlns:netty="urn:opendaylight:params:xml:ns:yang:controller:netty">netty:netty-threadgroup</type>
+    <name>global-worker-group</name>
+  </worker-group>
+ </module>
+----
+
+For user configuration of BMP, check User Guide.
+
+==== Parser
+
+The base BMP parser includes messages and attributes from
+https://tools.ietf.org/html/draft-ietf-grow-bmp-15
+
+==== Registration
+
+All parsers and serializers need to be registered
+into _Extension provider_. This _Extension provider_ is configured in
+initial configuration of the parser (_32-bmp.xml_).
+
+[source,xml]
+----
+ <module>
+  <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:bmp:spi">prefix:bmp-extensions-impl</type>
+  <name>global-bmp-extensions</name>
+  <extension>
+   <type xmlns:bmp-spi="urn:opendaylight:params:xml:ns:yang:controller:bmp:spi">bmp-spi:extension</type>
+   <name>bmp-parser-base</name>
+  </extension>
+ </module>
+----
+
+* _bmp-parser-base_ - will register parsers and serializers
+implemented in bmp-impl module
+
+==== Parsing
+
+Parsing of BMP elements is mostly done equally to BGP. Some of the BMP messages includes wrapped
+BGP messages.
+
+==== BMP Monitoring Station
+
+The BMP application (Monitoring Station) serves as message processor incoming from monitored routers.
+The processed message is transformed and relevant information is stored. Route information is stored in a BGP
+RIB data structure.
+
+BMP data is displayed only through one URL that is accessible from the base BMP URL:
+
+_http://<controllerIP>:8181/restconf/operational/bmp-monitor:bmp-monitor_
+
+Each Monitor station will be displayed and it may contains multiple monitored routers and peers within:
+
+[source,xml]
+----
+<bmp-monitor xmlns="urn:opendaylight:params:xml:ns:yang:bmp-monitor">
+ <monitor>
+ <monitor-id>example-bmp-monitor</monitor-id>
+  <router>
+  <router-id>127.0.0.11</router-id>
+   <status>up</status>
+   <peer>
+    <peer-id>20.20.20.20</peer-id>
+    <as>72</as>
+    <type>global</type>
+    <peer-session>
+     <remote-port>5000</remote-port>
+     <timestamp-sec>5</timestamp-sec>
+     <status>up</status>
+     <local-address>10.10.10.10</local-address>
+     <local-port>220</local-port>
+    </peer-session>
+    <pre-policy-rib>
+     <tables>
+      <afi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:ipv4-address-family</afi>
+      <safi xmlns:x="urn:opendaylight:params:xml:ns:yang:bgp-types">x:unicast-subsequent-address-family</safi>
+      <ipv4-routes xmlns="urn:opendaylight:params:xml:ns:yang:bgp-inet">
+       <ipv4-route>
+        <prefix>10.10.10.0/24</prefix>
+         <attributes>
+          ...
+         </attributes>
+       </ipv4-route>
+      </ipv4-routes>
+      <attributes>
+       <uptodate>true</uptodate>
+      </attributes>
+     </tables>
+    </pre-policy-rib>
+    <address>10.10.10.10</address>
+    <post-policy-rib>
+     ...
+    </post-policy-rib>
+    <bgp-id>20.20.20.20</bgp-id>
+    <stats>
+     <timestamp-sec>5</timestamp-sec>
+     <invalidated-cluster-list-loop>53</invalidated-cluster-list-loop>
+     <duplicate-prefix-advertisements>16</duplicate-prefix-advertisements>
+     <loc-rib-routes>100</loc-rib-routes>
+     <duplicate-withdraws>11</duplicate-withdraws>
+     <invalidated-as-confed-loop>55</invalidated-as-confed-loop>
+     <adj-ribs-in-routes>10</adj-ribs-in-routes>
+     <invalidated-as-path-loop>66</invalidated-as-path-loop>
+     <invalidated-originator-id>70</invalidated-originator-id>
+     <rejected-prefixes>8</rejected-prefixes>
+    </stats>
+   </peer>
+   <name>name</name>
+   <description>description</description>
+   <info>some info;</info>
+  </router>
+ </monitor>
+</bmp-monitor>
+</source>
+----
+
+=== API Reference Documentation
+Javadocs are generated while creating mvn:site
+and they are located in target/ directory in each module.
index 13c350fc96de00b6e14ef32b08f30542e4107ff5..b3b3112ebb20187fc7d79848d55564a981ca3475 100644 (file)
@@ -58,6 +58,8 @@ include::armoury/odl-armoury-dev.adoc[ARMOURY]
 
 include::bgpcep/odl-bgpcep-bgp-all-dev.adoc[BGP]
 
+include::bgpcep/odl-bgpcep-bmp-dev.adoc[BGP]
+
 include::capwap/capwap-dev.adoc[CAPWAP]
 
 include::controller/controller.adoc[Controller]
diff --git a/manuals/user-guide/src/main/asciidoc/bgpcep/odl-bgpcep-bmp-user.adoc b/manuals/user-guide/src/main/asciidoc/bgpcep/odl-bgpcep-bmp-user.adoc
new file mode 100644 (file)
index 0000000..6290bf7
--- /dev/null
@@ -0,0 +1,135 @@
+== BGP Monitoring Protocol User Guide ==
+
+=== Overview ===
+
+The OpenDaylight Karaf distribution comes preconfigured with baseline BMP configuration.
+
+- *32-bmp.xml* (initial configuration for BMP messages handler service provider and BMP client/server dispatcher settings)
+- *42-bmp-example.xml* (sample initial configuration for the BMP Monitoring Station application)
+
+=== Configuring BMP ===
+
+==== Server Binding ====
+The default shipped configuration will start a BMP server on 0.0.0.0:12345.You can change this behavior in *42-bmp-example.xml*:
+
+[source,xml]
+----
+ <module>
+  <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">prefix:bmp-monitor-impl</type>
+  <name>example-bmp-monitor</name>
+  <!--<binding-address>0.0.0.0</binding-address>-->
+  <binding-port>12345</binding-port>
+  ...
+ </module>
+----
+
+- *binding-address* - adress on which BMP will be started and listen; to change value, uncomment then line first
+- *binding-port* - port on which the address will be started and listen
+
+Multiple instances of the BMP monitoring station (*bmp-monitor-impl* module) can be created. However, each instance must have a unique pair of *binding-address* and *binding-port*
+
+==== Active mode ====
+OpenDaylight's BMP might be configured to act as an active party of the connection (ODL BMP < = > Monitored router). To enable this functionality,
+configure monitored-router with mandatory parameters:
+
+* address (must be unique for each configured "monitored-router"),
+* port,
+* active.
+
+See following example from 42-bmp-example.xml: 
+
+[source,xml]
+----
+ <monitored-router>
+  <address>192.0.2.2</address>
+  <port>1234</port>
+  <active>true</active>
+ </monitored-router>
+----
+
+=== Configuration through RESTCONF ===
+
+==== Server Binding ====
+
+*URL:*
+_http://<controllerIP>:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/config:module/odl-bmp-impl-cfg:bmp-monitor-impl/example-bmp-monitor_
+
+*Content-Type:*
+application/xml
+
+*Method:*
+PUT
+
+*Body:*
+[source,xml]
+----
+<module xmlns="urn:opendaylight:params:xml:ns:yang:controller:config">
+  <name>example-bmp-monitor</name>
+  <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">x:bmp-monitor-impl</type>
+  <bmp-dispatcher xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type>bmp-dispatcher</type>
+    <name>global-bmp-dispatcher</name>
+  </bmp-dispatcher>
+  <codec-tree-factory xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding">x:binding-codec-tree-factory</type>
+    <name>runtime-mapping-singleton</name>
+  </codec-tree-factory>
+  <extensions xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:spi">x:extensions</type>
+    <name>global-rib-extensions</name>
+  </extensions>
+  <binding-address xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">0.0.0.0</binding-address>
+  <dom-data-provider xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:md:sal:dom">x:dom-async-data-broker</type>
+    <name>pingpong-broker</name>
+  </dom-data-provider>
+  <binding-port xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">12345</binding-port>
+</module>
+----
+
+* change values for *binding-address* and/or *binding-port*
+
+==== Active mode ====
+
+*URL:*
+_http://<controllerIP>:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/config:module/odl-bmp-impl-cfg:bmp-monitor-impl/example-bmp-monitor_
+
+*Content-Type:*
+application/xml
+
+*Method:*
+PUT
+
+*Body:*
+[source,xml]
+----
+<module xmlns="urn:opendaylight:params:xml:ns:yang:controller:config">
+  <name>example-bmp-monitor</name>
+  <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">x:bmp-monitor-impl</type>
+  <bmp-dispatcher xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type>bmp-dispatcher</type>
+    <name>global-bmp-dispatcher</name>
+  </bmp-dispatcher>
+  <codec-tree-factory xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding">x:binding-codec-tree-factory</type>
+    <name>runtime-mapping-singleton</name>
+  </codec-tree-factory>
+  <extensions xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:spi">x:extensions</type>
+    <name>global-rib-extensions</name>
+  </extensions>
+  <binding-address xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">0.0.0.0</binding-address>
+      <dom-data-provider xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:md:sal:dom">x:dom-async-data-broker</type>
+    <name>pingpong-broker</name>
+  </dom-data-provider>
+  <binding-port xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">12345</binding-port>
+  <monitored-router xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">
+    <address xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">127.0.0.1</address>
+    <port xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">1234</port>
+    <active xmlns="urn:opendaylight:params:xml:ns:yang:controller:bmp:impl">true</active>
+  </monitored-router>
+</module>
+----
+
+* change values for *address* and *port*
index f2355b6d38b4a0a96097f682e14770de87aac42d..4b657b9f35d334b9d6a6c43203444761dadeb9fa 100644 (file)
@@ -36,6 +36,8 @@ include::armoury/odl-armoury-user.adoc[ARMOURY]
 
 include::bgpcep/odl-bgpcep-bgp-all-user.adoc[BGP]
 
+include::bgpcep/odl-bgpcep-bmp-user.adoc[BMP]
+
 include::capwap/capwap-user.adoc[CAPWAP]
 
 include::didm/didm-user.adoc[]