Version 4.2.5
 —  Database Management System Interfaces  —

Monitor Client NATMOPI

This document covers the following topics:


Introduction

The Monitor Client NATMOPI is a character-based command interface for monitoring the various types of servers that are provided in a mainframe Natural environment. Each of these servers has its own set of monitor commands which is described in the corresponding server documentation. In addition, a set of directory commands is available which can be used independent of the server type. One NATMOPI can be used to monitor different server types.

Top of page

Command Interface Syntax

Basically the syntax of the command interface consists of a list of options where each option can/must have a value. For example:

-s <server-id> -c help

where -s and -c are options and <server-id> and help are the option values.

It is possible to specify multiple options, but each option can have only one value assigned.

The command options available are listed below.

Top of page

Command Options Available

Words enclosed in <> are user supplied values.

Command Option Action
-s <server-id> Specify a server ID for sending a monitor command. If the server ID is not unique in the server directory, NATMOPI prompts the user to select a server.
-c <monitor command> Specify a monitor command to be sent to the server ID defined with the -s option
-d <directory command> Specify a directory command to be executed.
-a Suppress prompting for ambiguous server ID. Process all servers which apply to the specified server ID.
-h Print NATMOPI help.

Top of page

Monitor Commands

These are commands that are sent to a server for execution. The monitor commands available depend on the type of server, however, each server is able to support at least the commands ping, terminate and help.

For further commands, refer to Operating the Natural SQL Gateway Server where the corresponding server commands are described.

Top of page

Directory Commands

Directory commands are not executed by a server, but directly by the monitor client NATMOPI.

You can use the directory commands to browse through the existing server entries and to remove stuck entries.

The following directory commands are available. Words enclosed in <> are user supplied values and words enclosed in straight brackets [] are optional.

Directory Command Action
ls [<server-id>] List all servers from the server directory that apply to the specified server ID. The server list is in short form.
ll [<server-id>] Same as ls, but the server list contains extended server information.
rs [<server-id>] Remove server entries from server directory.

Note:
If you remove the entry of an active server, you will loose the ability to monitor this server process.

cl [<server-id>] Clean up server directory. This command pings the specified server. If the server does not respond, its entry will be removed from the directory.
ds Dump the content of the server directory.
lm List pending IPC messages.

Top of page

Command Examples

natmopi -dls
List all servers registered in the directory in short format.
natmopi -dcl TST -ls TST
Clean up all servers with ID TST* (ping server and remove it, if it does not respond), and list all servers with ID TST* after cleanup.
natmopi -sSRV1 -cping -sSRV2 -sSRV3 -cterminate
Send command ping to SRV1. Send command terminate to SRV2 and SRV3.
natmopi -cterminate -sSRV1 -cping -sSRV2 -sSRV3
Is equivalent to the previous example. That is, NATMOPI sends the command following the -s option to the server. If no -c option follows the -s option, the first -c option from the command line will be used.
natmopi -sSRV1 -cterminate -a
Send command terminate to SRV1. If SRV1 is ambiguous in the server directory, send the command to all SRV1 servers without prompting for selection.

Top of page