[PATCH net-next 0/7] selftests: Add tests for mirroring to gretap

Petr Machata petrm at mellanox.com
Fri Apr 27 09:17:05 AEST 2018


This suite tests GRE-encapsulated mirroring. The general topology that
most of the tests use is as follows, but each test defines details of
the topology based on its needs, and some tests actually use a somewhat
different topology.

+---------------------+                      +---------------------+
| H1                  |                      |                  H2 |
|     + $h1           |                      |           $h2 +     |
+-----|---------------+                      +---------------|-----+
      |                                                      |
+-----|------------------------------------------------------|-----+
| SW  o---> mirror                                           |     |
| +---|------------------------------------------------------|---+ |
| |   + $swp1               BR                         $swp2 +   | |
| +--------------------------------------------------------------+ |
|                                                                  |
|     + $swp3          + gt6 (ip6gretap)    + gt4 (gretap)         |
+-----|----------------:--------------------:----------------------+
      |                :                    :
+-----|----------------:--------------------:----------------------+
|     + $h3            + h3-gt6(ip6gretap)  + h3-gt4 (gretap)      |
| H3                                                               |
+------------------------------------------------------------------+

The following axes of configuration space are tested:

- ingress and egress mirroring
- mirroring triggered by matchall and flower
- mirroring to ipgretap and ip6gretap
- remote tunnel reachable directly or through a next-hop route
- skip_sw as well as skip_hw configurations

Apart from basic tests with the above mentioned features, the following
tests are included:

- handling of changes to neighbors pertinent to routing decisions in
  mirrored underlay
- handling of configuration changes at the mirrored-to tunnel (endpoint
  addresses, upness)

A suite of mlxsw-specific tests will be part of a separate submission
through linux-mlxsw patch queue.

Petr Machata (7):
  selftests: forwarding: Add libs for gretap mirror testing
  selftests: forwarding: Add test for mirror to gretap
  selftests: forwarding: Test gretap mirror with next-hop remote
  selftests: forwarding: Test mirror to gretap w/ bound dev
  selftests: forwarding: Test flower mirror to gretap
  selftests: forwarding: Test neighbor updates when mirroring to gretap
  selftests: forwarding: Test changes in mirror-to-gretap

 tools/testing/selftests/net/forwarding/lib.sh      |  96 ++++++++++
 .../testing/selftests/net/forwarding/mirror_gre.sh | 139 ++++++++++++++
 .../selftests/net/forwarding/mirror_gre_bound.sh   | 213 +++++++++++++++++++++
 .../selftests/net/forwarding/mirror_gre_changes.sh | 194 +++++++++++++++++++
 .../selftests/net/forwarding/mirror_gre_flower.sh  | 116 +++++++++++
 .../selftests/net/forwarding/mirror_gre_lib.sh     |  85 ++++++++
 .../selftests/net/forwarding/mirror_gre_neigh.sh   | 101 ++++++++++
 .../selftests/net/forwarding/mirror_gre_nh.sh      | 117 +++++++++++
 .../net/forwarding/mirror_gre_topo_lib.sh          | 129 +++++++++++++
 .../testing/selftests/net/forwarding/mirror_lib.sh |  40 ++++
 10 files changed, 1230 insertions(+)
 create mode 100755 tools/testing/selftests/net/forwarding/mirror_gre.sh
 create mode 100755 tools/testing/selftests/net/forwarding/mirror_gre_bound.sh
 create mode 100755 tools/testing/selftests/net/forwarding/mirror_gre_changes.sh
 create mode 100755 tools/testing/selftests/net/forwarding/mirror_gre_flower.sh
 create mode 100644 tools/testing/selftests/net/forwarding/mirror_gre_lib.sh
 create mode 100755 tools/testing/selftests/net/forwarding/mirror_gre_neigh.sh
 create mode 100755 tools/testing/selftests/net/forwarding/mirror_gre_nh.sh
 create mode 100644 tools/testing/selftests/net/forwarding/mirror_gre_topo_lib.sh
 create mode 100644 tools/testing/selftests/net/forwarding/mirror_lib.sh

-- 
2.4.11



More information about the Linux-mlxsw mailing list