jpctool alarm bind
- Organization of this page
Format
jpctool alarm bind -key service-key -table alarm-table-name -id service-ID [-add] [-wait number-of-seconds]
Function
The jpctool alarm bind command binds a defined alarm table to an agent.
If this command is executed on an agent to which an alarm table has already been bound, the alarm table specified in this command is bound to the agent.
In some cases, the alarm table to be bound includes alarms indicating state changes for individual instances. In such cases, the Agent Collector service with the service ID you specify must consist of a PFM - Agent and PFM - Base pair that supports the notification of state changes for each instance. If the Agent Collector service does not consist of a PFM - Agent and PFM - Base pair that supports the notification of state changes for each instance, a KAVE05969-E message will be output.
If multiple service IDs are specified, even if the bind processing for a service terminates abnormally, the alarm table bind processing will continue for other services. If the bind processing for all those services results in errors, this command will return the return value that indicates the last error.
Hosts that can execute the command
PFM - Manager
Execution permission
- In Windows:
-
User with Administrators permissions
- In UNIX:
-
User with root user permissions
Installation directory
- In Windows:
installation-folder\tools\
- In UNIX:
/opt/jp1pc/tools/
Arguments
-key service-key
Specifies the service key of the PFM - Agent or PFM - RM to which the alarm table is to be bound. A product name can also be specified when the product name display functionality is enabled. You can specify only the service key of PFM - Agent or PFM - RM here. For details about the service key of the PFM - Agent or PFM - RM, see the naming rules described in the appendix of the JP1/Performance Management Planning and Configuration Guide.
-table alarm-table-name
Specifies the name of the alarm table that is to be bound.
For alarm-table-name, specify a string of 1 to 64 bytes long, consisting of double-byte characters, single-byte alphanumeric characters, single-byte spaces, and the following single-byte symbols:
% - ( ) _ . / @ [ ]
If the value contains a space, enclose the entire value in double quotation marks ("). If the value contains a defined symbol, specify an escape character if necessary.
Wildcard characters cannot be used.
-id service-ID
Specifies the service ID for the agent to which the alarm table is to be bound. For service-ID, specify a string from 1 to 258 bytes. To bind the alarm table to a PFM - RM monitoring target, specify the service ID of the remote agent or group agent corresponding to the monitoring target. If the service ID of the Remote Monitor Collector service is specified, an error will occur.
You can use wildcard characters to specify multiple service IDs. In this case, even when an error occurs for a given Agent Collector service, remote agent, or group agent, processing will continue for the remaining Agent Collector services, remote agents, or group agents. If processing on multiple Agent Collector services, remote agents, or group agents results in an error, the command returns the value for the last error that occurred.
-add
Binds an additional alarm table, for version 09-00 or later. If this is executed for an agent for which another alarm table is already bound, the additional specified alarm table is bound. If this is executed for an agent for which the same alarm table is already bound, nothing will happen. An error will also occur if the functionality for binding multiple alarm tables is not enabled, or if, as a result of the additional binding, the number of tables bound exceeds 50 (the maximum number of bindable alarm tables).
If the specified alarm table is already bound for all specified service IDs, the KAVE05353-W message is displayed, and the command terminates normally.
-wait number-of-seconds
Specifies the maximum wait period (in seconds) applied when a command that cannot be executed with this command is running. When the setting to suspend execution of alarm commands (Alarm Command Wait Mode) is enabled in the startup information file (jpccomm.ini), if you want to specify a wait period (in seconds) separately from the wait period specified in the jpccomm.ini file, specify a value in the range from 1 to 3,600 for this option.
If you omit the option, this command runs with the wait period (in seconds) specified in the jpccomm.ini file.
For details on the commands that cannot be executed with this command, see Commands that cannot be executed with alarm commands. For details on the jpccomm.ini file and Alarm Command Wait Mode, see Startup information file (jpccomm.ini).
Notes
-
This command cannot be executed concurrently.
-
This command updates a specified bind setting on PFM - Manager. When the bind setting is updated, the PFM - Manager service performs alarm table setting on the relevant running agent.
Therefore, if the alarm table setting on the agent fails because of a failure in agent communication or for other reasons even when this command has been executed successfully, a KAVE00448-E message is output to the common message log.
-
For details about the service ID, see the naming rules described in the appendix of the JP1/Performance Management Planning and Configuration Guide.
-
This command cannot be executed if any of the Name Server, Master Manager, and View Server services is stopped.
-
If the PFM - Agent or PFM - RM data model version number is smaller than the alarm table data model version number, the alarm table cannot be bound to the PFM - Agent or PFM - RM. If an unsupported alarm table data model version is specified, the command terminates with an error.
-
If arguments of a jpctool alarm command include double-byte characters, the LANG environment variable for the shell that is used to execute the command must be set to Japanese (Shift JIS, EUC, or UTF-8) or Simplified Chinese (GB18030 or UTF-8). In addition, the value of that LANG environment variable must be the same as the value of the LANG environment variable that is loaded when PFM - Manager starts. Before you execute this command, make sure that the LANG environment variable settings of the shell and PFM - Manager match.
-
If PFM - Manager is installed on a logical host, execute the command on the executing node.
-
When performing multiple monitoring, you cannot execute this command from the secondary PFM - Manager host.
-
It might take several tens of seconds until this command takes effect on the agent after this command has terminated.
-
For notes on successive stopping of the monitoring using alarms and the monitoring target system, see Notes on execution of jpctool alarm commands.
Return values
0 |
The command terminated normally. |
1 |
An argument specification is invalid. |
2 |
The user does not have execution permission for the command. |
3 |
At least one of the Name Server, Master Manager, and View Server services is not running, or there is no PFM - Agent or PFM - RM that corresponds to the specified service ID. |
4 |
The startup stop command or another setup command was executed on the same machine. |
5 |
The command was executed on a host that is not the PFM - Manager host. Alternatively, the agent to which alarms are to be bound has not been set up. Or else, an attempt was made to execute the command from the secondary PFM - Manager host when multiple monitoring is performed. |
6 |
The specified alarm table was not found, or the data model version of the specified alarm table cannot be bound. The maximum number of alarm tables that can be bound was exceeded (09-00 or later). |
11 |
The user canceled the processing. |
12 |
The functionality for binding multiple alarm tables has not been enabled (09-00 or later). |
13 |
The agent to which an alarm table is to be bound does not support the notification of state changes for each instance. |
100 |
The Performance Management environment is invalid. |
200 |
A memory shortage occurred. |
210 |
A disk space shortage occurred. |
211 |
A file or directory cannot be accessed. |
222 |
A communication error occurred. |
223 |
Communication processing resulted in a timeout. |
255 |
An unexpected error occurred. |
Usage example 1
This example binds the PFM UNIX Solution Alarms 8.00 monitoring template from PFM - Agent for Platform (UNIX), to the agent with host name host01 (service ID: UA1host01).
jpctool alarm bind -key UNIX -table "PFM UNIX Solution Alarms 8.00" -id UA1host01
Usage example 2
This example binds the alarmtable1 alarm table of PFM - Agent for Platform (UNIX) to all agents whose host name beings with host:
jpctool alarm bind -key UNIX -table alarmtable1 -id "UA1host*"
Usage example 3
This example binds the additional alarm table alarmtable3 to the service UA1hostA.
jpctool alarm bind -key UNIX -table alarmtable3 -id UA1hostA -add