summaryrefslogtreecommitdiffstats
path: root/scripts/automation/trex_control_plane/doc_stl
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/automation/trex_control_plane/doc_stl')
-rwxr-xr-xscripts/automation/trex_control_plane/doc_stl/api/client_code.rst5
-rw-r--r--scripts/automation/trex_control_plane/doc_stl/index.rst26
2 files changed, 31 insertions, 0 deletions
diff --git a/scripts/automation/trex_control_plane/doc_stl/api/client_code.rst b/scripts/automation/trex_control_plane/doc_stl/api/client_code.rst
index 4ae2b9fd..d3e48dab 100755
--- a/scripts/automation/trex_control_plane/doc_stl/api/client_code.rst
+++ b/scripts/automation/trex_control_plane/doc_stl/api/client_code.rst
@@ -82,6 +82,11 @@ STLClient snippet
# block until done
c.wait_on_traffic(ports = [0, 1])
+ # check for any warnings
+ if c.get_warnings():
+ # handle warnings here
+ pass
+
finally:
c.disconnect()
diff --git a/scripts/automation/trex_control_plane/doc_stl/index.rst b/scripts/automation/trex_control_plane/doc_stl/index.rst
index aa2abd75..8a2fc4b0 100644
--- a/scripts/automation/trex_control_plane/doc_stl/index.rst
+++ b/scripts/automation/trex_control_plane/doc_stl/index.rst
@@ -24,6 +24,32 @@ Un-pack it using command::
tar -xzf trex_client.tar.gz
+How to use
+==================
+
+| The client assumes server is running.
+| After un-tarring the client package, you can verify basic tests in examples directory out of the box:
+
+.. code-block:: bash
+
+ cd trex_client/stl/examples
+ python stl_imix.py -s <server address>
+
+You can verify that the traffic was sent and arrives properly if you see something like this:::
+
+ Mapped ports to sides [0, 2] <--> [1, 3]
+ Injecting [0, 2] <--> [1, 3] on total rate of '30%' for 10 seconds
+
+ Packets injected from [0, 2]: 473,856
+ Packets injected from [1, 3]: 473,856
+
+ packets lost from [0, 2] --> [0, 2]: 0 pkts
+ packets lost from [1, 3] --> [1, 3]: 0 pkts
+
+ Test has passed :-)
+
+
+Also, in the stl folder there are directories with profiles that define streams and the console (with which you can easily send the profiles)
How to pyATS
==================