z/OS Communications Server: IP Programmer's Guide and Reference
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


SNA network monitoring NMI: Communicating with the server

z/OS Communications Server: IP Programmer's Guide and Reference
SC27-3659-02

Applications that need to communicate with the VTAM® AF_UNIX server can do so by creating an AF_UNIX stream socket using either the Language Environment® C/C++ API or UNIX System Services BPX callable services. The VTAM server provides a well-known AF_UNIX stream socket with a socket path name of /var/sock/SNAMGMT that applications can use in connecting to the server.

Perform the following steps to communicate with the VTAM server:
  1. Open an AF_UNIX socket.
  2. Connect to the VTAM server using the socket path name /var/sock/SNAMGMT.
  3. Read any data on the socket.
  4. Build the NMI request packet.
  5. Send the packet to the VTAM server.
  6. Read the reply.
    • If the reply is a termination record, perform any application cleanup.
    • If the reply is a response to the request, process the response.
  7. Repeat the process beginning with step 4 or close the connection.
Tips:
  • When an application establishes a successful connection to the VTAM server, the server responds by sending an initialization record to the application. The application must read this record before it can start processing request responses.
  • When VTAM needs to close the connection with the application, it attempts to send a termination record to the application before closing the connection.

    VTAM closes the connection when VTAM terminates, when the interface is disabled by an operator, or when there are severe formatting errors in the data requests sent by the application to the VTAM server.

  • Both the initialization and termination records conform in structure to the solicited response records sent by VTAM to the application; see SNA network monitoring NMI request/response format for details.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014