ONOS - setting, configuration, installation, and test

  • Published on
    21-Jan-2017

  • View
    577

  • Download
    1

Embed Size (px)

Transcript

<ul><li><p>ONOS SDN Controller SDN </p><p>Mobile Convergence Lab, Computer Engineering, Kyung Hee University</p><p>Sangyun Han</p><p>Email : sangyun0628@khu.ac.kr</p><p>SDN/NFV , , </p><p>[ONOS , ]</p></li><li><p>Setting</p><p>Mobile Convergence Laboratory 2</p><p>A Table of Contents</p><p>Install</p><p>Test</p><p> , </p><p>SW </p><p> , </p><p> SDN </p><p>Q&amp;A</p></li><li><p>Prerequisites</p><p> Ubuntu 14.04 LTS 64bits</p><p> 2GB or more RAM</p><p> 2 or more processors</p><p> 8GB or more storage</p><p> Java 8 JDK</p><p> Apache Maven(3.3.9 and later)</p><p> Apache Karaf(3.0.5 and later)</p><p> Git</p><p>Mobile Convergence Laboratory 3</p></li><li><p> VM instance</p><p> Ubuntu 14.04 LTS</p><p> 2GB memory</p><p> 12GB hard disk(dynamic allocation)</p><p> eth0 NAT / eth1 host-only</p><p> username : sdn password : mclab</p><p>Mobile Convergence Laboratory 4</p></li><li><p>Setting1. Installing VM</p><p>2. Creating VM instance</p><p>3. Configuring network option</p><p>Mobile Convergence Laboratory 5</p></li><li><p>Virtual Box</p><p> Virtual Box https://www.virtualbox.org/wiki/Downloads</p><p> Ubuntu www.ubuntu.com/download/desktop</p><p>Mobile Convergence Laboratory 6</p></li><li><p>Set VM (1/2)</p><p>Mobile Convergence Laboratory 7</p><p> Ubuntu </p></li><li><p>Set VM (2/2)</p><p> 8GB Ubuntu OS + </p><p>Mobile Convergence Laboratory 8</p></li><li><p>Install Ubuntu (1/2)</p><p>Mobile Convergence Laboratory 9</p></li><li><p>Install Ubuntu (2/2)</p><p> username : sdn // </p><p>Mobile Convergence Laboratory 10</p></li><li><p>VM Network Setting</p><p> 1 NAT For connecting internet</p><p> 2 For communicating ONOS cluster member</p><p>11</p></li><li><p>Structure of Machines</p><p> , </p><p>Mobile Convergence Laboratory 12</p><p>Internet</p><p>Physical machine</p><p>Virtual machine Virtual machine Virtual machine</p><p>Instance 1 Instance 2 Instance 3</p><p>Eth0 Eth1 Eth0 Eth1 Eth0 Eth1</p><p>Host-Only Network</p></li><li><p>Structure of Machines</p><p> , </p><p>Mobile Convergence Laboratory 13</p><p>Internet</p><p>Physical machine</p><p>Virtual machine Virtual machine Virtual machine</p><p>Instance 1 Instance 2 Instance 3</p><p>Eth0 Eth1 Eth0 Eth1 Eth0 Eth1</p><p>Host-Only Network</p><p> Instance Duplication</p></li><li><p>ONOS - InstallSingle Instance setting1. Getting ONOS</p><p>2. Installing ONOS</p><p>3. Start ONOS</p><p>Mobile Convergence Laboratory 14https://wiki.onosproject.org/display/ONOS/Installing+and+Running+ONOS</p></li><li><p>1. Install Java 8</p><p>$ sudo apt-get install software-properties-common -y</p><p>$ sudo add-apt-repository ppa:webupd8team/java -y</p><p>$ sudo apt-get update</p><p>$ sudo apt-get install oracle-java8-installer oracle-java8-set-default</p><p>Mobile Convergence Laboratory 15</p><p>Single Instance Setting (1/10)</p></li><li><p>1. Install Java 8</p><p>Mobile Convergence Laboratory 16</p><p>Single Instance Setting (1/10)</p><p> Java8 </p></li><li><p>2. Configure Java Path </p><p> on Ubuntu</p><p>$ env | grep JAVA_HOMEJAVA_HOME=/usr/lib/jvm/java-8-oracle</p><p>$ export JAVA_HOME=/usr/lib/jvm/java-8-oracle</p><p>Mobile Convergence Laboratory 17</p><p>Single Instance Setting (2/10)</p></li><li><p>3. Install Git</p><p>$ sudo apt-get install git-core</p><p>$ git --version</p><p>Mobile Convergence Laboratory 18</p><p>Single Instance Setting (3/10)</p></li><li><p>4. Set Maven</p><p>$ cd; mkdir Downloads Applications</p><p>$ cd Downloads</p><p>$ wget http://archive.apache.org/dist/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz</p><p>$ tar -zxvf apache-maven-3.3.9-bin.tar.gz -C ../Applications/ </p><p>Mobile Convergence Laboratory 19</p><p>Single Instance Setting (4/10)</p></li><li><p>4. Set Maven</p><p>$ cd; mkdir Downloads Applications</p><p>$ cd Downloads</p><p>$ wget http://archive.apache.org/dist/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz</p><p>$ tar -zxvf apache-maven-3.3.9-bin.tar.gz -C ../Applications/ </p><p>Mobile Convergence Laboratory 20</p><p>Single Instance Setting (4/10)</p><p>!static path</p></li><li><p>5. Set Karaf</p><p>$ cd Downloads</p><p>$ wget http://archive.apache.org/dist/karaf/3.0.5/apache-karaf-3.0.5.tar.gz</p><p>$ tar -zxvf apache-karaf-3.0.5.tar.gz -C ../Applications/</p><p>Mobile Convergence Laboratory 21</p><p>Single Instance Setting (5/10)</p></li><li><p>6. Clone ONOS</p><p>$ cd ~/$ git clone https://gerrit.onosproject.org/onos/ </p><p>$ cd onos</p><p>if&gt; getting specific ONOS version$ git checkout onos-1.5</p><p>Mobile Convergence Laboratory 22</p><p>Single Instance Setting (6/10)</p></li><li><p>7. Configure ONOS Path</p><p>$ export ONOS_ROOT=~/onos</p><p>$ source $ONOS_ROOT/tools/dev/bash_profile</p><p>Mobile Convergence Laboratory 23</p><p>Single Instance Setting (7/10)</p><p># add bashsudo vi /etc/bash.bashrcexport ONOS_ROOT=~/onossource $ONOS_ROOT/tools/dev/bash_profile</p></li><li><p>8. Build ONOS </p><p>$ cd ~/onos</p><p>$ mvn clean install</p><p>Mobile Convergence Laboratory 24</p><p>Single Instance Setting (8/10)</p></li><li><p>9. Start ONOS CLI </p><p>$ ok clean</p><p>Mobile Convergence Laboratory 25</p><p>Single Instance Setting (9/10)</p></li><li><p>10. Start ONOS GUI</p><p> start ONOS (ONOS CLI)</p><p> In web browser</p><p> http://localhost:8181/onos/ui/login.html</p><p>Default ID: karaf / PW: karaf</p><p>Mobile Convergence Laboratory 26</p><p>Single Instance Setting (10/10)</p></li><li><p>Mobile Convergence Laboratory 27</p></li><li><p>Mobile Convergence Laboratory 28</p></li><li><p>Activate ONOS app</p><p>onos&gt; app activate onos&gt; app deactivate </p><p>Mobile Convergence Laboratory 29</p></li><li><p>Test1. mininet </p><p>2. Open vSwitch </p><p>Mobile Convergence Laboratory 30</p></li><li><p>Mininet</p><p> Open source , Linux kernel host, switch, router node Linux sw </p><p> wireshark, tcpdump, web server, etc</p><p> OpenFlow Python API custom topology </p><p>Mobile Convergence Laboratory 31</p><p>1. mininet (1/6)</p></li><li><p>mininet </p><p> Ubuntu package $ apt-get install mininet $ sudo mn</p><p> Source build $ git clone git://github.com/mininet/mininet.git $ ./mininet/util/install.sh -nfw $ sudo mn</p><p>Mobile Convergence Laboratory 32</p><p>1. mininet (2/6)</p></li><li><p> ONOS </p><p> 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</p><p>Mobile Convergence Laboratory 33</p><p>1. mininet (3/6)</p><p>Python mininet </p></li><li><p>ping test &amp; host discovery</p><p>mininet&gt; pingall</p><p>Mobile Convergence Laboratory 34</p><p> SDN controlle pingall unreachable ( )</p><p>1. mininet (4/6)</p></li><li><p>ping test &amp; host discovery</p><p>Mobile Convergence Laboratory 35</p><p>1. mininet (5/6)</p></li><li><p>mininet tool</p><p> xterm node terminal xterm </p><p> ifconfig ifconfig</p><p> ping ping </p><p> net node </p><p>Mobile Convergence Laboratory 36</p><p>1. mininet (6/6)</p></li><li><p>Open vSwitch </p><p> PC/Server/RaspberryPi OpenFlow </p><p>Mobile Convergence Laboratory 37</p></li><li><p>Open vSwitch </p><p>Mobile Convergence Laboratory 38</p><p> Pi Stack Switch https://github.com/MobileConvergenceLab/pi-switch Raspberry Pi </p></li><li><p>Mobile Convergence Laboratory 39</p></li><li><p>Mobile Convergence Laboratory 40</p><p>Pi only SDN (1/3)</p><p>Raspberry Pi</p></li><li><p>Mobile Convergence Laboratory 41</p><p>Pi only SDN (2/3)</p><p>ONOS controller</p><p>Pi Stack Switch(SDN Switch)</p></li><li><p>Mobile Convergence Laboratory 42</p><p>Pi only SDN (3/3)</p><p>Raspberry Pi Screen running ONOS</p></li><li><p>Mobile Convergence Laboratory 43</p></li></ul>