====== BGP-LS ====== BGP can only listen on port 179 on ONOS. It can't be changed at the time of writing. ===== Installation ===== feature:install onos-providers-bgp feature:install onos-apps-pcep-api app activate org.onosproject.pcep-api app activate org.onosproject.bgp ===== Check configuration ===== curl -u "onos:rocks" -X GET http://192.168.103.143:8181/onos/v1/configuration | python -m json.tool ===== Configure ONOS for BGP ===== { "apps":{ "org.onosproject.provider.bgp.cfg": { "bgpapp": { "routerId": "192.168.103.143", "localAs": 64513, "maxSession": 20, "lsCapability": true, "holdTime": 180, "largeAsCapability": true, "flowSpecCapability": "IPV4", "bgpPeer":[ {"peerIp": "192.168.103.144", "remoteAs": 64514, "connectMode":"active"}] } } } } * **routerId** Local IP address. * **localAs** Local AS number * **maxSession** Max number of session BGP ONOS can maintain. * **lsCapability** BGP-LS capability * **holdTime** Hold Time * **largeAsCapability** 4-octet AS capability, true to talk with OpenDayLight which has the capability * **flowSpecCapability** flowspec capability * **bgpPeer** Remote BGP peer information * **peerIp** Remote BGP peer IP * **remoteAs** Remote BGP AS number * **connectMode** Session initiation, active or passive. In case of passive mode BGP is in listen mode. curl -u "onos:rocks" -X POST -H "Content-Type: application/json" -d @bgp-ls.json http://192.168.103.143:8181/onos/v1/network/configuration/ ===== Problems of config ===== * **Bad Peer AS**, You can't use iBGP for inter-AS communication * **Unsupported Capability**, if BGP capabilities of peers don't match, this error pops up. Check [2] ===== Sources ===== * [1] [[ https://wiki.onosproject.org/display/ONOS/BGP+protocol+with+Link-State+Distribution ]] * [2] [[ https://www.iana.org/assignments/capability-codes/capability-codes.xhtml ]]