Defining an SPX connection

The channel definition at the sending end specifies the address of the target. A listener program must be run at the receiving end.

Sending end

If the target machine is remote, specify the SPX address of the target machine in the Connection name field of the channel definition.

The SPX address is specified in the following form:

        network.node(socket)

where:

network
Is the 4-byte network address of the network on which the remote machine resides,
node
Is the 6-byte node address, which is the LAN address of the LAN adapter in the remote machine
socket
Is the 2-byte socket number on which the remote machine will listen.

If the local and remote machines are on the same network then the network address need not be specified. If the remote end is listening on the default socket (5E86) then the socket need not be specified.

An example of a fully specified SPX address specified in the CONNAME parameter of an MQSC command is:

      CONNAME('00000001.08005A7161E5(5E87)')

In the default case, where the machines are both on the same network, this becomes:

      CONNAME(08005A7161E5)

The default socket number may be changed by specifying it in the queue manager configuration file (qm.ini) or the Windows registry:

SPX:
  Socket=5E87

For more information about the values you set using qm.ini or the Windows registry, see Appendix C, Configuration file stanzas for distributed queuing.

Using the SPX KEEPALIVE option (OS/2 only)

If you want to use the KEEPALIVE option (as discussed in Checking that the other end of the channel is still available) you need to add the following entry to your queue manager configuration file (qm.ini):

SPX:
   KeepAlive=yes

You can use the timeouts described in IPX/SPX parameters to adjust the behavior of KEEPALIVE.

Receiving on SPX

Receiving channel programs are started in response to a startup request from the sending channel. To do this, a listener program has to be started to detect incoming network requests and start the associated channel.

You should use the WebSphere MQ listener.

Using the SPX listener backlog option

When receiving on SPX, a maximum number of outstanding connection requests is set. This can be considered a backlog of requests waiting on the SPX port for the listener to accept the request. The default listener backlog values are shown in Table 14.

Table 14. Default outstanding connection requests on OS/2 and Windows

Platform Default listener backlog value
OS/2 Warp 5
Windows Server 5
Windows Workstation 5

If the backlog reaches the values in Table 14, the reason code, MQRC_Q_MGR_NOT_AVAILABLE is received when trying to connect to the queue manager using MQCONN or MQCONNX. If this happens, it is possible to try to connect again.

However, to avoid this error, you can add an entry in the qm.ini file or in the registry for Windows:

SPX:
ListenerBacklog = n

This overrides the default maximum number of outstanding requests (see Table 14) for the SPX listener.

Note:
Some operating systems support a larger value than the default. If necessary, this can be used to avoid reaching the connection limit.

To run the listener with the backlog option switched on, use the RUNMQLSR -B command. For information about the RUNMQLSR command, see the WebSphere MQ System Administration Guide book.

Using the WebSphere MQ listener

To run the Listener supplied with WebSphere MQ, that starts new channels as threads, use the RUNMQLSR command. For example:

RUNMQLSR -t spx [-m QMNAME] [-x 5E87]

The square brackets indicate optional parameters; QMNAME is not required for the default queue manager, and the socket number is not required if you are using the default (5E86).

For the best performance, run the WebSphere MQ listener as a trusted application as described in Running channels and listeners as trusted applications. See the WebSphere MQ Application Programming Guide for information about trusted applications.

You can stop all WebSphere MQ listeners running on a queue manager that is inactive, using the command:

ENDMQLSR [-m QMNAME]

If you do not specify a queue manager name, the default queue manager is assumed.

IPX/SPX parameters

In most cases the default settings for the IPX/SPX parameters will suit your needs. However, you may need to modify some of them in your environment to tune its use for WebSphere MQ. The actual parameters and the method of changing them varies according to the platform and provider of SPX communications support. The following sections describe some of these parameters, particularly those that may influence the operation of WebSphere MQ channels and client connections.

OS/2

Please refer to the Novell Client for OS/2 documentation for full details of the use and setting of NET.CFG parameters.

The following IPX/SPX parameters can be added to the Novell NET.CFG file, and can affect WebSphere MQ SPX channels and client connections.

IPX

sockets (range = 9 - 128, default 64)
This specifies the total number of IPX sockets available. WebSphere MQ channels use this resource, so depending on the number of channels and the requirements of other IPX/SPX applications, you may need to increase this value.

SPX

sessions (default 16)
This specifies the total number of simultaneous SPX connections. Each WebSphere MQ channel or client connection uses one session. You may need to increase this value depending on the number of WebSphere MQ channels or client connections you need to run.

retry count (default = 12)
This controls the number of times an SPX session will resend unacknowledged packets. WebSphere MQ does not override this value.

verify timeout, listen timeout, and abort timeout (milliseconds)
These timeouts adjust the 'Keepalive' behavior. If an SPX sending end does not receive anything within the 'verify timeout' period, it sends a packet to the receiving end. It then waits for the duration of the 'listen timeout' for a response. If it still does not receive a response, it sends another packet and expects a response within the 'abort timeout' period.

DOS and Windows 3.1 client

Please refer to the Novell Client for DOS and MS Windows documentation for full details of the use and setting of NET.CFG parameters.

The following IPX/SPX parameters can be added to the Novell NET.CFG file, and can affect WebSphere MQ SPX channels and client connections.

IPX

sockets (default = 20)
This specifies the total number of IPX sockets available. WebSphere MQ channels use this resource, so depending on the number of channels and the requirements of other IPX/SPX applications, you may need to increase this value.

retry count
This controls the number of times unacknowledged packets will be resent. WebSphere MQ does not override this value.

SPX

connections (default 15)
This specifies the total number of simultaneous SPX connections. Each WebSphere MQ channel or client connection uses one session. You may need to increase this value depending on the number of WebSphere MQ channels or client connections you need to run.

Windows systems

Please refer to the Microsoft documentation for full details of the use and setting of the NWLink IPX and SPX parameters. The IPX/SPX parameters are in the following paths in the registry:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Service\NWLinkSPX\Parameters
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Service\NWLinkIPX\Parameters

Windows 95 and Windows 98

Please refer to the Microsoft documentation for full details of the use and setting of the IPX and SPX parameters. You access them by selecting Network option in the control panel, then double-clicking on IPX/SPX Compatible Transport.



© IBM Corporation 2002. All Rights Reserved