mirror of
https://github.com/opennetworkinglab/onos.git
synced 2025-10-15 17:31:31 +02:00
Bump version of BMv2 and disable nanomsg
To match what used in Stratum Change-Id: Ic4b87bcad6c3da36030fa01ee4135f60c05fcd78 (cherry picked from commit 1a16f00d8ddfb47c6423e5bc70f5d362230debb7)
This commit is contained in:
parent
4f32fe2752
commit
76e6386d41
@ -5,9 +5,10 @@ import random
|
|||||||
import re
|
import re
|
||||||
import socket
|
import socket
|
||||||
import threading
|
import threading
|
||||||
import time
|
|
||||||
import urllib2
|
import urllib2
|
||||||
from contextlib import closing
|
from contextlib import closing
|
||||||
|
|
||||||
|
import time
|
||||||
from mininet.log import info, warn
|
from mininet.log import info, warn
|
||||||
from mininet.node import Switch, Host
|
from mininet.node import Switch, Host
|
||||||
|
|
||||||
@ -82,7 +83,7 @@ class ONOSBmv2Switch(Switch):
|
|||||||
mininet_exception = multiprocessing.Value('i', 0)
|
mininet_exception = multiprocessing.Value('i', 0)
|
||||||
|
|
||||||
def __init__(self, name, json=None, debugger=False, loglevel="warn",
|
def __init__(self, name, json=None, debugger=False, loglevel="warn",
|
||||||
elogger=False, grpcport=None, cpuport=255,
|
elogger=False, grpcport=None, cpuport=255, notifications=False,
|
||||||
thriftport=None, netcfg=True, dryrun=False, pipeconf="",
|
thriftport=None, netcfg=True, dryrun=False, pipeconf="",
|
||||||
pktdump=False, valgrind=False, gnmi=False,
|
pktdump=False, valgrind=False, gnmi=False,
|
||||||
portcfg=True, onosdevid=None, **kwargs):
|
portcfg=True, onosdevid=None, **kwargs):
|
||||||
@ -92,6 +93,7 @@ class ONOSBmv2Switch(Switch):
|
|||||||
self.cpuPort = cpuport
|
self.cpuPort = cpuport
|
||||||
self.json = json
|
self.json = json
|
||||||
self.debugger = parseBoolean(debugger)
|
self.debugger = parseBoolean(debugger)
|
||||||
|
self.notifications = parseBoolean(notifications)
|
||||||
self.loglevel = loglevel
|
self.loglevel = loglevel
|
||||||
# Important: Mininet removes all /tmp/*.log files in case of exceptions.
|
# Important: Mininet removes all /tmp/*.log files in case of exceptions.
|
||||||
# We want to be able to see the bmv2 log if anything goes wrong, hence
|
# We want to be able to see the bmv2 log if anything goes wrong, hence
|
||||||
@ -266,8 +268,9 @@ class ONOSBmv2Switch(Switch):
|
|||||||
if not intf.IP():
|
if not intf.IP():
|
||||||
args.append('-i %d@%s' % (port, intf.name))
|
args.append('-i %d@%s' % (port, intf.name))
|
||||||
args.append('--thrift-port %s' % self.thriftPort)
|
args.append('--thrift-port %s' % self.thriftPort)
|
||||||
ntfaddr = 'ipc:///tmp/bmv2-%s-notifications.ipc' % self.name
|
if self.notifications:
|
||||||
args.append('--notifications-addr %s' % ntfaddr)
|
ntfaddr = 'ipc:///tmp/bmv2-%s-notifications.ipc' % self.name
|
||||||
|
args.append('--notifications-addr %s' % ntfaddr)
|
||||||
if self.elogger:
|
if self.elogger:
|
||||||
nanologaddr = 'ipc:///tmp/bmv2-%s-nanolog.ipc' % self.name
|
nanologaddr = 'ipc:///tmp/bmv2-%s-nanolog.ipc' % self.name
|
||||||
args.append('--nanolog %s' % nanologaddr)
|
args.append('--nanolog %s' % nanologaddr)
|
||||||
|
@ -21,7 +21,7 @@ set -e
|
|||||||
BUILD_DIR=~/p4tools
|
BUILD_DIR=~/p4tools
|
||||||
# in case BMV2_COMMIT value is updated, the same variable in
|
# in case BMV2_COMMIT value is updated, the same variable in
|
||||||
# protocols/bmv2/thrift-api/BUCK file should also be updated
|
# protocols/bmv2/thrift-api/BUCK file should also be updated
|
||||||
BMV2_COMMIT="a3f0ebe4c0f10a656f8aa1ad68cb20402a62b0ee"
|
BMV2_COMMIT="13370aaf9329fcb369a3ea3989722eb5f61c07f3"
|
||||||
PI_COMMIT="7e94b025bac6db63bc8534e5dd21a008984e38bc"
|
PI_COMMIT="7e94b025bac6db63bc8534e5dd21a008984e38bc"
|
||||||
P4C_COMMIT="2d089af757212a057c6690998861ef67439305f4"
|
P4C_COMMIT="2d089af757212a057c6690998861ef67439305f4"
|
||||||
PROTOBUF_COMMIT="tags/v3.2.0"
|
PROTOBUF_COMMIT="tags/v3.2.0"
|
||||||
@ -293,7 +293,7 @@ function do_bmv2 {
|
|||||||
|
|
||||||
./autogen.sh
|
./autogen.sh
|
||||||
if [ "${DEBUG_FLAGS}" = true ] ; then
|
if [ "${DEBUG_FLAGS}" = true ] ; then
|
||||||
./configure --with-pi --enable-debugger --disable-elogger "CXXFLAGS=-O0 -g"
|
./configure --with-pi --disable-elogger --without-nanomsg "CXXFLAGS=-O0 -g"
|
||||||
else
|
else
|
||||||
./configure --with-pi --disable-logging-macros --disable-elogger --without-nanomsg
|
./configure --with-pi --disable-logging-macros --disable-elogger --without-nanomsg
|
||||||
fi
|
fi
|
||||||
|
Loading…
x
Reference in New Issue
Block a user