aboutsummaryrefslogtreecommitdiffstats
path: root/test/test_udp.py
AgeCommit message (Collapse)AuthorFilesLines
2018-09-20UDP-Encap: name counters for the stats segmentNeale Ranns1-8/+13
change the ADD api so that is returns the 'ID' that can be used by the client to read the stats from the stats segment and to delete the object. Previously a similar value used required to be chosen by the client, now VPP allocates one (like it does e.g. for interfaces) Change-Id: I563cf6092276eb990c52d5457c86e72546bcf69e Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-08-10Use IP address types on UDP encap APINeale Ranns1-5/+10
Change-Id: I3c714c519b6d0009329b50947ce250c18ee2a85a Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-06-24Revert "Revert "make test: fix broken interfaces""Klement Sekera1-4/+4
This reverts commit c8efa29b6f9a91381897b54f1147daf922ed7164. Change-Id: I1d5c5773d5f86a63073e255336bd9de628e26179 Signed-off-by: Klement Sekera <ksekera@cisco.com>
2018-06-22Revert "make test: fix broken interfaces"Ole Troan1-4/+4
This reverts commit d5c60b96a3fd93916fc4af5c8d6d25625c28242e. Change-Id: I3632b9c3f76c615aee897f28f76d094e7031e689 Signed-off-by: Ole Troan <ot@cisco.com>
2018-06-22make test: fix broken interfacesKlement Sekera1-4/+4
Change-Id: I2e092774f81503e04b53cc6c6b5d357fe3fc52ab Signed-off-by: Klement Sekera <ksekera@cisco.com>
2018-06-11udp: fix for multiple workers and add testFlorin Coras1-0/+74
Since the main thread is not used for session polling anymore, when vpp is started with multiple wokers, allocate connections on the first. Also add a simple udp make test. Change-Id: Id869f5d89e0fced51048f0384fa86a5022258b7c Signed-off-by: Florin Coras <fcoras@cisco.com>
2018-03-09MPLS Unifom modeNeale Ranns1-6/+6
- support both pipe and uniform modes for all MPLS LSP - all API programming for output-labels requires that the mode (and associated data) is specificed - API changes in MPLS, BIER and IP are involved - new DPO [sub] types for MPLS labels to handle the two modes. Change-Id: I87b76401e996f10dfbdbe4552ff6b19af958783c Signed-off-by: Neale Ranns <nranns@cisco.com>
2018-01-09test: consolidate the multiple versions of send_and_*Neale Ranns1-13/+5
Change-Id: I7fa7d0ebf73dab8264a2e5ddbd412600d78ead05 Signed-off-by: Neale Ranns <nranns@cisco.com>
2017-11-07UDP Encapsulation.Neale Ranns1-0/+235
A UDP-encap object that particiapates in the FIB graph and contributes DPO to teh output chain. It thereofre resembles a tunnel but without the interface. FIB paths (and henace routes) can then be created to egress through the UDP-encap. Said routes can have MPLS labels, hence this also allows MPLSoUPD. Encap is uni-directional. For decap, one still registers with the UDP port dispatcher. Change-Id: I23bd345523b20789a1de1b02022ea1148ca50797 Signed-off-by: Neale Ranns <nranns@cisco.com>
pace */ .highlight .kp { color: #008800 } /* Keyword.Pseudo */ .highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */ .highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */ .highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */ .highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */ .highlight .na { color: #336699 } /* Name.Attribute */ .highlight .nb { color: #003388 } /* Name.Builtin */ .highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */ .highlight .no { color: #003366; font-weight: bold } /* Name.Constant */ .highlight .nd { color: #555555 } /* Name.Decorator */ .highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */ }
.. _vppinaws:

.. toctree::

VPP in AWS
==========

Warning: before starting this guide you should have a minimum knowledge on how `AWS works <https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/concepts.html>`_!

First of all, you should log into your Virtual Machine inside AWS (we suggest to create an instance with Ubuntu 16.04 on a m5 type) and download some useful packages to make VPP installation as smooth as possible:

.. code-block:: console

    $ sudo apt-get update
    $ sudo apt-get upgrade
    $ sudo apt-get install build-essential
    $ sudo apt-get install python-pip
    $ sudo apt-get install libnuma-dev
    $ sudo apt-get install make
    $ sudo apt install libelf-dev



Afterwards, types the following commands to install VPP:

.. code-block:: console

 $ curl -s https://packagecloud.io/install/repositories/fdio/1807/script.deb.sh | sudo bash




In this case we downloaded VPP version 18.07 but actually you can use any VPP version available. Then, you can install VPP with all of its plugins:


.. code-block:: console

    $ sudo apt-get update
    $ sudo apt-get install vpp
    $ sudo apt-get install vpp-plugins vpp-dbg vpp-dev vpp-api-java vpp-api-python vpp-api-lua



Now, you need to bind the NICs (Network Card Interface) to VPP. Firstly you have the retrieve the PCI addresses of the NICs you want to bind:

.. code-block:: console

 $ sudo lshw -class network -businfo




The PCI addresses have a format similar to this: 0000:00:0X.0. Once you retrieve them, you should copy them inside the startup file of VPP:

.. code-block:: console

 $ sudo nano /etc/vpp/startup.conf



Here, inside the dpdk block, copy the PCI addresses of the NIC you want to bind to VPP.


.. code-block:: console

  dev 0000:00:0X.0




Now you should install DPDK package. This will allow to bind the NICs to VPP through a script available inside the DPDK package:

.. code-block:: console

 $  wget https://fast.dpdk.org/rel/dpdk-18.08.tar.xz
 $  tar -xvf dpdk-18.08.tar.xz
 $  cd ~/dpdk-18.08/usertools/



and open the script:

.. code-block:: console

 $ ./dpdk-setup.sh



When the script is running, you should be able to execute several options. For the moment, just  install  T=x86_64-native-linuxapp-gcc and then close the script. Now go inside:

.. code-block:: console

 $ cd ~/dpdk-18.08/x86_64-native-linuxapp-gcc/



and type:

.. code-block:: console

 $ sudo modprobe uio
 $ sudo insmod kmod/igb_uio.ko


In this way, the PCIs  addresses should appear inside the setup file of DPDK and therefore you  can bind them:

.. code-block:: console

 $ ./dpdk-setup.sh



Inside the script, bind the NICs using the option 24.

Finally restart VPP and the NICs should appear inside VPP CLI:

.. code-block:: console

 $ sudo service vpp stop
 $ sudo service vpp start
 $ sudo vppctl show int




Notice that if you stop the VM, you need to bind again the NICs.