Server with an affinity for a specific transport provider

When the service is related to the internal functioning of the transport provider (for example, Telnet, OMPROUTE, OSNMPD, and the Netstat command), there must be an explicit binding of the server application to the chosen transport provider. (See Figure 1.) There must also be a way to specify the single transport to be chosen.

Figure 1. Server with affinity for a specific transport provider
Example of a server with affinity for a specific transport provider

With the exception of applications that use the socket API provided by TCP/IP, other IBM-supplied applications that use the z/OS® UNIX socket API and that must bind to a specific transport provider use the z/OS UNIX socket call setibmopt() (see z/OS XL C/C++ Runtime Library Reference) to specify which TCP they have chosen. A C function __iptcpn(), described in the z/OS XL C/C++ Runtime Library Reference, enables the application to search the TCPIP.DATA file to find the name of the specific TCP/IP. (See Figure 2.) An application that uses the z/OS Language Environment® run time can also establish stack affinity by setting the environment variable _BPXK_SETIBMOPT_TRANSPORT.

Figure 2. Example of binding an application to a specific transport provider
Example of an application with socket bound to a specific transport provider