IBM
Contents Index Previous Next



Run-Time Considerations


Starting Up the PostMaster (in Windows)

When SDL Suite or TTCN Suite is started in Windows, an instance of the PostMaster is automatically started. No additional commands are needed for the PostMaster. There might however be situations when it is necessary to start the PostMaster stand-alone. This is described in the following sections. The examples only handle how the SDL Suite is started from the "DOS" command prompt, but in many cases a shortcut with the analogous parameters can be created.

Start-Up

There are several possible ways to start the PostMaster itself and the tools that wish to communicate via the PostMaster. In principle, there are two main alternatives:

We will exemplify the start-up methods by using the DemonGame simulator and a User Interface to the DemonGame simulator.

Note:

The PostMaster must be started first, but the communicating tools may be started in any order. An SDL simulator must also execute the commands Start-SDL-Env and Go before communication with another tool can start.

Starting When the PostMaster Is Present

When the SDL Suite is started from the "DOS" or UNIX prompt, an instance of the PostMaster is automatically started. No additional commands are needed for the PostMaster in this case.

The DemonGame simulator is preferably started from the SDL Suite, thus giving access to all simulation features. It can also be started directly from the "DOS" or UNIX prompt.

Starting from the "DOS" Prompt

Use the following command from the "DOS" prompt:

DemonGame.exe -post

Note:

In Windows, the simulator is a Windows GUI application and not a Console application. It is therefore not possible to run the simulator stand-alone, i.e. without -post.

Starting from the UNIX Prompt

Use the following command from the UNIX prompt:

DemonGame.sct -post

(Without the parameter, the simulator runs stand-alone, which is not desired in this case.) Starting the simulator this way restricts the possibilities of the simulation since there is no connection to the SDL Suite tools. For instance, graphical trace is disabled.

The UI is preferably started directly from the UNIX prompt. It can also be started from the DemonGame simulator with the command Start-ITEX-Com, but this requires that the executable is named sdtenv. This is the name specified in the configuration for tool number 27000.

Starting Without the PostMaster

The SDL Suite must be started directly from the "DOS" or UNIX prompt with the command:

$telelogic/bin/sdtpm <arg> & (on UNIX)

<Installation Directory>\sdt <arg> (in Windows)

(using one of the start-up arguments, see below).

The DemonGame simulator must also be started directly from the "DOS" or UNIX prompt, as described above.

Note:

On UNIX: If activating the PostMaster this way, the environment variable POSTPATH must be set to include the directory where the executables resides, typically $sdtbin.

The UI can be started in the same way as when the PostMaster is running (see above). It can also be started indirectly when starting the PostMaster by using the "DOS" or UNIX command:

$telelogic/bin/sdtpm -clients 27000 & (on UNIX)

<Installation Directory>\sdt -clients 27000 (in 
Windows)

This requires that the executable is named sdtenv, the name specified in the configuration for tool number 27000.

Note:

A tool communicating through the PostMaster can also be started from another tool by using the SESTART message. This requires that the tool to be started is specified in the configuration.

Start-Up Arguments

The PostMaster recognizes the following arguments at start-up. Normally they are not needed, but could be used for special purposes

All other arguments are passed to the tool started.

SDT-2 Connections (UNIX only)

Applications or tools linked with an SDT 2.X PostMaster application library will not be compatible with SDT 3.X PostMaster. Trying to connect such an old application to an SDT 3.X PostMaster will result in an error message:

Postmaster cannot connect SDT2 tool:<tool> with pid: 
<pid>

on standard output, if externally started, or as a service reply, if started via the start service, and the connection is aborted.

Version 3.4 PostMaster (Windows only)

If an old PostMaster (version 3.4 or older) is used the SPInit function will fail. The error code is SPOLDPOSTMASTER.

Applications or tools linked with an SDT 3.4 PostMaster application library will not be compatible with the SDT 3.6 PostMaster. Trying to connect such an old application to an SDT 3.6 PostMaster with the SPInit function will fail. The error code is SPNOPOSTMASTER.

Multiple PostMaster Instances

It is possible to have multiple instances of the PostMaster running, for instance when more than one SDL Suite or TTCN Suite has been started. In this case it should be made sure that the communicating tools are connected to the correct instance of the PostMaster.

On UNIX, the function SPInit by default looks for the PostMaster instance with the highest process id (PId) number and connects to it.

On Windows, the function SPInit by default fails if more than one PostMaster is found.

To connect to another PostMaster instance, you can set the environment variable POSTPID to the PId number of the desired PostMaster. If this variable is set, SPInit connects to the PostMaster instance with that PId number.

Configuration and Tool Search

The PostMaster configuration is read whenever a PostMaster instance is invoked. The environment variable POSTPATH defines a list of directories where the PostMaster looks for a configuration file named post.cfd.

The user can extend the normal configuration by defining the POSTPATH variable to a directory containing an extended configuration. When SDL Suite or TTCN Suite is started normally, the directories containing the binaries are put as the first directories in the POSTPATH variable.

The same search order is applied when the start service is used. The supplied tool number is matched against the name of an executable in the configuration, which is then searched for as above.


http://www.ibm.com/rational
Contents Index Previous Next