Scripts Development
Scripts Development
[email protected]
Support: support-asiapac@ixi-
Ixia Pte Ltd
Asia Pacific acom.com
210 Middle Road
+91 80 4939 6410
- ii -
#08-01 IOI Plaza
Singapore 188994
Ixia KK
Japan
Ixia Technologies Pvt Ltd
Bangalore-560 037,
Karnataka, India
+91 80 42862600
Support: support-chin-
Ixia Technologies (Shanghai)
[email protected]
Company Ltd
400 898 0598 (Greater China
China Unit 3, 11th Floor, Raffles
Region)
City, Beijing
+86 10 5732 3932 (Hong
Beijing, 100007 P.R.C.
Kong)
For viewing the FAQs related to the product, go to Ixia Technical Support Online:
http://www.ixiacom.com/support-services/contact-support
- iii -
IxChariot Scripts Development and Editing Guide
Contents
- iv -
IxChariot Scripts Development and Editing Guide
-v-
IxChariot Scripts Development and Editing Guide
Command Description 36
Parameters 36
Usage Notes 36
CONFIRM_REQUEST 37
Command Description 37
Parameters 37
Usage Notes for CONFIRM Commands 37
CONFIRM_ACKNOWLEDGE 37
Command Description 37
Parameters 37
Usage Notes 37
DISCONNECT 37
Command Description 37
Parameters 37
Usage Notes 37
Application Commands 39
SLEEP 39
Command Description 39
Parameters 39
Usage Notes 39
OPTION 39
Command Description 39
Parameters 40
Notes 40
RTP_PAYLOAD_TYPE 40
Command Description 40
Parameters 40
Notes 40
- vi -
IxChariot Scripts Development and Editing Guide
- vii -
IxChariot Scripts Development and Editing Guide
Parameters 45
Usage Notes 45
Chapter 6: Configuring IxChariot Script Variables 46
Script Variable Overview 47
Script Variable Rules 47
Default Value Versus Current Value 47
Setting Source and Destination Ports 48
Using AUTO 48
Using Specific Port Numbers 48
Port Number Categories 48
Setting the SEND Data Rate 50
Selectable Data Rates 50
Send-Data-Rate Guidelines 50
Setting the SEND Data Type 52
Setting the SEND/RECEIVE Buffer Size 53
Types of Buffers in IxChariot Scripts 53
SEND and RECEIVE Buffers 53
Using a Constant Value for Buffer Size 53
Using Random Buffer Sizes for the SEND Command 53
Randomizing Buffer Sizes 54
Setting SLEEP Times 55
Standard SLEEP Variables 55
SLEEP Variable Durations 55
Guidelines for SLEEP Variables 55
Random Distributions 57
Uniform Distribution 57
Normal Distribution 57
Poisson Distribution 58
- viii -
IxChariot Scripts Development and Editing Guide
Exponential Distribution 58
Chapter 7: Providing Script Payload 60
SEND Command Payload Options 61
ZEROS and NOCOMPRESS Payload 62
Using Calgary Corpus Compression Files 63
List of Calgary Corpus Files 63
Using Your Own .cmp Files 64
Creating Your Own .cmp Files 64
HTTP GET Example 64
User01.cmp 64
User02.cmp 64
Test Configuration 64
Specifying Embedded Payload Data 66
Specifying External Payload Files 68
External Payload File Overview 68
Selecting an External Payload File 68
Using Embedded Versus Reference Payload Data 69
Referenced Payload File Considerations 70
Saving a Script with Embedded or Referenced Payload Data 70
Saving a Test with External Payload 70
Exporting Tests with External Payload to Older Versions 71
Chapter 8: IxChariot Application Groups 72
Synchronized Pair Testing 73
Introduction to Synchronized Pair Testing 74
Types of Pairs Supported 75
How Synchronization is Achieved 76
Application Groups 76
Synchronization Commands 76
- ix -
IxChariot Scripts Development and Editing Guide
Events 76
Application Groups Delivered with IxChariot 77
How Wait Times Are Recorded in Timing Records 78
The Type Parameter 78
Wait Times in Nonstreaming Scripts 78
Wait Times in Streaming Scripts 78
Creating and Running Synchronized Pair Tests 80
Creating a Test from an Application Group 81
Importing an Application Group 81
Creating and Saving the Test 81
Application Group Validation 82
Error Conditions in Application Group Tests 83
Creating and Managing Application Groups 84
The Application Group Submenu 85
Creating an Application Group 86
Editing an Application Group 88
Adding Events to an Application Group 89
Deleting an Application Group 90
Copying and Pasting an Application Group 91
Renaming an Application Group 92
Adding Pairs to an Existing Application Group 93
Removing Pairs from an Application Group 94
Replacing Host Addresses in an Application Group 95
Validating an Application Group 96
Exporting an Application Group to a File 97
Importing an Application Group from a File 98
Adding Synchronization Commands to Scripts 99
Test Requirements 100
-x-
IxChariot Scripts Development and Editing Guide
- xi -
IxChariot Scripts Development and Editing Guide
The information in this section is provided to help you navigate this manual and make better use of its content.
A list of related documentation is also included.
Topics:
l Purpose
l Manual Content
l Related Documentation
l Technical Support
Purpose
This manual provides a complete reference for IxChariot users who need to:
l Create custom application scripts.
l Modify application scripts.
l Create and use application groups.
Manual Content
This manual contains the following sections:
Name Description
About This Provides information on this manual, including its purpose, content, and related doc-
Guide umentation. Also explains how to contact technical support.
Chapter 2,
Application
Provides a brief overview of IxChariot application scripts and application groups.
Scripts Over-
view
Chapter 3,
Describes the basic structure of IxChariot scripts and describes the commands that are
Application
required in all scripts.
Script Structure
Chapter 4, Edit- Provides instructions for using the IxChariot Script Editor, including procedures for editing
ing and Creat- parameters and variables, creating new scripts from script templates, and saving new and
ing Scripts with modified script files. Also includes a reference section for the Script Editor menus and tool-
the Script Editor bar.
Chapter 5,
Script Com-
Provides a reference for all script commands.
mand Refer-
ence
Provides instructions for configuring IxChariot parameters and variables, including pro-
Chapter 6, Con-
cedures for setting source and destination port addresses, setting SLEEP times, setting the
figuring
SEND data rate, setting the SEND data type, and setting the SEND/RECEIVE buffer size.
IxChariot Script
Also includes a description of the four random distributions that can be used for SLEEP
Variables
times and buffer sizes.
Chapter 7, Describes the available options for providing the payload that is transmitted from one end-
Providing Script point to another by IxChariot scripts.
-1-
IxChariot Scripts Development and Editing Guide
Payload
Chapter 8,
Provides a complete description of IxChariot application groups: what they are, how they
IxChariot Applic-
are used, and how to create them.
ation Groups
Appendix A,
Mapping Com-
Describes the mapping of IxChariot communication commands to the APIs on the endpoint
munication
computers.
Commands to
APIs
Appendix B,
Default Buffer
Lists the default buffer sizes for the protocols and platforms supported by the IxChariot Per-
Sizes for
formance Endpoint software.
IxChariot
Scripts
Related Documentation
The IxChariot documentation suite includes the following manuals:
l Getting Started with IxChariot
l IxChariot User Guide
l IxChariot Runtime User Guide
l IxChariot Performance Endpoints
l IxChariot Scripts and Streams Reference Guide
l IxChariot Scripts Development Guide (this guide)
l IxChariot API Reference
The following additional manuals are provided for customers who are using Ixia chassis in their testing:
l Stack Manager User Guide
l Stack Manager API Reference
The IxChariot manuals are provided in hardcopy and PDF format.
IxChariot also provides comprehensive context-sensitive online help.
Technical Support
You can obtain technical support for any Ixia product by contacting Ixia Technical Support by any of the meth-
ods mentioned on the inside cover of this manual. Technical support from Ixia's corporate headquarters is avail-
able Monday through Friday from 6 a.m. to 6 p.m., Pacific Standard Time (excluding American holidays).
Technical support from Ixia's EMEA and India locations is available Monday through Friday, 8 a.m. to 5 p.m.
local time (excluding local holidays).
-2-
IxChariot Scripts Development and Editing Guide
Scripts consist of commands, such as SEND and RECEIVE, and script variables, such as the Send Buffer Size,
which produce different data flows on the network. You can alter the parameters and variables that control
script commands, and thus customize the scripts you use in testing and monitoring.
IxChariot application scripts are generally independent of the network protocol. This means the same script can
be used with any network protocol supported by the Performance Endpoints you are using.
There are two broad categories of scripts:
l Streaming scripts require a datagram (connectionless) protocol, such as IPX, RTP, or UDP.
l Nonstreaming scripts require a connection-oriented protocol, such as TCP or SPX.
Both types of scripts are described in this manual.
The user interface in IxChariot offers dialog boxes for modifying the variables in any script. In addition, you can
modify existing script files or create your own script files from scratch. The Script Editor, included with IxChariot,
reads and writes binary script files in the IxChariot format.
If you would like to create custom scripts, you can also use IxProfile to trace an application's WinSock calls and
generate a script from those calls. You can also use IxProfile to create an IxChariot script from a line trace file
that was generated by a network protocol analyzer, such as Ethereal. You can then use the IxChariot Script
Editor to modify the scripts that you generate in IxProfile. Refer to the IxProfile User Guide for more information.
-3-
IxChariot Scripts Development and Editing Guide
Nonstreaming Scripts
Nonstreaming scripts emulate the traffic of applications that require two-way communication. A database query
script, for example, requires a request/response transaction between a client and a server. Figure 3-1 shows an
example of a basic ("empty") nonstreaming script.
Figure 3-1. Basic Nonstreaming Script
As shown in this example, every script comprises the statements for both Endpoint1 and Endpoint2.
Required Commands
Every nonstreaming IxChariot script includes the following commands for Endpoint1:
...
LOOP
count = number_of_timing_records (50)
START_TIMER
LOOP
count = transactions_per_record (100)
...
INCREMENT_TRANSACTION
END_LOOP
END_TIMER
...
END_LOOP
...
When you use the IxChariot Script Editor to create a new "empty" script, it provides these seven commands as
the basic framework to which you will add commands and parameters to model application traffic. Table 3-1
provides a brief description of these commands. (Also see Chapter 5, Script Command Reference, for a more
detailed explanation of each command.)
-4-
IxChariot Scripts Development and Editing Guide
END_TIMER Marks the end of a checkpoint and causes a timing record to be generated.
END_LOOP Ends the outer loop.
Streaming Scripts
Streaming scripts emulate applications that require a unidirectional flow of data at a specified data rate. They
use a datagram (connectionless) protocol to stream data packets from Endpoint1 to Endpoint2. Figure 3-2
shows an example of the IxChariot streaming script template.
Figure 3-2. Basic Streaming Script
As is the case with nonstreaming scripts, every streaming script comprises the statements for both Endpoint1
and Endpoint2.
When you use the IxChariot Script Editor to create a new streaming script, it provides the commands described
in Table 3-2.
Table 3-2. Required Commands in a Streaming Script
Command Description
RTP_
Specifies the payload type for scripts that use RTP as the transport protocol. The default type
PAYLOAD_
is H261. (Refer to RTP_PAYLOAD_TYPE for a list of the payload types.)
TYPE
-5-
IxChariot Scripts Development and Editing Guide
DISCONNECT
Ends the connection established by the CONNECT_INITIATE command.
Because the streaming script template contains all of the commands required for a valid streaming script, you
cannot modify the structure of the script. However, you can modify the variables in the script and you can insert
SLEEP and OPTION commands into the script.
-6-
IxChariot Scripts Development and Editing Guide
-7-
IxChariot Scripts Development and Editing Guide
-8-
IxChariot Scripts Development and Editing Guide
-9-
IxChariot Scripts Development and Editing Guide
You can edit a script that is used by multiple pairs if those pairs use an identical script. Not only must it be the
same script (such as Throughput.scr), but the scripts used in the pairs must be identical in all aspects: they must
have the same steps, the same variables, and the same values applied to the variables.
To edit a script used by multiple pairs, follow these steps:
1. Select the pairs in the Test Setup window.
2. Select Edit ... from the Edit menu.
IxChariot opens the Edit Multiple Endpoint Pairs dialog. If the scripts used by the selected pairs are
identical in all aspects, IxChariot enables the Edit This Script button. Otherwise, the button is disabled.
3. Click the Edit This Script button.
IxChariot loads the selected script into the Script Editor, making it available for modification.
4. Make the desired changes.
The topics in this chapter provide detailed information about modifying scripts.
5. Select Save to Pair from the File menu.
IxChariot saves a copy of the modified script with each of the pairs.
6. Select Exit from the File menu.
IxChariot closes the Script Editor.
- 10 -
IxChariot Scripts Development and Editing Guide
Each time you return to the IxChariot Test window from the Script Editor, any unsaved changes you made to a
script are discarded.
If you have modified the current script and not saved your changes, a message box asks if you want to save
your changes to the current script.
- 11 -
IxChariot Scripts Development and Editing Guide
- 12 -
IxChariot Scripts Development and Editing Guide
In the lower part of the Script Editor window, variable elements of each parameter in a script are shown. Most
script commands have parameters that you can change to better emulate your applications and the types of
data they send on your network.
To edit a parameter:
1. Select the desired parameter in the upper portion of the Script Editor.
2. Select Edit Parameter from the Edit menu.
The Script Editor opens the Edit Parameter dialog, as shown in Figure 4-2.
Figure 4-2. Edit Parameter Dialog
Constant A unique value that you assign to a single instance of a variable within a script; enter the new
- 13 -
IxChariot Scripts Development and Editing Guide
value in the field. When you click Constant, all fields are grayed out because the rules governing
default instances of this variable do not apply.
A value that will be changed automatically for all instances of this parameter within your script.
Variable When you click Variable, all fields are enabled because the rules governing default instances of
this variable apply to your choices.
Variable The variable you want to edit. A list of appropriate variables previously defined in the script is
Name available from the list. See Editing a Script Variable for more information on the variable fields.
The value assigned to the variable. The available choices vary according to the parameter; for
example, if you chose the Sleep Time parameter, the available choices are Constant Value and
Current Uniform, Normal, Poisson, and Exponential Distribution. Do not use commas when entering val-
Value ues in this field.
Click Reset to reset the value in the Current value field to the value showing in the Default value
field the last time you exited the Edit Variable dialog box for this variable.
Instructs the endpoint to use the default appropriate for the protocol being used and the API of the
Default platform in which it is operating. This field lets you specify the initial value for the variable, when
Value the script is loaded from a file into a test.
Refer to Default Value Versus Current Value for more information.
Comment A brief explanation of what the parameter instructs the endpoint to do.
Variable A description of the variable and how it operates in a script. You can customize the help text by
help entering information in this field.
- 14 -
IxChariot Scripts Development and Editing Guide
The Edit Variable dialog box is a limited version of the Edit Parameter dialog box; the two are very similar. Vari-
ables are used in scripts to enable command parameters to be changed globally within a script. They can be
used to control loops, define port numbers, specify the data type for a send, and so forth.
To edit a script variable:
1. Select the variable from the Variable Name list in the lower area of the Script Editor window.
2. Select Edit Variable from the Edit menu.
The Script Editor opens the Edit Variable dialog, as shown in Figure 4-3.
Figure 4-3. Edit Variable Dialog
Current The type of value to be selected. The available choices vary according to the parameter; for
- 15 -
IxChariot Scripts Development and Editing Guide
example, if you chose the Sleep Time parameter, the available choices are Constant Value and
Uniform, Normal, Poisson, and Exponential Distribution. Do not use commas when entering val-
ues in this field.
The type of variable used for the SLEEP command allows five values: Constant Value, Uniform
Distribution, Normal, Poisson, and Exponential. For a Constant Value, one field is presented for
Value the value. For a distribution, two fields let you enter the upper and lower distribution range. All val-
ues are in milliseconds. See "Setting Sleep Times" in the "Rules for Scripts" section of the Applic-
ation Scripts guide for more information and pictures of the distributions.
Click Reset to reset the value in the Current value field to the value showing in the Default value
field the last time you exited the Edit Variable dialog box for this variable.
Refer to Default Value Versus Current Value for more information.
Lets you specify the initial value for the variable, when the script is loaded from a file into a test.
Accepts numbers to 9 digits. On some variable types, such as the buffer size on SEND and
Default RECEIVE, you can use the terms "DEFAULT" or "AUTO." The DEFAULT value depends on the net-
Value work protocol and the endpoints you are using. AUTO, when entered for the "source_port" or "des-
tination_port" variables, specifies that Endpoint 1 should choose the port number dynamically. Do
not use commas when entering values in this field.
Comment
A brief explanation of what the variable instructs the endpoint to do.
Variable A description of the variable and how it operates in a script. You can customize the help text by
Help entering information in this field.
- 16 -
IxChariot Scripts Development and Editing Guide
Inserting Commands
To insert a script command:
1. Choose an insertion point by selecting a command (or group of commands):
l Choose a block of commands as the insertion point if you are inserting either of the following
commands: Connect...or Loop...
In this case, the commands that you insert will surround the insertion point. Refer to Command
Insertion Example for more information.
l For all other insertions, choose a single command as the insertion point. The command that you
insert will be placed after the insertion point.
2. Select a command from the Insert menu.
The Script Editor opens the Edit Parameter dialog.
3. Modify the command parameter as desired.
Refer to Editing a Parameter of a Script Command for more information.
4. Click OK.
The Script Editor inserts the new command(s), either after or surrounding the original insertion point.
When you insert a command in one endpoint that has a corollary in the other endpoint, the Script Editor auto-
matically adds the corresponding command. For example, if you add a SEND command to Endpoint1, the
Script Editor automatically inserts the corresponding RECEIVE command to Endpoint2.
- 17 -
IxChariot Scripts Development and Editing Guide
- 18 -
IxChariot Scripts Development and Editing Guide
- 19 -
IxChariot Scripts Development and Editing Guide
All network protocols have overhead associated with connection setup and take-down. The performance dif-
ference between short and long connections can be dramatic. How do you decide which to run? Here are sev-
eral guidelines that make the decision simple.
l If you are trying to emulate a particular application, use the same connection type that the application
uses.
l If you are trying to test a network backbone or the equipment that supports one, use long connections.
Because the test endpoints do not have to go through the overhead of starting and ending the con-
nection, each endpoint pair can create considerably more traffic.
l If you are trying to test a network protocol stack, run a mix of long- and short-connection scripts.
l If you are running large tests of at least 500 endpoint pairs, do not use short-connection scripts. They are
too taxing for most networks.
- 20 -
IxChariot Scripts Development and Editing Guide
Plus, as Nagle himself admits, the Delayed ACK implementations on many networks may work badly with the
Nagle algorithm. The Delayed ACK specifies that the sending computer will not send any more data until it has
some more data on which the small ACK packets can be piggybacked. If the Delayed ACK is implemented, the
receiver is required to wait for a fixed maximum amount of time, as much as 200 ms on some networks. In a few
cases, such as sequences of "SEND, SEND, WAIT-FOR_REPLY" where both SENDs contain small amounts of
data, the connection may be stalled for one ACK delay timer plus one round-trip time.
Therefore, some applications disable the Nagle algorithm. To emulate them, you can disable it for IxChariot
tests in the Script Editor. Just do the following:
1. On the Insert menu in the Script Editor, click Options at Endpoint 1 or Options at Endpoint 2.
2. The Edit Parameter dialog box is shown, with the parameter Nagle Algorithm (TCP Only) selected.
3. In the Current Value list, click Disabled.
Another case in which you may want to disable Nagle is in TCP tests that use random buffer sizes. A few TCP
applications may not buffer smaller packets and send them out in larger chunks, but instead send data as
quickly as it becomes available, in packets of varying sizes. With random buffer sizes, your scripts can real-
istically emulate these applications. But if you do not also disable Nagle when you test with random buffer
sizes, your tests will not mean much. That is because Nagle requires the sending computer to use the MSS for
the packets it sends, overriding the BUFFER_SIZE you have selected. See Setting the SEND/RECEIVE Buffer
Size for more information.
Of course, when you disable Nagle, you should expect to see substantially reduced throughput. Do not disable
it if you are doing performance testing.
Note:On Linux, disabling Nagle will not produce the effect described above. If your sockets program (in this
case, the endpoint) does many SENDs of small sizes, do not expect to see each of those SEND requests in its
own packet. Linux will combine them into larger packets.
The MVS operating system does not support the disabling of the Nagle algorithm.
- 21 -
IxChariot Scripts Development and Editing Guide
- 22 -
IxChariot Scripts Development and Editing Guide
Note:For a protocol other than UDP, this option will have no effect, although no warning message will be
issued. If this option is specified for an endpoint whose communications stack does not support the disabling
of UDP checksums, you will see an error message, unless you are running VoIP endpoint pairs. The UDP
checksum is disabled by default for all voice over IP pairs, as long as the operating system allows it. For VoIP
pairs a "best effort" is made to disable the UDP checksum, but failure to do so is not treated as an error.
If the Transport layer does not compute a UDP checksum, it sets the field to zero. Receivers do not validate a
checksum of zero.
Disabling the UDP checksum with IxChariot is only supported on Windows operating systems and on Linux,
including the Ixia endpoint. It is possible to disable it manually on FreeBSD UNIX, IBM AIX, SCO UnixWare, and
Solaris, but the new setting affects all UDP connections on this computer until you manually reset it or restart
the computer. Instructions for disabling the checksum on these operating systems are provided below.
l To disable the UDP checksum on FreeBSD UNIX, do the following:
Go to the /sbin directory.
Enter the following at a command prompt (this command requires super-user privileges):
./sysctl -w net.inet.udp.checksum=N
where N=1 enables the UDP checksum and N=0 disables it. The change lasts until you restart. To see
the current setting, enter the following:
./sysctl -a | grep net.inet.udp.checksum
The first number shown is the current setting, the second is the default setting, and the others do not
apply.
l To disable the UDP checksum on IBM AIX, do the following:
Go to the /usr/sbin directory.
Enter the following at a command prompt (this command requires super-user privileges):
./nfso -o udpchecksum=N
where N=1 enables the UDP checksum and N=0 disables it. The change lasts until you restart. To see
the current setting, enter the following:
./nfso -o udpchecksum
l To disable the UDP checksum on SCO UnixWare 2.1, do the following:
Go to the /etc/conf/bin directory.
Enter the following at a command prompt (this command requires super-user privileges):
- 23 -
IxChariot Scripts Development and Editing Guide
./idtune UDPCKSUM N
where N=1 enables the UDP checksum and N=0 disables it. The change lasts until you restart. To see
the current setting, enter the following:
./idtune -g UDPCKSUM
l To disable the UDP checksum on Solaris, do the following:
Go to the /usr/sbin directory.
Enter the following at a command prompt (this command requires super-user privileges):
./ndd -set /dev/udp udp_do_checksum N
where N=1 enables the UDP checksum and N=0 disables it. The change lasts until you restart. To see
the current setting, enter the following:
./ndd /dev/udp udp_do_checksum
- 24 -
IxChariot Scripts Development and Editing Guide
- 25 -
IxChariot Scripts Development and Editing Guide
- 26 -
IxChariot Scripts Development and Editing Guide
Your options in the File menu vary slightly, depending upon the method you use to accessed the Script Editor
(refer to Accessing the Script Editor). The Script Editor File menu provides these following options:
l New
Open an IxChariot script template to use as the basis of a new script. When you select New, the Script
Editor opens the New Script dialog, listing the available script templates. Refer to Adding a New Script
for a description of the script templates.
l Open
Open an IxChariot script file (an .scr file).
l Save to Pair
Save your modified IxChariot script file to disk, using the original script file name. The changes you
make to the script will apply only to the script used by a single pair.
l Save to File
Save the current IxChariot script file to disk using a different name. The changes you make to the script
will apply to the script file itself, which means that any pair using this script will always use your modified
version after you save your changes.
l Save
Save the current IxChariot script file to disk, using the original script file name. The changes you make to
a script will apply to the script file itself, which means that any pair using this script will always use your
modified version after you save your changes. (This menu options appears only when you select Edit
Scripts from the Tools menu.)
l Save As
Save the current IxChariot script file to disk using a different name. The changes you make to the script
will apply only to the renamed script. (This menu options appears only when you select Edit Scripts
from the Tools menu.)
l Validate script
Check the script for errors and inconsistencies.
l Exit
Exit the Script Editor.
- 27 -
IxChariot Scripts Development and Editing Guide
The menu items in the Script Editor's Edit menu let you work with the script that is currently open.
l Undo
Lets you undo an unlimited number of previous actions in the Script Editor. However, this menu item is
only available if your last action was something other than clicking the Undo menu item.
l Redo
Lets you reverse your last Undo and return the script to the state it was in before you clicked Undo. Only
available when your last action was Undo.
l Delete
Deletes commands and variables from a script. First, highlight the command or variable you want to
delete by clicking the command or variable.
l Move Up
Moves a variable up in the sequence of commands in a script. To keep the script valid, this menu item is
only available when moving the highlighted variable up in a valid scripting choice. In some cases, the
Move Up function may cause the highlighted variable to move up to the next valid place in the script or
may cause other variables to move.
l Move Down
Moves a variable down in the sequence of commands in a script. To ensure a valid script, this menu
item is only available when moving the highlighted variable down is a valid move. In some cases, the
Move Down function may cause the highlighted variable to move down to the next valid place in the
script or may cause other variables to move.
l Swap Sides
Moves a command to the opposite endpoint or reverses a command pair. For example, if you highlight
SEND/RECEIVE and use the Swap sides functionality, the command pair is now RECEIVE/SEND. Only
available for certain commands.
l Edit Parameter
Lets you change a command's parameters and assign the command as either a constant or a variable.
See Editing a Parameter of a Script Command for more information on editing parameters.
l Edit Variable
Lets you change a variable's name, description, value, and default value. See Editing a Script Variable
for more information on editing variables.
- 28 -
IxChariot Scripts Development and Editing Guide
The Insert menu lets you insert the following commands into the script:
Table 4-4. Insert Menu Functions
Script Com-
Description
mand
CONNECT Creates a connection. Also inserts a DISCONNECT command.
SEND from
Sends a buffer of the size and type you specified from E1 and receives data at E2.
Endpoint 1
SEND from
Sends a buffer of the size and type you specified from E2 and receives data at E1.
Endpoint 2
CONFIRM
from End- Requests an acknowledgment from E2 that the previously-sent data has been received.
point 1
CONFIRM
from End- Requests an acknowledgment from E1 that the previously-sent data has been received.
point 2
WAIT at Instructs a script running on Endpoint1 to pause its execution and listen for a SIGNAL from
Endpoint 1 another script.
WAIT at Instructs a script running on Endpoint2 to pause its execution and listen for a SIGNAL from
Endpoint 2 another script.
SIGNAL at Instructs a script running on Endpoint1 to SIGNAL an "event" to the script that is waiting to
Endpoint 1 resume execution upon receipt of that event.
SIGNAL at Instructs a script running on Endpoint2 to SIGNAL an "event" to the script that is waiting to
Endpoint 2 resume execution upon receipt of that event.
UDP com-
Selects the UDP network protocol implementation that is compliant with RFC768. This is valid
pliant with
for unicast and multicast streaming scripts only. If you do not select this option, IxChariot uses a
RFC768
proprietary implementation of UDP that enables the collection of additional test statistics.
option
SLEEP at
Simulates a user or processing delay at E1.
Endpoint 1
SLEEP at
Simulates a user or processing delay at E2.
Endpoint 2
Nagle
option at Disables the Nagle algorithm for TCP sending from E1.
Endpoint 1
Nagle
option at Disables the Nagle algorithm for TCP sending from E2.
Endpoint 2
UDP Check-
sum option
Disables the UDP checksum for UDP sending from E1.
at Endpoint
1
UDP Check-
sum option
Disables the UDP checksum for UDP sending from E2.
at Endpoint
2
- 29 -
IxChariot Scripts Development and Editing Guide
at Endpoint
1
MSS option
at Endpoint Sets the transmit MSS for E2.
2
OPTIONS at the endpoints control the:
l TCP Nagle algorithm see Disabling the Nagle Algorithm.
l UDP checksum see Disabling the UDP Checksum.
l UDP protocol see Selecting RFC768 UDP.
l MSS value see Setting the Transmit MSS Option.
Highlight the location in the script where you want to insert the command, or highlight the group of commands to
insert around it. On the Insert menu, click the command you want to insert in the script.
All scripts must adhere to specific rules. Only the commands that can be inserted at the selected location in the
script are available to you; unavailable commands are dimmed. The location you highlight determines the avail-
able commands. If the command you want to insert is dimmed, try selecting an adjacent location.
- 30 -
IxChariot Scripts Development and Editing Guide
Many of the Script Editor menu options have a corresponding button on the toolbar. The following is a list of
each function represented by a toolbar button, with a brief description of each:
Table 4-5. Toolbar Buttons
Button Name Description
Move Up; Move Moves a variable to the next position in the script. Applies only to script
Down variables.
Insert Send from E1 Inserts a SEND command from Endpoint 1 at the desired location.
Insert Send from E2 Inserts a SEND command from Endpoint 2 at the desired location.
The option to choose a normal CLOSE_TYPE for your script does not appear on the Insert menu. To change
the CLOSE_TYPE from abortive (Reset) to Normal, double-click the CLOSE_TYPE variable where it appears in
the lower half of the Script Editor window.
- 31 -
IxChariot Scripts Development and Editing Guide
You can use the following keys and key combinations as shortcuts in the Script Editor window, instead of using
the mouse:
Table 4-6. Shortcut Keys for Script Editor
Key or Key
Command Invoked
Combination
Del Delete the highlighted variable from the script.
Enter Edit the currently-highlighted parameter on a command, or a script variable.
F1 Get help for the Script Editor window.
F2 Show an index of all the available help topics.
In addition to these keys, you can use the Alt key in combination with any underscored letter in a menu item title
to invoke a menu function. The menu function must be visible and not shown in gray. For example, clicking
Alt+F shows the File menu.
- 32 -
IxChariot Scripts Development and Editing Guide
- 33 -
IxChariot Scripts Development and Editing Guide
Communication Commands
The communication commands establish and disconnect the TCP sessions between the communicating end-
point computers, manage the send and receive buffers used for data transfers, and effect the transfers of data
between the endpoints. The communication commands include:
l CONNECT_INITIATE
l CONNECT_ACCEPT
l SEND
l RECEIVE
l CONFIRM_REQUEST
l CONFIRM_ACKNOWLEDGE
l DISCONNECT
CONNECT_INITIATE
Command Description
Initiates establishment of a connection from Endpoint1 to Endpoint2.
Parameters
This command takes three parameters:
l Source Port:
You can specify a specific source port number or you can select AUTO to allow the script to auto-
matically assign the port number. Selecting AUTO generally gives the best performance.
You may need to enter a specific port number when your script emulates a specific application. Spe-
cifying specific port numbers is also useful when testing devices that filter traffic based on their port num-
ber, such as firewalls.
Use AUTO if possible when testing with multiple pairs. If the same port is specified for multiple pairs, the
performance degrades, since the pairs must share (serialize) the use of the port to run the test.
l Send Buffer Size on E1:
This variable specifies the send-buffer space that the Endpoint operating system is requested to reserve
for this connection.
l Receive Buffer Size on E1:
This variable specifies the receive-buffer space that the Endpoint operating system is requested to
reserve for this connection.
- 34 -
IxChariot Scripts Development and Editing Guide
2. They need not have the same value. Their values are in the range 1 to 65,535 or the value AUTO.
l The CONNECT_INITIATE and CONNECT_ACCEPT commands use the send_buffer parameter and the
receive_buffer parameter to specify how much buffer space the operating system should allocate for
the sockets datagram service:
l UDP traffic:
For UDP traffic, these parameters specify how many bytes the operating system can store before
data loss occurs.
l TCP traffic:
For TCP traffic, these parameters specify how much buffer space the operating system should
allocate for the TCP sliding window service. This supports the RFC 1323-specified TCP window
scale option, which allows a TCP window size in excess of 64KB. You can specify a buffer size
up to 2,147,483,646 bytes. (For a detailed description of this topic, refer to the "Modifying the
TCP Window Size" topic in the IxChariot User Guide.)
l Previously, 0 was identified with the DEFAULT value; DEFAULT is now 2,147,483,647 bytes.
In general, you will want larger send and receive buffers for fast networks and for bursty traffic.
CONNECT_ACCEPT
Command Description
Causes Endpoint2 to accept the TCP connection initiated by Endpoint1.
Parameters
This command takes the same three parameters as the CONNECT_INITIATE command: port, send_buffer, and
receive_buffer. The port variable specifies the destination_port for the CONNECT_INITIATE command.
l Destination Port:
You can specify a specific destination port number or you can select AUTO to allow the script to auto-
matically assign the port number. Selecting AUTO generally gives the best performance.
You may need to enter a specific port number when your script emulates a specific application. Spe-
cifying specific port numbers is also useful when testing devices that filter traffic based on their port num-
ber, such as firewalls.
Use AUTO if possible when testing with multiple pairs. If the same port is specified for multiple pairs, the
performance degrades, since the pairs must share (serialize) the use of the port to run the test.
l Send Buffer Size on E2:
This variable specifies the send-buffer space the Endpoint operating system is requested to reserve for
this connection.
l Receive Buffer Size on E2:
This variable specifies the receive-buffer space the Endpoint operating system is requested to reserve
for this connection.
Usage Notes
Refer to Usage Notes for CONNECT and DISCONNECT.
SEND
Command Description
The SEND command sends data (a record or a file) to the other endpoint. It can be issued by either Endpoint1
or Endpoint2.
- 35 -
IxChariot Scripts Development and Editing Guide
Parameters
The SEND command has four parameters:
l Send Data Size: The number of bytes to send.
l Send Buffer Size: The size of buffers to use on each SEND.
l Send Data Type: The type of data to send.
l Send Data Rate: The rate at which to send the data.
For example, if you chose "SEND 1000, 100, ZEROS, UNLIMITED," the endpoint will send 1,000 bytes, 100
bytes at a time, with all zeros as data, as fast as possible. This SEND command will result in 10 Send calls to
the communications API.
RECEIVE
Command Description
The RECEIVE command receives the data that was sent by the other endpoint. It can be issued by either
Endpoint1 or Endpoint2. When you add a SEND command to a script, the Script Editor automatically adds the
corollary RECEIVE command for the opposite endpoint.
Parameters
The RECEIVE command has two parameters:
l send_data_size: The number of bytes that will be received.
l receive_buffer_size: The size of receive-buffers to use for each RECEIVE.
Usage Notes
Refer to Usage Notes for SEND and RECEIVE.
- 36 -
IxChariot Scripts Development and Editing Guide
CONFIRM_REQUEST
Command Description
The CONFIRM_REQUEST command can be issued by either Endpoint 1 or Endpoint 2. It requests that the
other endpoint confirm that it has received the data from the sending endpoint.
Parameters
The CONFIRM_REQUEST command has no parameters.
CONFIRM_ACKNOWLEDGE
Command Description
When you add CONFIRM_REQUEST command to a script, the Script Editor automatically adds the corollary
CONFIRM_ACKNOWLEDGE command. The CONFIRM_ACKNOWLEDGE command.sends a one-byte data
record to the endpoint that requested the confirmation.
Parameters
The CONFIRM_REQUEST command has no parameters.
Usage Notes
Refer to Usage Notes for CONFIRM Commands.
DISCONNECT
Command Description
The DISCONNECT command closes the connection that was established with the CONNECT_INITIATE com-
mand.
Parameters
This command has one parameter (close_type) that specifies the type of disconnection required. The dis-
connection types are:
l Reset: The script uses an abortive close, with a RST flag, which closes the connection immediately. With
an abortive close, the protocol stack on the receiving endpoint cannot reclaim network resources taken
up by the connection if the RST is lost, and may linger indefinitely in FIN_WAIT state.
l Normal: The script uses a normal close, with a FIN flag, to close the connection slowly, with acknow-
ledgments from the receiving computer. The normal close specifies that if the FIN is lost, the endpoints
remain in TIME_WAIT state only until the stack's timeout period elapses.
The close_type variable is valid for TCP only. The default value is Reset.
Usage Notes
Refer to Usage Notes for CONNECT and DISCONNECT.
- 37 -
IxChariot Scripts Development and Editing Guide
- 38 -
IxChariot Scripts Development and Editing Guide
Application Commands
The application commands emulate specific characteristics of an application or the traffic patterns generated by
the application. The application commands include:
l SLEEP
l OPTION
l RTP_PAYLOAD_TYPE
SLEEP
Command Description
The SLEEP command instructs the script to pause for the time specified in milliseconds (ms). SLEEP com-
mands can be used to emulate application processing time or human delays between transactions.
Parameters
The SLEEP command has one parameter: Sleep Time.
Sleep Time is the number of milliseconds that the script will sleep. Sleep Time is either a constant or a ran-
domly-selected number. If you select a constant sleep time, you enter a positive integer in the range 0 to
2,147,483,647. The default value is the constant 0, which means not to sleep. Alternatively, select a type of ran-
dom distribution and the range within which the random sleep times should be generated. Refer to Random Dis-
tributions for more information.
Usage Notes
The following rules apply to the SLEEP command:
l There is no restriction on the placement of SLEEP commands.
However, the location of SLEEP commands in scripts is important. If a SLEEP command occurs before
the timing loop, the timing records do not reflect the impact of the SLEEP command on the test meas-
urements. If the SLEEP command occurs within the timing loop, the results include the effects that the
SLEEP command had on the sending and receiving of data.
l Do not insert multiple SLEEP commands back-to-back. Doing so can cause several problems in the
Script Editor and in exporting these scripts.
Note that not all operating systems can sleep for precise 1 millisecond time periods. For example, the shortest
sleep on NetWare endpoints is 1/18th second; that is, 55 ms. Thus, if you are setting a constant sleep time for a
script that will use NetWare, multiples of 55 are the most efficient due to the granularity of its clock.
See Setting SLEEP Times for more information.
OPTION
Command Description
The OPTION command is used to specify any of the following options on Endpoint 1 or Endpoint 2:
l Disable the Nagle algorithm. Nagle is enabled by default in all IxChariot TCP scripts. It imposes flow con-
trol on TCP/IP networks. Disabling the Nagle algorithm allows you to determine the packet sizes used in
a script. For example, you must disable the Nagle algorithm to perform tests with variable buffer sizes.
l Set the maximum segment size. The max_segment_size variable controls the size of transmitted pack-
ets. When this option is set, the TCP/IP stack will segment the data stream into packets where the TCP
payload is no larger than the value specified.
l Disable UDP checksums. When UDP checksum is disabled, this variable suppresses the generation of
the checksum field of UDP headers.
- 39 -
IxChariot Scripts Development and Editing Guide
l Enable RFC768 compliant implementation of UDP. This option selects the UDP network protocol imple-
mentation that is compliant with RFC 768. If you do not select this option, IxChariot uses a proprietary
implementation of UDP to enables the collection of extended test statistics.
Parameters
Each of the variations of the OPTION command provides one parameter:
Notes
The following notes apply to the OPTION command:
l Not not all communications stacks support the UDP Checksum option.
l UDP checksums are disabled by default on all VoIP pairs, if the endpoint operating system allows it.
l Selecting the RFC 768 implementation of UDP is valid for unicast and multicast streaming scripts only. It
is not valid for VoIP or video tests.
RTP_PAYLOAD_TYPE
Command Description
The RTP_PAYLOAD_TYPE command is used only in streaming scripts. It causes Endpoint 1 to set the payload
type field in the RTP packet header to the specified value.
Parameters
The RTP_PAYLOAD_TYPE command has one parameter: RTP Payload Type.
RTP Payload Type identifies the value of the bit pattern that is set in the RTP header. It does not affect the type
of data that is being sent. If you need to send a specific type of data that is not provided by one of the .cmp files,
you can provide user-defined data, as described in Chapter 7, Providing Script Payload. All predefined scripts
default to the correct value for this variable based on the application being emulated.
You can select from our predefined values for the type field. We have defined the most common values for the
payload type. See "Supported RTP Payload Types" for a description each of the payload types you can select
for the type value.
Notes
The following rules apply to the RTP_PAYLOAD_TYPE command:
l The RTP_PAYLOAD_TYPE required is present in all streaming scripts.
l If the protocol is UDP or IPX, this command is ignored.
- 40 -
IxChariot Scripts Development and Editing Guide
- 41 -
IxChariot Scripts Development and Editing Guide
LOOP
Command Description
The LOOP command starts a program loop in the script.
Many scripts have two loops: the outer loop controls the number of timing records, while the inner loop controls
the number of transactions per timing record.
Parameters
The LOOP command has one parameter:
l Loop Count: specifies the number of times that the loop will repeat. The Loop Count variable is an
integer in the range of 1 to 2,147,483,647. The default value varies, depending where it is used in each
script. IxChariot scripts use a wide variety of default loop count values to emulate repeatedly running an
application.
END_LOOP
Command Description
The END_LOOP command marks the end of a loop.
Parameters
The END_LOOP command has no parameters.
Usage Notes
Refer to Usage Notes for LOOP and END_LOOP.
- 42 -
IxChariot Scripts Development and Editing Guide
START_TIMER
Command Description
The START_TIMER command marks the beginning of a checkpoint, and resets the transaction count to 1.
In streaming scripts, this command is used only in Endpoint 2, which keeps the timings, and accounts for lost
data.
In nonstreaming scripts, this command is used only in Endpoint 1. (Timing records are kept at Endpoint 1 in non-
streaming scripts.)
Parameters
The START_TIMER command has no parameters.
END_TIMER
Command Description
The END_TIMER command marks the end of a checkpoint and causes a timing record to be generated, which
includes the transaction count.
In streaming scripts, this command is used only in Endpoint 2, which keeps the timings and accounts for lost
data.
In nonstreaming scripts, this command is used only in Endpoint 1.
Parameters
The END_TIMER command has no parameters.
Usage Notes
Refer to Usage Notes for the START_TIMER, END_TIMER, and INCREMENT_TRANSACTION Commands.
INCREMENT_TRANSACTION
Command Description
The INCREMENT_TRANSACTION command increments the number of transactions per timing record. It is
used only in nonstreaming scripts, and every nonstreaming script is required to include one call to the
INCREMENT_TRANSACTION command.
The transaction counter is reset to 1 each time a START_TIMER command is executed. Because timing records
are kept only at Endpoint 1, this command is used only in the Endpoint 1 portion of scripts.
- 43 -
IxChariot Scripts Development and Editing Guide
Parameters
The END_TIMER command has no parameters.
Usage Notes
Refer to Usage Notes for the START_TIMER, END_TIMER, and INCREMENT_TRANSACTION Commands.
WAIT_EVENT
Command Description
The WAIT_EVENT command is used in scripts that are included in IxChariot application groups. Such scripts
synchronize their operations with one or more concurrently-running scripts. When an IxChariot script executes
a WAIT_EVENT command, it pauses execution until it receives a signal to resume execution. The signal is
received from another script that executes a SIGNAL_EVENT command with the same event parameter.
Parameters
The WAIT_EVENT command has two parameters:
l Synchronization Wait Event: A named object uniquely defined within an application group.
l Synchronization Wait Type: Specifies whether the wait time is measured or unmeasured in the timing
records.
l A streaming pair (including VoIP) can have any number of WAIT_EVENT commands on Endpoint1.
These commands can appear anywhere in the script.
l A streaming pair (including VoIP) can have any number of SIGNAL_EVENT commands on Endpoint1
and Endpoint2. These commands can appear anywhere in the script. However, because streaming is
unidirectional (from Endpoint1 to Endpoint2), WAIT_EVENT commands cannot be added on
Endpoint2.
Refer to "Synchronized Pair Testing" in the IxChariot User Guide for detailed information about application
groups, events, and the WAIT_EVENT and SIGNAL_EVENT commands.
SIGNAL_EVENT
Command Description
The SIGNAL_EVENT command is used in scripts that are included in IxChariot application groups. Such scripts
synchronize their operations with one or more concurrently-running scripts. When an IxChariot script executes
a SIGNAL_EVENT command, it causes another script which previously executed a WAIT_EVENT command to
resume execution.
For example, if Script-A executes a WAIT_EVENT (event1,measured) command, it pauses until another script in
the same application group executes a SIGNAL_EVENT (event1) command.
- 44 -
IxChariot Scripts Development and Editing Guide
Parameters
The SIGNAL_EVENT command has one parameter:
l Synchronization Signal Event: A named object uniquely defined within an application group.
Usage Notes
Refer to Usage Notes for WAIT_EVENT and SIGNAL_EVENT.
- 45 -
IxChariot Scripts Development and Editing Guide
- 46 -
IxChariot Scripts Development and Editing Guide
LOOP
count = number_of_timing_records (50)
In this example, the parameter name is count, and the variable name is number_of_timing_records, and
the current value is 50.
l The name of a variable must be unique within a script, and must not contain spaces.
l Non-zero integer variables can be used for loop count, file size, and buffer size. Values from zero to
2,147,483,647 are accepted.
l Variables used for loop count may not be used for any SEND parameter, and vice versa.
l AUTO, when entered for the source or destination_port variables, specifies that the TCP stack should
dynamically choose available ports to use in the test.
l Integer variables that allow the keyword DEFAULT are used only for buffer size. A Performance End-
point will resolve the DEFAULT keyword based on the network protocol and the endpoints you are
using.
l Random Distribution variables can be used only for sleep times and send and receive buffer sizes.
l Each variable has a variable type, depending on its usage as a command parameter. The variable type
is not exposed, per se.
l Scripts always use the Current Value defined for a variable. When you want to alter the value assigned
to a variable, you must change the Current Value. Changing the Default Value field has no effect.
l The Default Value field provides a simple means to return to a known value when you are modifying
script variables. A good rule of thumb is to always leave the Default Values set to their original, as-
installed values. This way, if you change a Current Value and the script subsequently fails, you can
return to the Default Value to start troubleshooting from a known point of reference.
The Edit Variable dialog box provides a Reset button that sets the Current Value equal to the Default Value.
- 47 -
IxChariot Scripts Development and Editing Guide
l Click AUTO to let the endpoints assign the port number automatically, or
l Enter the port number(s).
Using AUTO
Setting the port number to AUTO gives the best performance and is the preferred choice when testing with mul-
tiple pairs.
l You should plan to stop any other applications using these port numbers before you begin testing with
them.
l Only one pair at a time can use a port number for each datagram protocol (that is, RTP, IPX, or UDP).
For example, only one endpoint at a time can use port number 1234 with UDP.
l Endpoints running on IBM MVS allow only one pair at a time with the same port number. This restriction
is based on their internal tasking structure. Expect to see message CHR0264 if you attempt to use the
same port number more than once in a test with MVS endpoints.
l You should not replicate endpoints whose source and destination ports have been set. The test will not
run, or you may see CHR0206, which states that the port is already in use.
l With TCP, use only long connection scripts with endpoints whose source and destination ports have
been set. The short connection scripts will cause extremely long delays. Particularly with a TCP normal
disconnect, as soon as the endpoints establish the first connection, that connection will remain in TCP
TIME_WAIT state for between 1 and 4 minutes for each connection instead of closing the connection
and releasing the port for the rest of the test script.
l When testing with a NAT-enabled firewall, you may see differences in the line trace even though the test
will still use the ports you specified.
- 48 -
IxChariot Scripts Development and Editing Guide
When setting the port number in a script, consult the user documentation for the application that you are trying
to emulate to find out which port numbers it uses.
See Firewall Testing in the IxChariot User Guide for detailed information on setting the port numbers when
using firewalls.
- 49 -
IxChariot Scripts Development and Editing Guide
Send-Data-Rate Guidelines
Here are some guidelines for achieving a constant send_data_rate:
l When your test includes multiple pairs, avoid using UNLIMITED as the data rate. It is very possible for
one pair to consume all available bandwidth, which will cause the other pairs in the test to time-out.
l Send a large amount of data with respect to the buffer size and rate. For example, if you are using a buf-
fer size of 8K, setting a send_data_rate of 1 million bytes will give you a more consistent data rate. The
faster the rate, the more data you need to send to achieve a constant rate. Be aware that the default buf-
fer size varies based on network protocol and operating system.
l When trying to achieve a constant send rate, some scripts are better than others. Scripts that have
CONNECTs within a timing record are not good for trying to attain a steady send data rate. Scripts that
contain only sends within a timing record are better for achieving a steady send rate.
l When running streaming tests, use the UNLIMITED send_data_rate with caution. UNLIMITED sends
data as fast as possible. Using this rate may flood the network switches and adversely affect network per-
formance.
l The timers in different endpoint platforms have different resolutions. The resolution affects the accuracy
we can achieve with the send data rate. Some experimentation may be necessary to find the best send_
- 50 -
IxChariot Scripts Development and Editing Guide
- 51 -
IxChariot Scripts Development and Editing Guide
SEND
size = file_size (1000000)
buffer = send_buffer_size (65535)
type = send_datatype (NOCOMPRESS)
rate = send_data_rate (UNLIMITED)
Refer to Chapter 7, Providing Script Payload, for a detailed description of this topic.
- 52 -
IxChariot Scripts Development and Editing Guide
. . .
12 SEND
13 send = size_of_record_to_send (2147483647)
14 buffer = send_buffer_size (1048576)
. . .
By default, an IxChariot application script sends the same amount of data for every SEND command. In the
case of TCP applications, the buffer size in a script and the actual datagram size are not identical because the
Nagle algorithm causes the TCP/IP stack to combine small datagrams into larger ones. But in streaming scripts,
the send_buffer_size in the script and the actual size of datagrams are identical.
l Set the buffer size to a specific value. For example, the High Performance Throughput script sets the buf-
fers to a size of 65,535 bytes.
l DEFAULT Specifies that the endpoint will use buffers that are of the default size for the network protocol
being used. DEFAULT lets you use the default buffer size for each protocol, without having to modify the
script to handle protocol differences. The default value is different depending on the protocol and plat-
form being used.
Some scripts use the same variable for the send size and the buffer size. This ensures that the data are always
sent in one block.
- 53 -
IxChariot Scripts Development and Editing Guide
l If you are using a connection-oriented protocol, disable the Nagle algorithm. Otherwise, Nagle determ-
ines that data will be gathered into maximum segment-sized (MSS) chunks before it is sent. Refer to Dis-
abling the Nagle Algorithm.
When you are using a connectionless protocol UDP, RTP, or IPX the buffer size determines the payload size of
datagrams sent over the network.
The RECEIVE command that corresponds to the SEND command in a particular script cannot be edited to use
a random buffer size. In most cases, it is the same size as the SEND buffer_size. The table below summarizes
the behavior of the RECEIVE command, depending on the SEND buffer_size you select: either Constant,
DEFAULT, or Random distribution. (Random distributions are Uniform, Normal, Poisson, and Exponential.
Refer to Random Distributions for more information.)
- 54 -
IxChariot Scripts Development and Editing Guide
- 55 -
IxChariot Scripts Development and Editing Guide
between a user's transactions and convert the amount of time to milliseconds (ms).
For example, if you are emulating users transferring files, and the average user transfers a file every 20
minutes, there is a typical delay of 20 minutes. 20 minutes is equal to 1,200,000 ms. Divide this time by
the number of users. If you have 10 users, the 1,200,000-ms delay time is reduced to 120,000 ms. This
figure determines the upper and lower limits for SLEEP. For the lower limit, reduce this time by 10%. In
this example, use a lower limit of 120,000. For the upper limit, increase this time by 10%. In this
example, use an upper limit of 12,000,000.
As a general rule, if you are emulating a large number of users, use small values for the upper and
lower distributions. If you are emulating a small number of users, you should use large values.
- 56 -
IxChariot Scripts Development and Editing Guide
Random Distributions
You can specify random distributions for SLEEP times and for SEND buffer sizes. The four possible random dis-
tributions are Uniform, Normal, Poisson, and Exponential.
When you choose one of these random distributions, you specify the upper and lower limits for the random
times that are generated. This appears in the script in the following format:
For example, if you choose a Poisson distribution for a SEND buffer, the parameter will appear as follows in the
script:
In this example, "p" represents Poisson, the lower limit is 64 bytes, and the upper limit is 1,460 bytes.
Uniform Distribution
In the following graph, the distribution of sleep times between the upper and lower limit is completely uniform.
Any number within the upper and lower limits is as likely to be used for the sleep time as any other number. If
you plot the sleep times against the number of occurrences, the graph should be a flat horizontal line.
Figure 6-1. Graph of Uniform Distribution
Normal Distribution
In the following graph, the distribution of sleep times between the upper and lower limits is a normal, or bell-
curved, distribution. If you plot the sleep times against the number of occurrences, the graph should be a bell
curve.
The Marsaglia-Bray algorithm is used to generate the normal distribution. The average value of the distribution
is determined from the upper and lower limit. In a normal distribution, most values occur within +/-3 standard
deviations with respect to the average. The standard deviation is also calculated from the upper and lower lim-
its, as no value exceeds those limits.
Figure 6-2. Graph of Normal Distribution
- 57 -
IxChariot Scripts Development and Editing Guide
Poisson Distribution
In the following graph, the distribution of sleep times between the upper and lower limit is a Poisson distribution.
If you plot the sleep times against the number of occurrences, the graph should look like a Poisson distribution.
A typical use of a Poisson distribution is to emulate data inter-arrival rates.
The incomplete gamma function is used to generate the Poisson distribution. The average value of the dis-
tribution is determined from the upper and lower limit. In a Poisson distribution, most values occur within +/-3
standard deviations with respect to the average. The standard deviation is also calculated from the upper and
lower limits, as no value will exceed those limits.
This graph is based on an average and standard deviation. This means that 99% of all values on the graph
should be within +/-3 times the standard deviation. An endpoint calculates the standard deviation by dividing
the difference of the upper and lower limits by three.
Figure 6-3. Graph of Poisson Distribution
Exponential Distribution
- 58 -
IxChariot Scripts Development and Editing Guide
In the following graph, the distribution of sleep times between the upper and lower limit is an exponential dis-
tribution. In other words, if you plot the sleep times against the number of occurrences, the graph's maximum
should be at the upper limit and minimum should be at the lower limit.
The lower limit is where the asymptote occurs. The exponential distribution centers on the average of the upper
and lower limit. This should be the average of the distribution. An endpoint uses the average to calculate the dis-
tribution and makes sure that no values exceed the upper limit.
Figure 6-4. Graph of Exponential Distribution
- 59 -
IxChariot Scripts Development and Editing Guide
- 60 -
IxChariot Scripts Development and Editing Guide
All Zeros.
ZEROS
Refer to ZEROS and NOCOMPRESS Payload.
Randomly-generated bytes.
NOCOMPRESS
Refer to ZEROS and NOCOMPRESS Payload.
Calgary Text Com- Standard data files from the Calgary Text Compression Corpus (most of which have
pression Corpus the file extension .cmp).
Data Files Refer to Using Calgary Corpus Compression Files.
.cmp files that you create. You can supply up to 10 files with your own data. Name the
User-Defined .cmp
files User01.cmp through User10.cmp.
Files
Refer to Using Your Own .cmp Files.
When a Send Data Type variable is set to Embedded Payload (user defined), you spe-
Embedded Payload
cify the payload data for each SEND command from within the script.
(user defined)
Refer to Specifying Embedded Payload Data for detailed information.
When a Send Data Type variable is set to Payload file (user defined), you specify a
Payload File (user data file that can either be embedded within the script or can be externally referenced
defined) by the script.
Refer to Specifying External Payload Files for detailed information.
- 61 -
IxChariot Scripts Development and Editing Guide
The data for types ZEROS and NOCOMPRESS are internally generated by the endpoints. All other types
require .cmp files or user-specified data.
IxChariot generates its random data into a 250K size buffer; when the data from that buffer is transmitted, the
buffer contents are reused from the beginning.
- 62 -
IxChariot Scripts Development and Editing Guide
Several Calgary Corpus data files are included with the endpoints. The file called news.cmp contains a batch of
unedited news articles. Trans.cmp contains a transcript of a terminal session to indicate the increase in speed
that could be achieved by applying compression to a slow line to a terminal. The only non-ASCII file among
those that ship with the endpoints, lena.cmp contains a .gif file.
Ixia also provide other Calgary Corpus data files on the endpoint DVD-ROM and on our Web site. You can
download the Calgary Corpus compression files in zip format from our Web site: http://www.ixi-
acom.com/support/endpoint_library/.
For more information, see the following Web site: http://links.uwaterloo.ca/calgary.corpus.html.
book1, book2, paper1, paper2 Ordinary English, both fiction and non-fiction (ASCII).
bib A bibliography in English (ASCII).
- 63 -
IxChariot Scripts Development and Editing Guide
The same Userxx.cmp file must reside at all the endpoints you want to test with, and should be placed in the
Cmpfiles subdirectory along with the other Ixia-supplied .cmp files. Files with the same name must contain the
exact same data on each endpoint where they are used if data validation will be used.
User01.cmp
File User01.cmp contains the HTTP GET command (assume 404 bytes):
GET http://www.ixiacom.com/support/chariot_technical_questions.htm HTTP/1.0
If-Modified-Since: Tuesday, 07-Apr-00 20:39:41 GMT; length=16755
Referer: http://www.ixiacom.com/support/chariot_technical_questions.htm
Proxy-connection: Keep-Alive
User-Agent: Mozilla/4.05 [en] (WinNT; I)
Pragma: no-cache
Host: www.ixiacom.com
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, image/png, */*
Accept-Language: en
Accept-Charset: iso-8859-1,*,utf-8
User02.cmp
File User02.cmp contains the HTTP server response and the actual file (assume 1020 bytes):
HTTP/1.1 200 OK
Server: Microsoft-IIS/4.0
Date: Tue, 21 Jul 2000 22:11:49 GMT
Content-Type: text/html
Accept-Ranges: bytes
Last-Modified: Tue, 07 Apr 2000 20:39:41 GMT
ETag: "92274d4a6562bd1:6457"
Content-Length
"Text file ----"
Test Configuration
Configuration steps:
1. Create a pair and specify the script: HTTPtext.
- 64 -
IxChariot Scripts Development and Editing Guide
- 65 -
IxChariot Scripts Development and Editing Guide
Both the Current value and Default valuemay be displayed in text format or in hex format. You may edit, delete,
or add text to the value fields when the Textoption is selected. The file size is automatically adjusted to the pay-
load length.
When endpoint pairs with embedded payloads share the same destination port, the same script must be used.
Furthermore, only one CONNECT_INITIATE must exist within the script.
The total size of a script may not exceed 27,904 in the current release; use of embedded payloads can often
cause this limit to be exceeded.
In addition to typing (or pasting) in the value fields, you can also import data from a file. Press the appropriate
Import... button. The dialog in Figure 7-2 will be displayed.
Figure 7-2. Import Data Dialog
- 66 -
IxChariot Scripts Development and Editing Guide
Use the Browse... button to locate the file to be imported. After you have located the file, press the Open button.
The contents of the file will be displayed in text or hex. It is not necessary to import the entire contents of the file.
You may specify an offset within the file and a size to import. Changing the offset will show data from the spe-
cified offset is displayed at the top of the window. Press OK to accept the file and file slice to import.
- 67 -
IxChariot Scripts Development and Editing Guide
- 68 -
IxChariot Scripts Development and Editing Guide
If you choose Embedded Payload Data and the payload file is 100 MB or larger, IxChariot displays the following
warning message:
The selected payload file is larger than 100 MB. The size
of an embedded payload file has a direct impact on the
script and test file size.
Do you want to continue?
If you choose Referenced Payload File, IxChariot displays the following warning message:
- 69 -
IxChariot Scripts Development and Editing Guide
l The size of the payload data does not exceed 2 GB (2,147,483,647 bytes).
l You need to guarantee the integrity of the payload data used by a script, such that you can faithfully
reproduce tests in various test environments.
Use referenced payload files if:
l The size of the payload data exceeds 2 GB (2,147,483,647 bytes).
(Note that the combined size of all payload data for one endpoint cannot exceed 4 GB.)
l You modify the payload files quite often and want to avoid re-import the file into the script each time the
payload changes.
l You want to reduce the size of saved script and test files.
l When using referenced payload files in a script, IxChariot stores only the file name plus certain file prop-
erties with the script.
l There are no restrictions on when and how payload files can be changed. Therefore, script file and test
file integrity is the responsibility of the user. IxChariot can detect, but cannot control, changes to the pay-
load files.
l Changes to referenced files take effect immediately upon the next test run.
l When using referenced payload files in a script, if you copy or move the script file or test file to another
machine, IxChariot does not copy or move the referenced payload files. It is the responsibility of the user
to transfer referenced payload files.
l Export of already-embedded payload files is not supported.
l You can use the same payload file in different scripts in the same test. For example, you can use a
single payload file to emulate multiple users accessing a Web server and retrieving the same inform-
ation.
Note: Embedded payload files are not really embedded until you save the script or the test. In other
words, until you save the script or the test, the payload file exists only in the original location and is sus-
ceptible to modifications.
- 70 -
IxChariot Scripts Development and Editing Guide
l If the Save operation takes longer than three seconds, IxChariot displays a progress bar.
l If you selected Embedded Payload Data for one or more SEND commands, IxChariot saves the pay-
load data with the test. A single payload file used by multiple scripts within the test is stored only once.
(Depending on the size of the embedded payload files, this process can take a significant amount of
time and disk space.)
l If you selected Reference Payload File for one or more SEND commands, IxChariot stores only a ref-
erence to the payload files.
l When saving the test, IxChariot performs a check to detect if any payload files were changed outside of
IxChariot. If IxChariot detects any modified files, it displays a warning that lists the modified files. This
check is performed for both embedded and referenced payload files.
l Saves the test file, removing any embedded payload data and removing any references to referenced
payload files.
l Converts all Payload File send_data_types to NO_COMPRESS data types in the scripts.
- 71 -
IxChariot Scripts Development and Editing Guide
- 72 -
IxChariot Scripts Development and Editing Guide
- 73 -
IxChariot Scripts Development and Editing Guide
IxChariot provides the means to design tests that emulate applications that employ multiple connections. For
example, FTP operations require two connections: one for control (port 21) and the other for data transmission
(port 20). Another example is an Internet chat application, in which multiple participants join and leave the chat
session independent of one another.
To emulate applications such as FTP and internet chat clients, you can define tests with multiple pairs that:
l Start and stop independent of one another.
l Are logically linked, such that an event in one connection triggers the suspension or resumption of exe-
cution in another connection.
Tests of this nature are referred to as synchronized pair tests.
- 74 -
IxChariot Scripts Development and Editing Guide
You can create synchronized pair tests for the following types of endpoint pairs:
l Regular pairs (using streaming or nonstreaming scripts).
l VoIP pairs.
Hardware performance pairs, VoIP hardware performance pairs, video pairs, video multicast, and multicast
pairs are not supported by the Pair Synchronization feature.
Most of the topics in this section of the manual apply to both types of pairs, with the following exceptions:
l Refer to Adding Synchronization Commands to Scripts for information that is specific to scripts used by
regular pairs.
l Refer to Creating Synchronization Tests for VoIP Pairs for instructions that are specific to VoIP pairs.
- 75 -
IxChariot Scripts Development and Editing Guide
Synchronizing the operations of two or more scripts requires that the scripts recognize and respond to events
that are common to both scripts. The use of such events requires a test definition that includes the following ele-
ments.
Application Groups
An Application Group is a grouping of pairs that will participate in a synchronized test. In addition to identifying
the participants of a synchronized test, the application group also defines the synchronization events used in
the test. An application Group can use a maximum of 1,000 events.
Synchronization Commands
These are the two script commands that enable the synchronization of actions across multiple pairs:
l WAIT_EVENT
When an IxChariot script encounters a WAIT_EVENT command, it pauses execution while it waits for a
specific event to occur. The script will not continue execution until it receives a SIGNAL_EVENT com-
mand from another script for that same event.
l SIGNAL_EVENT
When a script executes a WAIT_EVENT command, it listens for a SIGNAL_EVENT command for the
same event. It resumes execution of the script once it receives that SIGNAL_EVENT command from one
of the other pairs defined in the application group.
Events
Events are objects defined within application groups and passed as parameters by the WAIT_EVENT and
SIGNAL_EVENT commands. An event is simply a unique name (a character string) defined within an applic-
ation group. An event does not specify any actions. Rather, it acts as a token to trigger the scripts to pause or
resume execution at specific points in the scripts. Each event can be associated with one and only one WAIT_
EVENT command, whereas a single event can be used by more than one SIGNAL_EVENT commands.
Using meaningful names for your events can make your scripts much easier to read. For example, FTP scripts
might use events such as "login_complete" and "start_file_transfer."
- 76 -
IxChariot Scripts Development and Editing Guide
IxChariot provides a set of prebuilt application groups, each of which emulates an application that employs mul-
tiple connections. These files are located in the following folders:
- 77 -
IxChariot Scripts Development and Editing Guide
Wait times are accounted for in timing records based on three factors:
l Whether the script is streaming or nonstreaming.
l The placement of the WAIT_EVENT command within a script.
l The WAIT_EVENT command's Type parameter.
These are described in the subsections that follow.
WAIT_EVENT(Event, Type)
The Event parameter specifies the name of an event, as described in Events. The Type parameter can be
either of the following values:
l Measured Specifies that the wait time will be measured. A measured WAIT_EVENT can be located on
either Endpoint1 or on Endpoint2.
l Not-Measured Specifies that the wait time will not be measured. An unmeasured WAIT_EVENT can be
located only on Endpoint1.
inside a pair of START_TIMER and "Not-Measured" Inactive Time in the timing records.
END_TIMER commands, "Measured" Measured Time in the timing records.
outside a pair of START_TIMER Inactive Time for the first timing record. In this case,
Either value
and END_TIMER commands, behavior is similar to a SLEEP command.
A measured WAIT_EVENT command may be necessary to reflect the behavior of a simulated application pro-
tocol (if the protocol implies wait times that need to be measured). An unmeasured WAIT_EVENT may be neces-
sary when a script must wait in transaction loops while the pairs are synchronized (the only way that IxChariot
can synchronize pairs is to use WAIT_EVENT commands).
- 78 -
IxChariot Scripts Development and Editing Guide
command in the script. The behavior is as if there is no WAIT_EVENT command, but the initial_delay is
a non-zero value. With WAIT_EVENT and initial_delay both greater than 0, the inactive time for the first
timing record will be the sum of the wait time and sleep time.
The unmeasured WAIT_EVENT has an additional advantage. For an unmeasured WAIT_EVENT, the timer on
Endpoint2 is started only after the WAIT_EVENT, so there is no fear of getting a timeout error because of an
unusually long wait time.
- 79 -
IxChariot Scripts Development and Editing Guide
- 80 -
IxChariot Scripts Development and Editing Guide
The procedure for creating a synchronized pair test differs from that of tests using individual (non-synchronized)
pairs.
Unlike individual scripts which you select as part of a test definition you must first import an application group
into a test window. Once you have done that, the procedures for creating the test are identical to any other test.
- 81 -
IxChariot Scripts Development and Editing Guide
Running an application group test is no different from running any other type of test. However, when you start
the run of a test that includes application groups, IxChariot performs a set of validations before executing the
test. These validations include:
l Checking the script for consistency, including:
l Verifying that each pair contains at least one synchronization command.
l Verifying that each event is referenced by a maximum of one WAIT_EVENT command.
l Verifying that each WAIT_EVENT command has at least one corresponding SIGNAL_EVENT
command (the commands reference the same event).
l Checking for deadlock conditions.
Deadlock is a condition that occurs when two processes are each waiting for the other to complete
before proceeding. Deadlock can occur in an IxChariot script if two scripts each execute a WAIT_EVENT
command before either script has executed a corresponding SIGNAL_EVENT. In this case, neither
script could resume execution.
Deadlock can also occur when WAIT_EVENT and SIGNAL_EVENT commands execute within loops.
For example, assume that an application group includes scripts that use event event1 as follows:
l A WAIT_EVENT(event1) command occurs in a loop having p iterations.
l A SIGNAL_EVENT(event1) command occurs in a loop having n iterations.
l A SIGNAL_EVENT(event1) command occurs in a loop having m iterations.
Because a SIGNAL_EVENT command will resume a referred WAIT_EVENT command only
once, a deadline condition will occur if p>m+n.
Before executing a test, you can validate the application group to check for potential problems. Refer to Val-
idating an Application Group for instructions.
- 82 -
IxChariot Scripts Development and Editing Guide
In tests that use application groups, an event in one pair triggers the suspension or resumption of a script in
another pair. Dependencies among pairs are therefore inherent in application groups.
Because application groups define dependencies among separate pairs, IxChariot must ensure that the failure
of one pair during a test will not cause a deadlock condition in any of the other pairs. For example, if script_b is
waiting for script_a to signal an event, and script_a fails before the event is signaled, IxChariot must ensure that
script_b does not wait indefinitely for that event. Therefore, if one pair in an application group test fails, the other
pairs in the test will ignore all WAIT_EVENT and SIGNAL_EVENT messages associated with the failed pair.
This allows the test to continue to run.
- 83 -
IxChariot Scripts Development and Editing Guide
- 84 -
IxChariot Scripts Development and Editing Guide
A test using synchronized pairs requires an application group. You create and manage application groups
using the following IxChariot menus:
l The Application Group submenu selected from the File menu (for importing and exporting application
groups).
l The Application Group submenu selected from the Edit menu.
l The Application Group pop-up menu that is available when you select one or more pairs and right-click
the mouse.
Figure 8-1 shows an example of the Application Group submenu accessed from the Edit menu.
Figure 8-1. Application Group Menu
- 85 -
IxChariot Scripts Development and Editing Guide
- 86 -
IxChariot Scripts Development and Editing Guide
Having created a valid application group, the next step is to create or modify IxChariot scripts that use that
application group in testing:
l For regular pairs, this is described in Adding Synchronization Commands to Scripts.
l For VoIP pairs, you do not edit the scripts directly. The procedure for specifying the events is described
in Creating Synchronization Tests for VoIP Pairs.
- 87 -
IxChariot Scripts Development and Editing Guide
- 88 -
IxChariot Scripts Development and Editing Guide
- 89 -
IxChariot Scripts Development and Editing Guide
To delete an application group and all the pairs contained in the group, follow these steps:
1. Click the PG button to display the application group names in the Group column of the Test window.
2. Select the application group that you want to delete.
3. Right-click the mouse to display the pop-up menu.
4. Select Delete Application Group... from the Application Group item on the menu.
IxChariot displays a confirmation dialog: "Are you sure you want to delete the application group and its
pairs?"
5. Click YES.
IxChariot deletes the application group and all the pairs contained within the group.
Note: If you want to retain one or more of the pairs contained in an application group, remove those pairs
before deleting the group. Refer to Removing Pairs from an Application Group for instructions.
- 90 -
IxChariot Scripts Development and Editing Guide
- 91 -
IxChariot Scripts Development and Editing Guide
You will need to rename an application group whenever you perform either of the following tasks:
l Copy and paste an application group (see Copying and Pasting an Application Group).
If you copy an application group to the clipboard and then attempt to paste it into the Test window,
IxChariot requires you to assign a unique name to the group that you are pasting.
l Importing an application group (see Importing an Application Group from a File).
If you have an application group open and you attempt to import an application group with the same
name, IxChariot requires that you to assign a unique name to the group that you are importing.
In each case, IxChariot opens the Rename an Application Group dialog, as shown in Figure 8-3.
Figure 8-3. Rename Application Group Dialog
- 92 -
IxChariot Scripts Development and Editing Guide
To add one or more pairs to an existing application group, follow these steps:
1. Select the pair(s) that you want to add to the application group.
2. Right-click the mouse to display the pop-up menu.
3. Select Add to Application Group... from the Application Group item on the menu.
IxChariot opens the Add Pair(s) to Application Group dialog.
4. Select the application group to which you are adding the pair(s).
5. Click OK.
IxChariot adds the pairs to the application group.
Note: You can also replicate pairs within an application group. However, this is not recommended because
you may end up replicating scripts which can result in multiple WAIT_EVENT commands that reference the
same event.
- 93 -
IxChariot Scripts Development and Editing Guide
To remove one or more pairs from an application group, follow these steps:
1. Click the PG button to display the application group names in the Group column of the Test window.
2. Expand the list of pairs for the desired application group.
3. Select the pairs (one or more) that you want to remove from the group.
4. Right-click the mouse to display the pop-up menu.
5. Select Remove from Application Group... from the Application Group item on the menu.
IxChariot removes the selected pairs from the application group and moves them to "No Group."
Note that if you remove all the pairs from an application group, IxChariot deletes the application group.
- 94 -
IxChariot Scripts Development and Editing Guide
The application groups delivered with IxChariot (as well as those that you create with IxProfile) use symbolic
names for the endpoints in the group. For example, the SIP-VoIP application group uses endpoint names such
as caller and callee. Therefore, when you import one of these application group, you need to replace the sym-
bolic names with the actual addresses that you are using in your test. IxChariot provides the Search and
Replace Addresses dialog for this purpose.
To search for and replace addresses in an application group, follow these steps:
1. Click the PG button to display the application group names in the Group column of the Test window.
2. Select the desired application group.
3. Right-click the mouse to display the pop-up menu.
4. Select Search and Replace Addresses... from the Application Group item on the menu.
IxChariot opens the Search and Replace Addresses dialog. Test addresses and management
addresses are listed separately.
5. Select an address that you want to replace (a test or a management address).
6. Click Modify.
IxChariot opens the Change Address dialog.
7. Enter the replacement address.
8. Click OK to close the Change Address dialog.
9. Click OK to close the Search and Replace Addresses dialog.
IxChariot locates each instance of the address and replaces it with the new address that you entered. The
replacement is made in each of the pairs contained in the application group.
- 95 -
IxChariot Scripts Development and Editing Guide
The same validation check is automatically performed when you run a test using an application group. Refer to
Creating and Running Synchronized Pair Tests for more information.
- 96 -
IxChariot Scripts Development and Editing Guide
IxChariot allows you to save (export) application groups as files on disk and reload them whenever desired. To
export an application group to a file, follow these steps:
1. Click the PG button to display the application group names in the Group column of the Test window.
2. Select the application group that you want to export.
3. Select Export... from the Application Group item on the File menu.
IxChariot opens the Export an Application Group dialog.
4. Specify the desired folder in the Save in field.
5. Enter a file name.
6. Click EXPORT.
IxChariot exports the application group to a file, giving it a file extension of .iag.
- 97 -
IxChariot Scripts Development and Editing Guide
IxChariot allows you to load (import) an application group that was previously saved to an .iag file. To import an
application group, follow these steps:
1. Select Import... from the Application Group item on the File menu.
IxChariot opens the Import an Application Group File dialog.
2. Select the file name (application groups have an .iag file extension).
3. Click IMPORT.
IxChariot imports the application group into the Test window.
- 98 -
IxChariot Scripts Development and Editing Guide
- 99 -
IxChariot Scripts Development and Editing Guide
Test Requirements
- 100 -
IxChariot Scripts Development and Editing Guide
When writing scripts for use in application groups, you must observe the following rules:
l A WAIT_EVENT command must have at least by one corresponding SIGNAL_EVENT command and
this SIGNAL_EVENT command must be executed on the same machine as the WAIT_EVENT.
l Each event can be referenced by a maximum of one WAIT_EVENT command. (However, an event can
be referenced by more than one SIGNAL_EVENT command.)
l A WAIT_EVENT command should be following by a SEND or a CONNECT_ INITIATE command. This
ensures that the other endpoint will execute a blocking command, such as RECEIVE or CONNECT_
ACCEPT.
l For nonstreaming scripts, a measured WAIT_EVENT can be located on either Endpoint1 or on
Endpoint2. An unmeasured WAIT_EVENT can be located only on Endpoint1.
- 101 -
IxChariot Scripts Development and Editing Guide
6. If you are inserting a WAIT_EVENT command, select Synchronization Wait Type from the Parameter
drop-down box, then select one of the choices for the Current Value. (This parameter is not required by
the SIGNAL_EVENT command.)
Your select determines whether or not the wait time will be measured.
7. Click OK.
IxChariot inserts the command, followed by its parameter(s), into the script.
- 102 -
IxChariot Scripts Development and Editing Guide
The example in Figure 8-5 shows two scripts using the event "login_complete" to control the pause and resump-
tion of processing. Script-A pauses when it executes the WAIT_EVENT command. While waiting, it listens for a
SIGNAL_EVENT for "login_complete." When Script-B executes the SIGNAL_EVENT command, it causes any
other script waiting on that event to resume processing.
Figure 8-5. Synchronization Commands in Script Editor
Figure 8-6 shows an example of two synchronized scripts used in an application group. In this example, Pair_
1_A_B pauses when it reaches the WAIT_EVENT command on line 8. It does not resume execution until
another script in the application group (Pair_3_A_B in this example) executes a SIGNAL_EVENT command for
the same event. In this case, the event name is "event_3_P3_P1_A."
Figure 8-6. Synchronization Commands in the Script Editor
- 103 -
IxChariot Scripts Development and Editing Guide
- 104 -
IxChariot Scripts Development and Editing Guide
- 105 -
IxChariot Scripts Development and Editing Guide
- 106 -
IxChariot Scripts Development and Editing Guide
- 107 -
IxChariot Scripts Development and Editing Guide
a. Check the Count wait time as inactive time in results if appropriate for your test.
a. Select the Signal checkbox, then choose an event from the drop-down list.
Your choices will be Not Assigned plus any events that you have defined for the current applic-
ation group.
6. Specify the Endpoint 2 pair synchronization events:
Select the Signal checkbox, then choose an event from the drop-down list.
Your choices will be Not Assigned plus any events that you have defined for the current application
group.
7. Click OK.
8. Repeat steps 4 through 7 for each VoIP pair in the application group.
- 108 -
IxChariot Scripts Development and Editing Guide
- 109 -
IxChariot Scripts Development and Editing Guide
CONNECT_
INITIATE socket()
Socket() bind() and connect(): once
(source_port, bind()
per connection, per test.
send_buffer, connect()
receive_buffer)
CONNECT_
socket()
ACCEPT (des-
bind()
tination_port, None.
listen()
send_buffer,
accept()
receive_buffer)
Using sendto() or send(), send the
number of bytes in size, in send_buf-
SEND (size,
Using write(), send the number of bytes in size, in fer_size chunks. The last buffer may
send_buffer_
send_buffer_size chunks. The last buffer may be be smaller than the send_buffer_
size, send_data-
smaller than the buffer_size. The maximum buffer_ size.
type, send_data_
size value is 2,147,483,647. See Sockets Datagram send_buffer_
rate)
size for information on the maximum
buffer size.
Issue read() calls in a loop, until the number of Issue recvfrom() or recv() calls in a
bytes specified in size have been received, in loop, until the number of bytes spe-
RECEIVE (size,
receive_buffer_size chunks. The last buffer cified in size have been received.
receive_buffer_
received may be smaller than the receive_buffer_ See Sockets Datagram receive_buf-
size)
size value. The maximum buffer_size value is fer_size for information on the max-
2,147,483,647. imum buffer size.
- 110 -
IxChariot Scripts Development and Editing Guide
- 111 -
IxChariot Scripts Development and Editing Guide
CONNECT_
INITIATE t_open() t_open()
(source_port, t_bind() t_bind() and t_connect(): once per
send_buffer, t_connect() connection, per test
receive_buffer)
CONNECT_
ACCEPT (des-
t_listen()
tination_port, None.
t_accept()
send_buffer,
receive_buffer)
SEND (size,
send_buffer_
Using t_sndudata(), send the number
size, send_data-
of bytes in size, in buffer_size chunks.
type, send_data_ Using t_snd(), send the number of bytes in size, in
The last buffer may be smaller than
rate) send_buffer_size chunks. The last buffer may be
the send_buffer_size.
Refer to Provid- smaller than the send_buffer_size. The maximum
See TLI Datagram send_buffer_size
ing Script Pay- send_buffer_size value is 32767.
below for information on the max-
load for more on
imum buffer size.
the datatype para-
meter.
- 112 -
IxChariot Scripts Development and Editing Guide
dow size in numbers of datagrams. Therefore, it is important to use the same value for the RECEIVE buffer_size
as for the send_buffer_size.
The maximum value for the buffer_size of the RECEIVE command is limited by the IPX network packet size.
- 113 -
IxChariot Scripts Development and Editing Guide
Operating Sys- TCP send/re- SPX send/re- UDP send/ IPX send/re- RTP send/re-
tem ceive ceive receive ceive ceive
Linux (all) 32,767 n/a 8,175 n/a 8,180
- 114 -
IxChariot Scripts Development and Editing Guide
validating 82, 96
Index wait times 78
WAIT_EVENT command 44, 76
A
Application Script Name 19
application commands 39
application scripts, See scripts 3
application groups
AUTO 34, 48
about 72
adding pairs to 93 B
exporting 97
C
for VoIP pairs 105
Calgary Corpus data files 61, 63
host addresses, replacing 95
Calgary Corpus Web site 63
importing 81, 98
cmp files 61
removing pairs from 94
commands
renaming 92
application 39
rules for scripts 101
communication 34
SIGNAL_EVENT command 44, 76
program control 42
synchronization 76
commands, inserting in a script 29
synchronization commands 99
communication commands 34, 109
synchronized pair testing 73
CONFIRM_ACKNOWLEDGE 37
Type parameter 78
CONFIRM_REQUEST 36
- 115 -
IxChariot Scripts Development and Editing Guide
CONNECT_ACCEPT 6, 35 WAIT_EVENT 44
CONNECT_INITIATE 6, 34 events, in applicaton groups 76
Current Value 15, 47 exponential distribution 58
external payload files 68
D
data rate optimization 51 H
datatype files 52 host addresses in application groups 95
datatype, send options 61
I
DEFAULT buffer size 114
INCREMENT_TRANSACTION 5, 43
Default Value 16, 47
initial_delay variable 55
delayed ACK algorithm 21
IxProfile 3, 95
destination port number 35, 48
DISCONNECT 6, 37 L
event N
SIGNAL_EVENT 44 Nagle algorithm 21, 39
- 116 of 119-
IxChariot Scripts Development and Editing Guide
- 117 -
IxChariot Scripts Development and Editing Guide
- 118 of 119-
IxChariot Scripts Development and Editing Guide
- 119 -