ONOS安装

心不动则不痛 提交于 2019-12-04 17:56:28

本机安装教程(ubuntu)

https://wiki.onosproject.org/display/ONOS/Developer+Quick+Start

  1. 安装bazel: https://docs.bazel.build/versions/master/install-ubuntu.html

  2. 其他依赖:

    git
    zip
    curl
    unzip
    python # 2.7 required by some development scripts
    python3 # Required by Bazel
    bzip2 # Needed by legacy GUI build
  3. 安装onos

    git clone https://gerrit.onosproject.org/onos
    cd onos
    bazel build onos

    onos编译安装报错解决办法

    https://blog.csdn.net/daihanglai7622/article/details/88642998?tdsourcetag=s_pctim_aiomsg

  4. 运行onos

    bazel run onos-local -- clean debug
    # 'clean' to delete all previous running status
    # 'debug' to enable remote debugging

    进入onos cli:

    tools/test/bin/onos localhost

    通过 ONOS CLI 激活应用程序 openflow和响应转发:

    onos> app activate org.onosproject.openflow
    onos> app activate org.onosproject.fwd

    打开onos web界面:

    tools /test/bin/onos-gui localhost

    或者访问 http://localhost:8181/onos/ui

    onos/rocks

  5. 运行mininet,连接onos

    sudo mn --controller remote,ip=<ONOS IP address> --topo torus,3,3

    ONOS IP address替换成运行onos机器的ip地址,如果是在本机运行,则填127.0.0.1

  6. 执行onos单元测试

    bazel query 'tests(//...)' | xargs bazel test # or use 'ot' alias
  7. 设置bash环境变量

    编辑~/.bash_profile,添加下面两行

    export ONOS_ROOT=~/onos
    source $ONOS_ROOT/tools/dev/bash_profile

    执行. ~/.bash_profile

虚拟机镜像安装教程

https://wiki.onosproject.org/display/ONOS15/Distributed+ONOS+Tutorial

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!