Ofm+odl+mininet Environment Construction

Source: Internet
Author: User
Tags switches

SDN Vendor Genre ODL Environment Building
Env:ofm+odl+mininet after processing the detached components [ODL OFM mininet Separate installation], I want to encapsulate a single virtual machine ODL environment, in order to deploy an SDN environment quickly to do simple development and test use. ######################################################################## #Date: 2018-03-08 author:burlyluo# #Mail: [email protected] version:v1.0 ########################### ############################################# #OFM: Https://github.com/CiscoDevNet/OpenDaylight-Openflow-AppODL: https://www.opendaylight.org/Mininet:http://mininet.org/VirtualBox:http://sw.bos.baidu.com/sw-search-sp/ software/6bda11b7d3256/ Introduction to Virtualbox-5.1.30.18389-win.exe use:------------------------------------------------------------------------------------- ------------------Sdn.ova integrates SDN tools on a single host, including tools such as Ofm,odl,mininet. The platform host uses Ubuntu 14.04 Desktop Edition, in which the network uses bridge mode, the author environment is 192.168.35.3 address [environment for 192.168.35.0/24], in the actual use can be modified to the corresponding network environment address. CPU I test the use of 4 core, of course, in the actual use can be changed to 2, memory of the author to 4096M, in the actual environment can make the corresponding changes, 2048M is OK. Download the appropriate package: Link: Https://pan.baidu.com/s/1klz_FBIK_L7wYBvUcKcqJg Password: 5ppf1. After extracting the Sdn.ova package, import it into the VirtualBox virtual machine. The initial information can be changed in the import, including the name, Cpu,memory can make the corresponding changes. When you're done modifying, click Import. 2. After the import is complete, open the desktop, username/password: hive/hive. After entering the desktop, open Terminal,ifconfig can see the corresponding 192.168.35.3, according to their own environment, to change the address in your environment. Edit file: Nano/etc/network/interface3. The steps to start the ODL module are:[Email protected]:~$ sudo-i[sudo] password for hive://Password: hive[email protected]:~# CD Distribution-karaf-0.3.4-lithi Um-sr4/bin/[email protected]:~/distribution-karaf-0.3.4-lithium-sr4/bin#./karaf Java HotSpot (TM) 64-Bit Server VM warning:ignoring option maxpermsize=512m; Support is removed in 8.0 _ _______ ________ .__ .__ .__ __ \_____ \ ______ ____ ____ \ ______ \ _____ ___.__.| | |__| ____ | |___/ |_ / | \\____ \_/ __ \ / \ | | \\__ \< | || | | |/ ___\| | \ __\ / | \ |_>> ___/| | \| ` \/ __ \\___ || |_| //_/> Y \ | \_______/__/\___ >___| /_______ (____ / ____|| ____/__\___ /|___| /__| \/|__| \/ \/ \/ \/\/ /_____/ \/ Hit '<Tab>' for a list of available Commandsand ' [cmd]--help ' for help on a specific command. Hit '<ctrl-d>' or type ' system:shutdown ' or ' logout ' to shutdown opendaylight. [Email protected]> #在firefox中输入URL即可进入ODL GUI #用户名/password Admin/adminhttp://odl_ address: 8181/index.htmlhttp:// 192.168.35.3:8181/index.html
Odl effect:

4. Start the Mininet modulesudo mn--topo tree,3--controller ' Remote,ip=odl address, port=6653 '--switch ovsk,protocols=openflow13[Email protected]:~# sudo mn--topo tree,3--controller ' remote,ip=192.168.35.3,port=6653 '--switch ovsk,protocols= openflow13*** Creating network*** Adding controller*** Adding hosts:h1 H2 H3 h4 h5 h6 H7 H8 * * Adding switches:s1 s2 S3 S  4 S5 S6 S7 * * * Adding Links: (S1, S2) (S1, S5) (S2, S3) (S2, S4) (S3, H1) (S3, H2) (S4, H3) (S4, H4) (S5, S6), S5, S7 h5) (S6, H6) (S7, H7) (S7, H8) * * Configuring HOSTSH1 H2 H3 H4 h5 h6 H7 H8 * * * Starting CONTROLLERC0 * * Starting 7 Swit CHESS1 S2 S3 S4 S5 S6 S7 ... * * * starting cli:mininet> Click Odl in the Reload GUI to discover the 7 OpenFlow switches we just started. After executing pingall can be found in the ODL GUI reload hostmininet> pingall*** ping:testing Ping reachabilityh1, H2 H3 h4 h5 h6 H7 H8 H 2-H1 H3 h4 h5 h6 H7 H8 H3-H1 H2 H4 h5 h6 H7 H8 H4-H1 H2 H3 h5 h6 H7 H8 h5 H1 H2 H3 H4 -H1 H2 H3 H4 H5 H7 H8 H7-H1 H2 H3 h4 h5 h6 h8 H8-H1 H2 H3 h4 h5 h6 H7 * * results:0% dropped (56/56 rece ived) mininet>
mininet Effect:
5. Start OFM[email protected]:~$ Sudo-i[sudo] Password for hive: [email protected]:~# CD opendaylight-openflow-app/[ email protected]:~/opendaylight-openflow-app# lltotal 40drwxr-xr-x 5 root root 4096 March 8 11:53./drwx------Roo T root 4096 March 8 12:10.. /drwxr-xr-x 8 root root 4096 March 7 12:26. git/-rw-r--r--1 root root 420 March 7 12:26 gruntfile.js-rw-r--r--1 root R Oot 587 March 7 12:26 licensedrwxr-xr-x 4 root root 4096 March 7 12:26 node_modules/drwxr-xr-x 5 root root 4096 March 7 12 : ofm/-rw-r--r--1 root root 132 March 7 12:26 package.json-rw-r--r--1 root root 7219 March 7 12:26 readme.md--------- -------------------------------------------here we're going to change the environment factor: modification Principle: Update BASEURL to match SDN Controller IP address or Leave as localhost if supported on local machine need to modify the position I made the mark [email protected]:~$ Sudo-i[sudo] Password for hive: [em ail protected]:~# CD opendaylight-openflow-app/ofm/src/common/config/[email protected]:~/ opendaylight-openflow-app/ofm/src/common/config# lsenv.module.js[email protected]:~/opendaylight-openflow-app/ofm/src/common/config# Less Env.module.js define ([' ANGULARAMD '), function (NG) {' Use strict '; var config = angular.module (' config ', []). Constant (' ENV ', {baseURL: "http://192.168.35.3:",//To be amended here ODL address//Adsalport: "8181", Mdsalport: "8181", Ofmport: "8181", Configenv: "Env_dev ", Odlusername: ' admin ', Odluserpassword: ' admin ', getbaseurl:function (saltype) { if (saltype!==undefined) {var urlprefix = ""; if (this.configenv=== "Env_dev") {urlprefix = This.baseurl; }else{URLPrefix = window.location.protocol+ "//" +window.location.hostname+ ":"; } if (saltype=== "Ad_sal") {return urlprefix + this.adsalport; }else if (saltype=== "Md_sal") { return urlprefix + this.mdsalport; }else if (saltype=== "CONTROLLER") {return urlprefix + this.ofmport; }}//default behavior return "";//Aaaurl: "/AAA",// AppUrl: "/app",////controllerurl: "/controller",//Controllerurl: "",//Con Figenv: "Env_dev",//odlusername: ' admin ',//Odluserpassword: ' admin ',////g Etbaseurl:function (servicetype) {//if (servicetype!==undefined) {//var urlpref IX = Window.location.protocol + "//" + window.location.hostname;//var removehttp = "://";// var urlparts = Urlprefix.split (removehttp);//var host = urlparts[1];// var baseUrl = Window.location.protocol + "//" + Host + ': 8181 ';//// if (servicetype = = = null) {//return baseurl;//}else if (servicetype = = = "AAA") {//return BASEURL + this.aaaurl;//}else if (servicetype = = = "APP") {//return BASEURL + this.appurl;//}else if (servicetype = = = "A UTH ") {//return BASEURL +"/controller-auth ";//}else if (servicetype = = = "CONTROLLER") {//return BASEURL + this.controllerurl;//}else if (SE Rvicetype = = = "LOGS") {//return BASEURL + "/log-aggregator";//}else if (ServiceType = = = "METRICS") {//return BASEURL + "/metrics-aggregator/";//}else if (servicetype = = = "Pathman") {//return BASEURL + "/pathman";//}else {// Return baseurl;//}//}//return Window.locati On.protocol + "//" + Window.location.hostname + ': 8181 '; } }); return config;}); [email protected]:~/opendaylight-openflow-app/ofm/src/common/config# This starts the OFM----------------------------------------------------[email protected]:~/opendaylight-openflow-app# Gruntrunning "Connect:def" (Connect) taskwaiting forever ... Started Connect Web server on http://localhost:9000 after seeing this interface, we access it in the browser: Http://ODL_ address: 9000http://192.168.35.3:9000
-------------------------------------------------------------------------------------------------------
OFM Effect:

Ofm+odl+mininet Environment Construction

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.