Creating an Instance of SDN-R using docker-compose



Outdated, new version is here: SDN-R on docker-compose

For module tests and first integration test it is beneficial to create a "stand-alone" instance of ONAP SDN-R. Such version can  run on a single developer system. 

Prerequisites

Operating System:

$ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 20.04.1 LTS Release: 20.04 Codename: focal

It is assumed that any operation system which is supported by docker and docker-compose can be used.

The host systems must have internet connectivity.

The user must have sudo privileges. 

Basic Installation

For running ONAP SDN-R as "stand-alone" version docker and docker-compose must be installed.

Check the versions:

$ docker --version Docker version 19.03.8, build afacb8b7f0 $ docker-compose --version docker-compose version 1.27.2, build 18f557f

For IPv6 support a docker configuration by creating /etc/docker/daemon.json is required.

$ sudo -s $ cat <<EOT >> /etc/docker/daemon.json { "log-driver": "json-file", "log-opts": { "max-size": "10m", "max-file": "3" }, "ipv6": true, "fixed-cidr-v6": "2001:db8:1::/64" } EOT $ exit $ sudo systemctl restart docker

Docker compose configuration

A docker-compose.yaml file contains all the configuration required to run the different docker images, which are used to verify the different functions of ONAP SDN-R. 

The following file is used to configure and run

  • SDN-R Controller (ODL with SDN-R extensions

  • SDN-R data cache (ElasticSearch)

  • VES-Collector and DMaaP

  • O-RAN-SC Simulator as NetConf-Server and VES emitter



TBD

docker network create \
--ipv6 \
--driver=bridge \
--subnet=172.50.0.0/16 \
--subnet=2001:3984:3989::/64 \
--gateway=172.50.0.1 \
--gateway=2001:3984:3989::1 \
oam



Build and run single node SDN-R

Build and run container

  • Login to nexus repository (for first time) .. see here: Docker DevOps

  • Build

  • Use (1) to run container with name "sdnr" in detached mode without any port mapping or (2) to run with mapping to host:8181

  • With (1) do open UX Web GUI by using browser http://172.17.0.2:8181/index2.html (!) on host machine with user/password = admin/admin

    • Wait about 30 seconds that container is up and running

    • Verify with curl -v http://172.18.0.2:8181/index2.html that it is running. Correct ouput ends with lines: HTTP/1.1 301 Moved Permanently , < Location: odlux/index.html, < Content-Length: 0

    • docker ps should show a single running container

    • docker inspect sdnr gives IP adress to be used. In the example 172.17.0.2 

  • With start (2) you can open UX Web GUI by using browser http://HOST_IP:8181/index2.html from different machine with user/password = admin/admin

  • Login to docker container command line with name "sdnr"

  • Opendaylight home is under "/opt/opendaylight". Coul could cd $ODL_HOME

  • Leave CLI with exit

Stop and remove container



Build and run single node CENTENNIAL POC5

.. waiting for content