ONOS - setting, configuration, installation, and test

  • View
    577

  • Download
    1

Embed Size (px)

Text of ONOS - setting, configuration, installation, and test

  • ONOS SDN Controller SDN

    Mobile Convergence Lab, Computer Engineering, Kyung Hee University

    Sangyun Han

    Email : sangyun0628@khu.ac.kr

    SDN/NFV , ,

    [ONOS , ]

  • Setting

    Mobile Convergence Laboratory 2

    A Table of Contents

    Install

    Test

    ,

    SW

    ,

    SDN

    Q&A

  • Prerequisites

    Ubuntu 14.04 LTS 64bits

    2GB or more RAM

    2 or more processors

    8GB or more storage

    Java 8 JDK

    Apache Maven(3.3.9 and later)

    Apache Karaf(3.0.5 and later)

    Git

    Mobile Convergence Laboratory 3

  • VM instance

    Ubuntu 14.04 LTS

    2GB memory

    12GB hard disk(dynamic allocation)

    eth0 NAT / eth1 host-only

    username : sdn password : mclab

    Mobile Convergence Laboratory 4

  • Setting1. Installing VM

    2. Creating VM instance

    3. Configuring network option

    Mobile Convergence Laboratory 5

  • Virtual Box

    Virtual Box https://www.virtualbox.org/wiki/Downloads

    Ubuntu www.ubuntu.com/download/desktop

    Mobile Convergence Laboratory 6

  • Set VM (1/2)

    Mobile Convergence Laboratory 7

    Ubuntu

  • Set VM (2/2)

    8GB Ubuntu OS +

    Mobile Convergence Laboratory 8

  • Install Ubuntu (1/2)

    Mobile Convergence Laboratory 9

  • Install Ubuntu (2/2)

    username : sdn //

    Mobile Convergence Laboratory 10

  • VM Network Setting

    1 NAT For connecting internet

    2 For communicating ONOS cluster member

    11

  • Structure of Machines

    ,

    Mobile Convergence Laboratory 12

    Internet

    Physical machine

    Virtual machine Virtual machine Virtual machine

    Instance 1 Instance 2 Instance 3

    Eth0 Eth1 Eth0 Eth1 Eth0 Eth1

    Host-Only Network

  • Structure of Machines

    ,

    Mobile Convergence Laboratory 13

    Internet

    Physical machine

    Virtual machine Virtual machine Virtual machine

    Instance 1 Instance 2 Instance 3

    Eth0 Eth1 Eth0 Eth1 Eth0 Eth1

    Host-Only Network

    Instance Duplication

  • ONOS - InstallSingle Instance setting1. Getting ONOS

    2. Installing ONOS

    3. Start ONOS

    Mobile Convergence Laboratory 14https://wiki.onosproject.org/display/ONOS/Installing+and+Running+ONOS

  • 1. Install Java 8

    $ sudo apt-get install software-properties-common -y

    $ sudo add-apt-repository ppa:webupd8team/java -y

    $ sudo apt-get update

    $ sudo apt-get install oracle-java8-installer oracle-java8-set-default

    Mobile Convergence Laboratory 15

    Single Instance Setting (1/10)

  • 1. Install Java 8

    Mobile Convergence Laboratory 16

    Single Instance Setting (1/10)

    Java8

  • 2. Configure Java Path

    on Ubuntu

    $ env | grep JAVA_HOMEJAVA_HOME=/usr/lib/jvm/java-8-oracle

    $ export JAVA_HOME=/usr/lib/jvm/java-8-oracle

    Mobile Convergence Laboratory 17

    Single Instance Setting (2/10)

  • 3. Install Git

    $ sudo apt-get install git-core

    $ git --version

    Mobile Convergence Laboratory 18

    Single Instance Setting (3/10)

  • 4. Set Maven

    $ cd; mkdir Downloads Applications

    $ cd Downloads

    $ wget http://archive.apache.org/dist/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz

    $ tar -zxvf apache-maven-3.3.9-bin.tar.gz -C ../Applications/

    Mobile Convergence Laboratory 19

    Single Instance Setting (4/10)

  • 4. Set Maven

    $ cd; mkdir Downloads Applications

    $ cd Downloads

    $ wget http://archive.apache.org/dist/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz

    $ tar -zxvf apache-maven-3.3.9-bin.tar.gz -C ../Applications/

    Mobile Convergence Laboratory 20

    Single Instance Setting (4/10)

    !static path

  • 5. Set Karaf

    $ cd Downloads

    $ wget http://archive.apache.org/dist/karaf/3.0.5/apache-karaf-3.0.5.tar.gz

    $ tar -zxvf apache-karaf-3.0.5.tar.gz -C ../Applications/

    Mobile Convergence Laboratory 21

    Single Instance Setting (5/10)

  • 6. Clone ONOS

    $ cd ~/$ git clone https://gerrit.onosproject.org/onos/

    $ cd onos

    if> getting specific ONOS version$ git checkout onos-1.5

    Mobile Convergence Laboratory 22

    Single Instance Setting (6/10)

  • 7. Configure ONOS Path

    $ export ONOS_ROOT=~/onos

    $ source $ONOS_ROOT/tools/dev/bash_profile

    Mobile Convergence Laboratory 23

    Single Instance Setting (7/10)

    # add bashsudo vi /etc/bash.bashrcexport ONOS_ROOT=~/onossource $ONOS_ROOT/tools/dev/bash_profile

  • 8. Build ONOS

    $ cd ~/onos

    $ mvn clean install

    Mobile Convergence Laboratory 24

    Single Instance Setting (8/10)

  • 9. Start ONOS CLI

    $ ok clean

    Mobile Convergence Laboratory 25

    Single Instance Setting (9/10)

  • 10. Start ONOS GUI

    start ONOS (ONOS CLI)

    In web browser

    http://localhost:8181/onos/ui/login.html

    Default ID: karaf / PW: karaf

    Mobile Convergence Laboratory 26

    Single Instance Setting (10/10)

  • Mobile Convergence Laboratory 27

  • Mobile Convergence Laboratory 28

  • Activate ONOS app

    onos> app activate onos> app deactivate

    Mobile Convergence Laboratory 29

  • Test1. mininet

    2. Open vSwitch

    Mobile Convergence Laboratory 30

  • Mininet

    Open source , Linux kernel host, switch, router node Linux sw

    wireshark, tcpdump, web server, etc

    OpenFlow Python API custom topology

    Mobile Convergence Laboratory 31

    1. mininet (1/6)

  • mininet

    Ubuntu package $ apt-get install mininet $ sudo mn

    Source build $ git clone git://github.com/mininet/mininet.git $ ./mininet/util/install.sh -nfw $ sudo mn

    Mobile Convergence Laboratory 32

    1. mininet (2/6)

  • ONOS

    mininet tree // OpenFlow 1.0 , 6633 , ONOS OpenFlow 1.0 1.3 $ sudo mn -- [topology][,depth=][,fanout=] $ sudo mn --topo tree,2,3 --controller=remote,ip=127.0.0.1,port=6633

    Mobile Convergence Laboratory 33

    1. mininet (3/6)

    Python mininet

  • ping test & host discovery

    mininet> pingall

    Mobile Convergence Laboratory 34

    SDN controlle pingall unreachable ( )

    1. mininet (4/6)

  • ping test & host discovery

    Mobile Convergence Laboratory 35

    1. mininet (5/6)

  • mininet tool

    xterm node terminal xterm

    ifconfig ifconfig

    ping ping

    net node

    Mobile Convergence Laboratory 36

    1. mininet (6/6)

  • Open vSwitch

    PC/Server/RaspberryPi OpenFlow

    Mobile Convergence Laboratory 37

  • Open vSwitch

    Mobile Convergence Laboratory 38

    Pi Stack Switch https://github.com/MobileConvergenceLab/pi-switch Raspberry Pi

  • Mobile Convergence Laboratory 39

  • Mobile Convergence Laboratory 40

    Pi only SDN (1/3)

    Raspberry Pi

  • Mobile Convergence Laboratory 41

    Pi only SDN (2/3)

    ONOS controller

    Pi Stack Switch(SDN Switch)

  • Mobile Convergence Laboratory 42

    Pi only SDN (3/3)

    Raspberry Pi Screen running ONOS

  • Mobile Convergence Laboratory 43

Recommended

View more >