8.3.1.1. Chassis
This module contains the chassis classes that deal with basic information and configuration of the chassis itself (rather than its modules and test ports), as well as overall control of the scripting session. The chassis command names all have the form C_<xxx>
and use neither a module index nor a port index.
- class C_BUILDSTRING[source]
Bases:
object
Identify the hostname of the PC that builds the xenaserver. It uniquely identifies the build of a xenaserver.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- build_string
string, identify the hostname of the PC that builds the xenaserver
- class C_CAPABILITIES[source]
Bases:
object
A series of integer values specifying various internal limits (aka. capabilities) of the chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- can_custom_defaults
integer, can server handle custom default values for XMP parameters?
- can_latency_f2f
integer, can server handle first-to-first latency mode?
- can_par_module_upgrade
integer, can server handle parallel module upgrades?
- can_read_log_files
integer, can clients read debug log files from server?
- can_read_temperatures
integer, can the server read out chassis and/or CPU temperatures? (C_TEMPERATURE ?)
- can_stream_based_arp
integer, does server support stream-based ARP/NDP?
- can_sync_traffic_start
integer, does server support synchronous traffic start?
- can_upgrade_timekeeper
integer, is server capable of upgrading the TimeKeeper application?
- max_chain_depth
integer, max chain index.
- max_comment_len
integer, max ASCII characters in chassis comment.
- max_ext_rate
integer, maximum rate for external traffic.
- max_module_count
integer, maximum number of L23 modules.
- max_name_len
integer, max ASCII characters in chassis name.
- max_owner_name_length
integer, max number of ASCII characters in C_OWNER name
- max_password_len
integer, max ASCII characters in chassis password.
- max_protocol_count
integer, max protocol segments in a packet.
- max_session_count
integer, max number of management and scripting sessions.
- version
integer, chassis software build number.
- get()[source]
Get the internal limits (capabilities) of the tester.
- Returns:
A series of integer values specifying various internal limits - chassis software build number - max ASCII characters in chassis name - max ASCII characters in chassis comment - max ASCII characters in chassis password - maximum rate for external traffic - max number of management and scripting sessions - max chain index - maximum number of L23 modules - max protocol segments in a packet - does server support stream-based ARP/NDP? - does server support synchronous traffic start? - can clients read debug log files from server? - can server handle parallel module upgrades? - is server capable of upgrading the TimeKeeper application? - can server handle custom default values for XMP parameters? - can server handle first-to-first latency mode? - max number of ASCII characters in
C_OWNER
name - can the server read out chassis and/or CPU temperatures?- Return type:
- class C_COMMENT[source]
Bases:
object
The description of the chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- comment
string, containing the description of the chassis.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- comment
string, containing the description of the chassis.
- class C_DEBUGLOGS[source]
Bases:
object
Allows to dump all the logs of a chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- data
list of hex bytes, all the logs of a chassis
- message_length
integer, length of the message.
- class C_DHCP[source]
Bases:
object
Controls whether the chassis will use DHCP to get the management IP address.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- on_off
coded byte, whether DHCP is enabled or disabled.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- on_off
coded byte, whether DHCP is enabled or disabled.
- get()[source]
Get whether DHCP is enabled for getting management IP.
- Returns:
whether DHCP is enabled.
- Return type:
- set(on_off)[source]
Set DHCP for getting management IP.
- Parameters:
on_off (OnOff) – whether DHCP is enabled or disabled.
- set_off()
Disable DHCP for for getting management IP.
- set_on()
Enable on to DHCP for for getting management IP.
- class C_DOWN[source]
Bases:
object
Shuts down the chassis, and either restarts it in a clean state or leaves it powered off.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- magic
integer, must be the special value -1480937026.
- operation
coded byte, what to do after shutting chassis down.
- set(operation)[source]
Shuts down the chassis, and either restarts it in a clean state or leaves it powered off.
- Parameters:
operation (ChassisShutdownAction) – what to do after shutting chassis down.
- set_poweroff()
Shuts down the tester and leaves it powered off.
- set_restart()
Shuts down the tester and then restarts it.
- class C_FILEDATA[source]
Bases:
object
Uploads a fragment of a file to the chassis.
- class C_FILEFINISH[source]
Bases:
object
Completes upload of a file to the chassis. After validation it will replace any existing file with the same name.
- class C_FILESTART[source]
Bases:
object
Initiates upload of a file to the chassis. This command should be followed by a sequence og
C_FILEDATA
parameters to provide the file content, and finally aC_FILEFINISH
to commit the new file to the chassis.- class SetDataAttr[source]
Bases:
RequestBodyStruct
- checksum
four hex bytes, little-endian integer, the checksum of the file.
- file_type
four hex bytes, little-endian integer, the file type, should be 1.
- mode
four hex bytes, little-endian integer, the Linux permissions of the file.
- name
string, the name and location of the file, as a full path.
- size
four hex bytes, little-endian integer, the number of bytes in the file.
- time
four hex bytes, little-endian integer, the Linux date+time of the file.
- class C_FLASH[source]
Bases:
object
Make all the test port LEDs flash on and off with a 1-second interval. This is helpful if you have multiple chassis mounted side by side and you need to identify a specific one.
NOTICE: Require Tester to be reserved before change value.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- on_off
coded byte, determines whether to blink all test port LEDs.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- on_off
coded byte, determines whether to blink all test port LEDs.
- get()[source]
Get the status of test port LEDs.
- Returns:
the blinking status of test port LEDs
- Return type:
- set(on_off)[source]
Set test ports LEDs blinking status.
- Parameters:
on_off (OnOff) – determines whether to blink all test port LEDs.
- set_off()
Disable flashing test port LEDs.
- set_on()
Enable flashing test port LEDs.
- class C_HEALTH[source]
Bases:
object
Gets the chassis system health information.
- class C_HOSTNAME[source]
Bases:
object
Get or set the chassis hostname used when DHCP is enabled.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- hostname
string, hostname for chassis (default value “xena-“)
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- hostname
string, hostname for chassis (default value “xena-“)
- class C_INDICES[source]
Bases:
object
Gets the session indices for all current sessions on the chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- session_ids
list of integers, the session indices for all current sessions on the chassis.
- class C_IPADDRESS[source]
Bases:
object
The network configuration parameters of the chassis management port.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- gateway
address, the gateway of the local network segment.
- ipv4_address
address, the static IP address of the chassis.
- subnet_mask
address, the subnet mask of the local network segment.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- gateway
address, the gateway of the local network segment.
- ipv4_address
address, the static IP address of the chassis.
- subnet_mask
address, the subnet mask of the local network segment.
- get()[source]
Get the IP configuration information of the tester.
- Returns:
the static IP address of the chassis
the subnet mask of the local network segment
the gateway of the local network segment
- Return type:
- set(ipv4_address, subnet_mask, gateway)[source]
the IP configuration information of the tester.
- Parameters:
ipv4_address (ipaddress.IPv4Address) – the static IP address of the chassis
subnet_mask (ipaddress.IPv4Address) – the subnet mask of the local network segment
gateway (ipaddress.IPv4Address) – the gateway of the local network segment
- class C_KEEPALIVE[source]
Bases:
object
You can request this value from the chassis, simply to let it (as well as and any routers and proxies between you) know that the connection is still valid.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- tick_count
integer, an increasing number from the chassis.
- class C_LOGOFF[source]
Bases:
object
Terminates the current scripting session. Courtesy only, the chassis will also handle disconnection at the TCP/IP level
- class C_LOGON[source]
Bases:
object
You log on to the chassis by setting the value of this command to the correct password for the chassis. All other commands will fail if the session has not been logged on.
- class C_MACADDRESS[source]
Bases:
object
Get the MAC address for the chassis management port.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- mac_address
six hex bytes, indicating the MAC address
- class C_MODEL[source]
Bases:
object
Gets the specific model of this Xena chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- model
string, the Xena model designation for the chassis.
- class C_MODEL_NAME[source]
Bases:
object
Get the Xena chassis model name.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- name
ChassisModelName, the model of the Xena tester
- class C_MODEL_NUMBER[source]
Bases:
object
Get the Xena chassis model number.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- number
ChassisModelNumber, the model of the Xena tester
- class C_MULTIUSER[source]
Bases:
object
Enable or disable the ability to control one resource from several different TCP connections.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- on_off
coded byte, enable or disable the ability to control one resource from several different TCP connections
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- on_off
coded byte, enable or disable the ability to control one resource from several different TCP connections
- get()[source]
Get the status of the ability to control one resource from several different TCP connections.
- Returns:
the status of the ability to control one resource from several different TCP connections
- Return type:
- set(on_off)[source]
Enable or disable the ability to control one resource from several different TCP connections.
- Parameters:
on_off (OnOff) – enable or disable the ability to control one resource from several different TCP connections
- set_off()
Disable the ability to control one resource from several different TCP.
- set_on()
Enable the ability to control one resource from several different TCP.
- class C_NAME[source]
Bases:
object
The name of the chassis, as it appears at various places in the user interface. The name is also used to distinguish the various chassis contained within a testbed and in files containing the configuration for an entire test case.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- chassis_name
string, containing the name of the chassis.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- chassis_name
string, containing the name of the chassis.
- class C_OWNER[source]
Bases:
object
Identify the owner of the management session. The name can be any short quoted string up to eight characters long. This name will be used when reserving ports prior to updating their configuration. There is no authentication of the users, and the chassis does not have any actual user accounts. Multiple concurrent connections may use the same owner name, but only one connection can have any particular resource reserved at any given time. Until an owner is specified the chassis configuration can only be read. Once specified, the session can reserve ports for that owner, and will inherit any existing reservations for that owner retained at the chassis. Maximum 32 ASCII characters.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- username
string, containing the name of the owner of this session.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- username
string, containing the name of the owner of this session.
- class C_PASSWORD[source]
Bases:
object
The password of the chassis, which must be provided when logging on to the chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- password
string, containing the password for the chassis.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- password
string, containing the password for the chassis.
- class C_PORTCOUNTS[source]
Bases:
object
Gets the number of ports in each module slot of the chassis, and indirectly the number of slots and modules.
Note
CFP modules return the number 8 which is the maximum number of 10G ports, but the actual number of ports can be configured dynamically using the M_CFPCONFIGEXT` command.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- port_counts
list of bytes, the number of ports, typically 2 or 6, or 0 for an empty slot.
- class C_PORTERRORS[source]
Bases:
object
Gets the number of errors detected across all streams on each port of each test module of the chassis. The counts are ordered in sequence with those of the module in the lowest numbered chassis slot first. Empty slots are skipped so that a chassis with a 6-port and a 2-port test module will return eight counts regardless of which slots they are in.
Note
CFP modules return eight error counts since they can be configured as up to eight 10G ports. When in 100G and 40G mode only the first one or two counts are significant.
Note
FCS errors are included, which leads to double-counting for streams detecting lost packets using the test payload mechanism.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- error_count
list of long integers, the total number of errors across all streams, and including FCS errors.
- get()[source]
Gets the number of errors detected across all streams on each port of each test module of the chassis. The counts are ordered in sequence with those of the module in the lowest numbered chassis slot first. Empty slots are skipped so that a chassis with a 6-port and a 2-port test module will return eight counts regardless of which slots they are in.
- Returns:
the total number of errors across all streams, and including FCS errors.
- Return type:
- class C_REMOTEPORTCOUNTS[source]
Bases:
object
Gets the number of ports of each remote module. A remote module is a relative to the xenaserver, for example, xenal47server. The first integer in the returned list is always 0 because it represents the xenaserver, which is not a remote module.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- port_counts
list of bytes, the number of ports, typically 2 or 6, or 0 for an empty slot.
- get()[source]
Gets the number of ports of each remote module. A remote module is a relative to the xenaserver, for example, xenal47server. The first integer in the returned list is always 0 because it represents the xenaserver, which is not a remote module.
- Returns:
the number of ports of each module slot of the tester, 0 for an empty slot.
- Return type:
- class C_RESERVATION[source]
Bases:
object
You set this command to reserve, release, or relinquish the chassis itself. The chassis must be reserved before any of the chassis-level parameters can be changed. The owner of the session must already have been specified. Reservation will fail if any modules or ports are reserved for other users.
NOTICE: Before reserve Tester need to reserve all the ports on it, otherwise
<STATUS_NOTVALID>
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- operation
coded byte, containing the operation to perform. The reservation parameters are asymmetric with respect to set/get. When set, it contains the operation to perform. When get, it contains the status.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- operation
coded byte, containing the operation to perform. The reservation parameters are asymmetric with respect to set/get. When set, it contains the operation to perform. When get, it contains the status.
- get()[source]
Get the chassis reservation status.
- Returns:
the status of chassis reservation.
- Return type:
- set(operation)[source]
Set the chassis reservation operation to be performed.
- Parameters:
operation (ReservedAction) – reservation operation to be performed.
- set_release()
Release the ownership of the tester.
- set_relinquish()
Release the ownership of the tester from another user.
- set_reserve()
Reserve the tester.
- class C_RESERVEDBY[source]
Bases:
object
Identify the user who has the chassis reserved. The empty string if the chassis is not currently reserved.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- username
string, containing the name of the current owner of the chassis.
- class C_RESTCONTROL[source]
Bases:
object
Controls REST API server. This command should be used with extra care as it can affect other users using the server.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- operation
coded byte, what to do with the REST API server.
- set(operation)[source]
Controlling the REST API server.
- Parameters:
operation (RESTControlAction) – what to do with the REST API server
- class C_RESTENABLE[source]
Bases:
object
Controls whether the chassis will run REST API server or not. The command takes affect only after chassis reset. To start/stop REST API server use
C_RESTCONTROL
command.- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- on_off
coded byte, determines whether REST API server should be enabled or disabled.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- on_off
coded byte, determines whether REST API server should be enabled or disabled.
- get()[source]
Get the On/Off status of the REST API server.
- Returns:
the status of the REST API server, whether it is enabled.
- Return type:
xt.XmpByte
- set(on_off)[source]
Set the On/Off status of the REST API server.
- Parameters:
on_off (OnOff) – determines whether REST API server should be enabled or disabled
- set_off()
Disable the REST API server.
- set_on()
Enable the REST API server.
- class C_RESTPORT[source]
Bases:
object
The TCP port used by the REST API server.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- tcp_port
integer, containing the TCP port number (default 57911)
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- tcp_port
integer, containing the TCP port number (default 57911)
- class C_RESTSTATUS[source]
Bases:
object
Gets the REST API server operation status - whether it is active (running) or not. To get the admin status (whether the server is enabled or disabled) use
C_RESTCONTROL
command.- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- status
coded byte, determines the REST API server running status.
- class C_SCRIPT[source]
Bases:
object
To load and save CLI commands e.g. port configuration, through the binary XMP session.
- class C_SERIALNO[source]
Bases:
object
Gets the unique serial number of this particular Xena chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- serial_number
integer, the serial number of this chassis.
- class C_STATSESSION[source]
Bases:
object
Gets information and statistics for a particular session on the chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- ipv4_address
address, client IP address.
- operation_count
long integer, number of operations done during the session.
- owner
string, the name of the session owner.
- requested_byte_count
long integer, number of bytes received by the chassis.
- responded_byte_count
long integer, number of bytes sent by the chassis.
- session_type
coded integer, which kind of session.
- class C_TEMPERATURE[source]
Bases:
object
Get chassis temperature readings, if supported. Unit is millidegree Celsius.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- cpu_temperature
integer, the temperature of CPU. Unit is millidegree Celsius.
- mb1_temperature
integer, the temperature of motherboard 1. Unit is millidegree Celsius.
- mb2_temperature
integer, the temperature of motherboard 2. Unit is millidegree Celsius.
- class C_TIME[source]
Bases:
object
Get local chassis time in seconds.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- local_time
long integer, local chassis time in seconds
- class C_TIMEOUT[source]
Bases:
object
The maximum number of idle seconds allowed before the connection is timed out by the tester.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- second_count
integer, the maximum idle interval, default is 130 seconds.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- second_count
integer, the maximum idle interval, default is 130 seconds.
- class C_TKCONFIG[source]
Bases:
object
TimeKeeper config file content.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- config_file
string, TimeKeeper config file content
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- config_file
string, TimeKeeper config file content
- class C_TKGPSSTATE[source]
Bases:
object
Get TimeKeeper GPS status.
- class C_TKLICFILE[source]
Bases:
object
Get Xena TimeKeeper license file content.
- class C_TKLICSTATE[source]
Bases:
object
Get the state of the Xena TimeKeeper license file content.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- license_errors
coded integers, license errors.
- license_file_state
coded byte, timekeeper license state.
- license_type
coded byte, license type.
- class C_TKSTATUS[source]
Bases:
object
Report TimeKeeper version and status.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- status_string
string. Version, TimeKeeper license expiration, and TimeKeeper status. The string is formatted as shown in the example below. Each line is separated by.
- get()[source]
Get the version and status of TimeKeeper
- Returns:
Version, TimeKeeper license expiration, and TimeKeeper status. The string is formatted as shown in the example below.
The format is shown below.
TimeKeeper Status TimeKeeper version 8.0.3 License expires in 33 days (including grace period) TimeKeeper is not running
- Return type:
- class C_TKSTATUSEXT[source]
Bases:
object
Report TimeKeeper version and status (extended version).
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- status_string
string, extended status in JSON format. The string is formatted as shown in the example below.
- class C_TKSVCSTATE[source]
Bases:
object
Get and control TimeKeeper service state.
- set(state)[source]
Control TimeKeeper service state
- Parameters:
state (TimeKeeperServiceAction) – TimeKeeper service state
- set_restart()
Restart the TimerKeeper service.
- set_start()
Start the TimerKeeper service.
- set_stop()
Stop the TimerKeeper service.
- class C_TRAFFIC[source]
Bases:
object
Starts or stops the traffic on a number of ports on the chassis simultaneously. The ports are identified by pairs of integers (module port).
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- module_ports
list of integers, specifies ports on modules, which should stop or start generating traffic.
- on_off
coded byte, determines whether to start or stop traffic generation.
- set(on_off, module_ports)[source]
Starts or stops the traffic on a number of ports on the chassis simultaneously.
- set_off(module_ports)
Stop the traffic on a number of ports on the chassis simultaneously.
- set_on(module_ports)
Start the traffic on a number of ports on the chassis simultaneously.
- class C_TRAFFICSYNC[source]
Bases:
object
Works just as the
C_TRAFFIC
command described above with an additional option to specify a point in time where traffic should be started. This can be used to start traffic simultaneously on multiple chassis. The ports are identified by pairs of integers (module port).Note
This requires that the chassis in question all use the TimeKeeper option to keep their CPU clocks synchronized.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- module_ports
list of integers, specifies ports on modules, which should stop or start traffic generation.
- on_off
coded byte, status traffic generation.
- timestamp
long integer, the time where traffic should be started, expressed as the number of seconds since January 1 2010, 00
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- module_ports
list of integers, specifies ports on modules, which should stop or start traffic generation.
- on_off
coded byte, determines whether to start or stop traffic generation.
- timestamp
long integer, the time where traffic should be started, expressed as the number of seconds since January 1 2010, 00
- get()[source]
Get the status of traffic generation.
- Returns:
status traffic generation
the time where traffic should be started, expressed as the number of seconds since January 1 2010, 00
ports on modules, which should stop or start traffic generation
- Return type:
- set_off(timestamp, module_ports)
Stop traffic generation on the given ports simultaneously on different chassis.
- set_on(timestamp, module_ports)
Start traffic generation on the given ports simultaneously on different chassis.
- class C_VERSIONNO[source]
Bases:
object
Gets the major version numbers for the chassis firmware and the Xena PCI driver installed on the chassis.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- chassis_major_version
integer, the chassis firmware major version number.
- pci_driver_version
integer, the cXena PCI driver version.
- class C_VERSIONNO_MINOR[source]
Bases:
object
Gets the minor version number for the chassis firmware. The full version of the chassis firmware is thus where the number is obtained with the
C_VERSIONNO
command and the number is obtained with theC_VERSIONNO_MINOR
command.- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- chassis_minor_version
integer, the chassis firmware minor version number.
- reserved_1
integer, reserved.
- reserved_2
integer, reserved.
- class C_VERSIONSTR[source]
Bases:
object
Returns xenaserver version number in the new format, e.g. “467.0.0+1.0”
Obsoletes C_VERSIONNO and C_VERSIONNO_MINOR
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- version_str
string, xenaserver version number in the new format.
- class C_WATCHDOG[source]
Bases:
object
If the chassis stalls for a long time, when the timer expires the chassis will be rebooted automatically.
- class GetDataAttr[source]
Bases:
ResponseBodyStruct
- timer_value
integer, the timer value that reboots the chassis. Unit = second.
- class SetDataAttr[source]
Bases:
RequestBodyStruct
- timer_value
integer, the timer value that reboots the chassis. Unit = second.