aboutsummaryrefslogtreecommitdiffstats
path: root/extras
AgeCommit message (Expand)AuthorFilesLines
2019-12-05classify: vpp packet tracer supportDave Barach1-0/+20
2019-12-04vom: get interface type from vpp device typeMohsin Kazmi2-22/+21
2019-11-20bash: vpp-make-test bash functionDave Wallace1-0/+140
2019-11-15build: make checkstyle-* targets and cleanupDave Wallace1-0/+3
2019-11-06misc: add lcov scripts, README.mdDave Barach3-0/+62
2019-11-05misc: Fix python scripts shebang lineRenato Botelho do Couto2-2/+2
2019-11-05libmemif: reset number of queues on disconnectJakub Grajciar1-9/+6
2019-10-30vpp_config: fix typos in templatesPaul Vinciguerra2-3/+3
2019-10-10http_static: add .json contentDave Barach1-0/+2
2019-10-09docs: Add macos build documentationNathan Skrzypczak2-0/+91
2019-10-03emacs: track improvements in vppapigenDave Barach7-270/+17
2019-10-03dhcp: API cleanupJakub Grajciar2-6/+8
2019-09-18builtinurl: initial working attemptDave Barach2-1/+84
2019-09-11bonding: API cleanupJakub Grajciar1-2/+2
2019-09-10misc: clean up "pcap [rx|tx] trace" debug CLIDave Barach1-0/+34
2019-09-09libmemif: prevent crash in case of invalid connection handleJakub Grajciar1-9/+31
2019-09-07ip: fix udp/tcp checksum corner casesDave Barach1-0/+276
2019-09-03api: enforce vla is last and fixed string typeOle Troan3-7/+7
2019-08-21libmemif: introduce 'memif_per_thread_' namespaceJakub Grajciar9-113/+1314
2019-08-20api: Cleanup APIs interface.apiJakub Grajciar4-15/+19
2019-08-12papi: Revert vpp-api-python to py2, add py3 pkgIan Wells1-2/+29
2019-08-10http_static: tls supportDave Barach2-0/+13
2019-08-07vom: export/install cmake filesNeale Ranns6-1/+169
2019-07-31qos: Store functionNeale Ranns7-1/+653
2019-07-26libmemif: fix autoconnectJakub Grajciar1-4/+4
2019-07-26dhcp ip: DSCP settings for transmitted DHCP packetsNeale Ranns8-17/+174
2019-07-25vom: QoS supportNeale Ranns17-0/+2132
2019-07-25libmemif: fix chained buffer flagJakub Grajciar1-0/+1
2019-07-12docs: how to enable coredump with systemdBenoît Ganne1-0/+5
2019-07-11vom: Fix reference to flags in GBP bridge-domainNeale Ranns1-1/+1
2019-07-10emacs: update the vat plugin generatorDave Barach1-17/+1
2019-07-09misc: extras update list_api_changes.py to PY3Paul Vinciguerra1-11/+14
2019-07-05misc: allow second ':' in commit messageDamjan Marion1-1/+1
2019-07-03fib: allow route delete with no paths and multipath=0 to remove theNeale Ranns1-1/+2
2019-07-02gbp: add anonymous l3-out subnetsBenoît Ganne2-6/+20
2019-07-02libmemif: version 3.0Jakub Grajciar12-339/+423
2019-07-02vom: Fix [m]route dumpNeale Ranns1-36/+2
2019-07-01libmemif: icmp-responder example buffer management fixJakub Grajciar1-5/+8
2019-07-01gbp: VRF scoped contractsNeale Ranns16-53/+152
2019-06-26api: refactor format_vl_api_prefix_t return keysPaul Vinciguerra1-2/+2
2019-06-26vom: Add getter for interface admin stateMohsin Kazmi2-0/+11
2019-06-25build: fix error messages in check_commit_msg.shDave Barach1-4/+3
2019-06-19l2: BD ARP termination entry API updateNeale Ranns2-10/+11
2019-06-18fib: fib api updatesNeale Ranns21-474/+593
2019-06-14misc: Update MAINTAINERS to include interface commonNeale Ranns1-1/+1
2019-06-12misc: add check_commit_msg.sh scriptDamjan Marion1-0/+50
2019-06-07build: add -Wall and -fno-common, fix reported issuesBenoît Ganne8-45/+14
2019-06-04vom: Add bridge domain unknown unicast flooding flagMohsin Kazmi4-5/+54
2019-06-03vom: Add bridge domain arp unicast forwarding flagMohsin Kazmi4-3/+48
2019-05-31VPP-1640 - Missing rules in vpp-selinux-policyBilly McFall1-1/+2
rocess = subprocess.run( [ "ip", "netns", "exec", host_namespace, "ip", "addr", "add", host_ip_prefix, "dev", host_interface_name, ], capture_output=True, ) if process.returncode != 0: print( f"Error setting ip prefix on the host interface: " f"{process.stderr}" ) sys.exit(1) except subprocess.CalledProcessError as e: raise Exception("Error adding route to namespace:", e.output) def set_interface_mtu(namespace, interface, mtu, logger): """set an mtu number on a linux device interface.""" args = ["ip", "link", "set", "mtu", str(mtu), "dev", interface] if namespace: args = ["ip", "netns", "exec", namespace] + args try: logger.debug( f"Setting mtu:{mtu} on linux interface:{interface} " f"in namespace:{namespace}" ) subprocess.run(args) except subprocess.CalledProcessError as e: raise Exception("Error updating mtu:", e.output) def enable_interface_gso(namespace, interface): """enable gso offload on a linux device interface.""" args = ["ethtool", "-K", interface, "rx", "on", "tx", "on"] if namespace: args = ["ip", "netns", "exec", namespace] + args try: process = subprocess.run(args, capture_output=True) if process.returncode != 0: print( f"Error enabling GSO offload on linux device interface: " f"{process.stderr}" ) sys.exit(1) except subprocess.CalledProcessError as e: raise Exception("Error enabling gso:", e.output) def disable_interface_gso(namespace, interface): """disable gso offload on a linux device interface.""" args = ["ethtool", "-K", interface, "rx", "off", "tx", "off"] if namespace: args = ["ip", "netns", "exec", namespace] + args try: process = subprocess.run(args, capture_output=True) if process.returncode != 0: print( f"Error disabling GSO offload on linux device interface: " f"{process.stderr}" ) sys.exit(1) except subprocess.CalledProcessError as e: raise Exception("Error disabling gso:", e.output) def delete_namespace(ns): """delete one or more namespaces. arguments: namespaces -- a list of namespace names """ if isinstance(ns, str): namespaces = [ns] else: namespaces = ns try: for namespace in namespaces: result = subprocess.run( ["ip", "netns", "del", namespace], capture_output=True ) if result.returncode != 0: raise Exception(f"Error while deleting namespace {namespace}") except subprocess.CalledProcessError as e: raise Exception("Error deleting namespace:", e.output) def list_namespace(ns): """List the IP address of a namespace""" try: subprocess.run(["ip", "netns", "exec", ns, "ip", "addr"]) except subprocess.CalledProcessError as e: raise Exception("Error listing namespace IP:", e.output) def libmemif_test_app(memif_sock_path, logger): """Build & run the libmemif test_app for memif interface testing.""" test_dir = os.path.dirname(os.path.realpath(__file__)) ws_root = os.path.dirname(test_dir) libmemif_app = os.path.join( ws_root, "extras", "libmemif", "build", "examples", "test_app" ) def build_libmemif_app(): if not os.path.exists(libmemif_app): print(f"Building app:{libmemif_app} for memif interface testing") libmemif_app_dir = os.path.join(ws_root, "extras", "libmemif", "build") if not os.path.exists(libmemif_app_dir): os.makedirs(libmemif_app_dir) os.chdir(libmemif_app_dir) try: p = subprocess.run(["cmake", ".."], capture_output=True) logger.debug(p.stdout) if p.returncode != 0: print(f"libmemif app:{libmemif_app} cmake error:{p.stderr}") sys.exit(1) p = subprocess.run(["make"], capture_output=True) logger.debug(p.stdout) if p.returncode != 0: print(f"Error building libmemif app:{p.stderr}") sys.exit(1) except subprocess.CalledProcessError as e: raise Exception("Error building libmemif_test_app:", e.output) def start_libmemif_app(): """Restart once if the initial run fails.""" max_tries = 2 run = 0 if not os.path.exists(libmemif_app): raise Exception( f"Error could not locate the libmemif test app:{libmemif_app}" ) args = [libmemif_app, "-b", "9216", "-s", memif_sock_path] while run < max_tries: try: process = subprocess.run(args, capture_output=True) logger.debug(process.stdout) if process.returncode != 0: msg = f"Error starting libmemif app:{libmemif_app}" logger.error(msg) raise Exception(msg) except Exception: msg = f"re-starting libmemif app:{libmemif_app}" logger.error(msg) continue else: break finally: run += 1 build_libmemif_app() process = mp.Process(target=start_libmemif_app) process.start() return process