Working with IxChariot from TestShell Studio and Runner #327
Quali-Community
started this conversation in
Useful Tips & Guides
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
IxChariot Integration Status
Users of TestShell sometimes ask about working with IxChariot from Ixia. Firstly, we do not currently have an official integration with this product BUT since it has a TCL API like other Ixia products that we do integrate with (e.g. IxLoad and IxNetwork), it is possible to drive Chariot from an automated test or driver.
Firstly, you will need to have the TCL Server installed on the machine hosting IxChariot (incidentally, it does not matter whether this is a remote machine or the same machine as the Studio/Runner host but the two will need to connect via the network). This piece is critical because IxChariot only works with certain versions of TCL.
Set up
Best to avoid ActiveState TCL and instead get the TCL server from Ixia. For this, you may need to download the IxOS which contains an installer for this. In the download, there are two files which relate to TCL. One is a CAB and another is a .msi installer for TCL 8.5. The latter is the one you need to run. It should install under IxChariot so you should end up with "C:\Program Files (x86)\Ixia\Tcl\8.5.12.0" (it may be the version changes over time since this article was posted).
To run a test through TCL, you can try one of the samples that come with IxChariot. The script I tried is called ChrPairsTest.tcl and is found under "C:\Program Files (x86)\Ixia\IxChariot\SDK\samples\tcl" typically.
Running a Chariot Test via TCL
Firstly, you should run the test from the IxChariot installation folder (this is critical). Typically this is "C:\Program Files (x86)\Ixia\IxChariot" so cd here. Next you will need to invoke the tclsh.exe which is located in "C:\Program Files (x86)\Ixia\Tcl\8.5.12.0\bin". Either use the relative path to this, or add the path to the PATH environment variable and use tclsh.exe. The single argument is the path to the sample test TCL script.
The test should run and you should see some output. At the end, a file (suffix tst) will be created. So for TCL script ChrPairsTest.tcl, you will get chrpairstest.tst. This contains output from the test.
Running the Test from Studio/Runner
Typically, the IxChariot host is not the same host as Studio/Runner. So you can install Remote Runner from the TestShell or CloudShell installer (choose Custom first and then tick Remote Runner only) on the Chariot machine. When Remote Runner is running ensure it is set up to start when Windows does and that you choose TCL (you can set up a new Engine called "IxChariot" if you wish). Next, click on the Edit button and check it points to "C:\Program Files (x86)\Ixia\Tcl\8.5.12.0\bin\tclsh.exe" or wherever you located the TCL Server above.
The TCL script you choose to run needs to be copied onto the Studio/Runner host and set up as an asset BUT you still need to ensure the current working folder on execution is set to "C:\Program Files (x86)\Ixia\IxChariot". The best way of achieving this is to add a line to the TCL script before any other commands are run
cd "C:\Program Files (x86)\Ixia\IxChariot"
On the Studio/Runner host, you need to set the Engine to point to the IxChariot host for the TCL asset, i.e. the TCL script such as ChrPairsTest.tcl.
It is a good idea to use the Check Connection button. Sometimes there is an issue with port 8101 (firewall blocking or conflict) in which case you can set another port here and on Remote Runner and try again (I tried 8103). If the connection works, the circle goes a darkish green. Without the connection, you cannot progress.
You can now drag the asset onto a test canvas and run it.
Getting Results Back to Studio/Runner
Firstly, the command output will show the TCL standard output from the test. Secondly, the test when run will generate an output file with the .tst suffix. You can then run (perhaps via SSH or Telnet) the command fmttst which is located under "C:\Program Files (x86)\Ixia\IxChariot" so it may be worth adding this to the PATH variable too on the Chariot machine. The command would look something like this:
fmttst ChrPairsTest.tst ChrParisTest.csv -v (this is comma separated values) OR
fmttst ChrPairsTest.tst ChrParisTest.html -h (self explanatory)
There is also a PDF option. The last step is to copy these files back to the Studio/Runner host and perhaps analyze the .csv using transforms etc.
Suggestion
The sample tcl scripts supplied by Ixia are just that. You could change them and/or parameterise them within the asset so that when you run it, you can alter settings, IP's, etc. In this way, it is perhaps possible to set up something more generic that can be used for different test scenarios.
Hope this helps,
Gary Wilson
Attachments:
Gary Wilson (Gary.W) - 04/24/2015 11:49 AM
· 2555 ·
Beta Was this translation helpful? Give feedback.
All reactions