mngsvrutil (Management Server management command)

Format

mngsvrutil [-m host-name [:port-number]
       [-u management-user-id] [-p management-user-password]
       [[-o file-name] [-h] [-t target-name] [-k target-type]
       [-s] [-i monitoring-time-interval] [-l maximum-monitoring-time]
       subcommand arguments]]

Function

This command connects to Management Server to execute the operations in management domain.

This command can be used for the following functions:

Arguments

-m host-name [:port-number]
Specifies the host name and port number of Management Server.
  • host-name
    For establishing communication with the Administration Agent, specifies either its IP address in dot notation (xxx.xxx.xxx.xxx) or a host name that can be resolved. Specify each xxx as an integer in the range 0 to 255.
  • port-number
    Specifies the port number which is set for Management Server. The default value is 28080.
-u management-user-id
Specifies the management user ID that is set with the mngsvrctl setup command.
When the functionality for omitting the admin user account is enabled and if you specify the admin user ID, the functionality will be disabled. For the functionality for omitting the admin user account, see 4.1.15(3) Settings specified when the management user account is not setup in the uCosminexus Application Server System Setup and Operation Guide.
-p management-user-password
Specifies the management user password corresponding to the management user ID set with the mngsvrctl setup command.
When no password has been set, the -p option can be omitted.
When the functionality for omitting the admin user account is enabled and if you specify the admin user ID, the functionality will be disabled. For the functionality for omitting the admin user account, see 4.1.15(3) Settings specified when the management user account is not setup in the uCosminexus Application Server System Setup and Operation Guide.
-o file-name
Specifies the name of the output destination file. The specified file will be overwritten. The file name that can be specified depends on the OS under which the command is executed. If this option is omitted, the command execution results are output to the standard output.
-h
Specifies that no header is to be output.
-f output-format
Specifies the output format provided with Management Server to be connected. Management Server provides the following output format.
  • csv: CSV format (default value)
-t target-name
Specifies the name of the target (logical server or host) to which the subcommand is to be applied.
-k target-type
Specifies the type of target to which the subcommand is to be applied:
  • logicalServer: Logical server
  • host: Host
If this option is omitted or if a value other than those listed above is specified, logicalServer is assumed.
-s
Specifies to wait for completion of startup or stop of logical servers or J2EE applications.
This option is valid when start or stop is specified as the subcommand.
When this option is specified, the subcommand can be retried in order to recover from an error if an error occurs during startup or stop.
-i monitoring-time-interval
Specifies the interval (in seconds) at which monitoring for completion of startup or stop processing for logical servers or J2EE applications is to be performed, as an integer in the range 0 to 2147483647 (seconds). The default value is 3 seconds.
Note that this option also sets the interval for retrying the subcommand after an error has occurred during startup or stop processing.
-l maximum-monitoring-time
Specifies the maximum amount of time (in seconds) monitoring for completion of logical server or J2EE application startup or stop processing is to be performed, as an integer in the range 0 to 2147483647 (seconds).
If the logical servers or J2EE applications do not start or stop within the specified time limit, the command terminates abnormally. The default value is 60 seconds.
subcommand arguments
Specifies a subcommand and arguments. The values that can be specified for the subcommand and arguments depend on Management Server version.
You use the arguments to specify the logical servers or hosts that are to be the targets of the subcommand.
The following subcommands can be specified:
For details on the subcommands, see 7.3 Details of subcommands of the mngsvrutil command.

Return value

0:
The command is terminated normally.
1:
An execution error is occurred.
2:
A syntax error is occurred.

Output format

CSV format
Names and values are output delimited by a comma (,).
You can specify the -h option to suppress output of the header.

Configuration file

Client-side definition file (.mngsvrutilrc)
You can set the default values for the mngsvrutil command options.
For details, see 10.15 .mngsvrutilrc (Client-side definition file for the mngsvrutil command) in the uCosminexus Application Server Definition Reference Guide.
The table below shows the values that become valid depending on the combination of the mngsvrutil.target_kind, mngsvrutil.target_name, and mngsvrutil.target_server_name properties, which are parameters of the mngsvrutilrc command, and the -k and -t options.
No.target_kindtarget_nametarget_server_name-k-tSpecified value interpretation
1logicalServer/------logicalServer/----No server name is specified.
2logicalServer/--AB/--logicalServer/----Server whose name is A is specified.
3logicalServer/----BlogicalServer/----Server whose name is B is specified.
4logicalServer/--A/--B/--logicalServer/--CServer whose name is C is specified.
5host--------No host name is specified.
6host/------Host--No host name is specified.
7host--B----No host name is specified.
8host/----BHost--No host name is specified.
9hostAB/------Host whose name is A is specified.
10host/--A/--B/--HostCHost whose name is C is specified.
Legend:
--: No value is specified.

Client-side common definition file (mngsvrutilcl.properties)
You can set the common default values for the mngsvrutil command options.
For details, see 10.17 mngsvrutilcl.properties (Client-side common definition file for the mngsvrutil command) in the uCosminexus Application Server Definition Reference Guide.
Server-side definition file (mngsvrutil.properties)
You can modify the execution environment for the mngsvrutil command.
For details, see 10.16 mngsvrutil.properties (Server-side definition file of the mngsvrutil command) in the uCosminexus Application Server Definition Reference Guide.

Input/output examples

Settings for SNMP integration (In UNIX)

To specify settings for SNMP integration in UNIX:

  1. Install JP1/Cm2/ESA
  2. Create and edit the ~root/.mngsvrutilrc file
    • Copy the
    • /opt/Cosminexus/manager/config/templates/.mngsvrutilrc file to ~root.
      # cp /opt/Cosminexus/manager/config/templates/.mngsvrutilrc ~root/
    • Change the file permission of the ~root/.mngsvrutilrc file to 600.
      # chmod 600 ~root/.mngsvrutilrc
    • Edit the ~root/.mngsvrutilrc file.
      Use an appropriate editor to setup the following items.
      For details on each item, see 10.15 .mngsvrutilrc (Client-side definition file for the mngsvrutil command) in the uCosminexus Application Server Definition Reference Guide.
      mngsvrutil.connect.host
      mngsvrutil.connect.userid
      mngsvrutil.connect.password
      mngsvrutil.output.format=snmp
      mngsvrutil.target_name
      mngsvrutil.target_kind
  3. Setting up the JP1/Cm2/ESA environment
    Use the extended MIB object definition file for Cosminexus (/opt/Cosminexus/manager/config/ hitachi-cosmiMng-MIB#1, #2) to reconfigure the SNMP sub-agent. For reconfiguring the SNMP sub-agent, see the manual JP1/Cm2/Extensible SNMP Agent.
    #1 In reality, _V-R (version) is added after hitachi-cosmiMng-MIB (Example: hitachi-cosmiMng-MIB_2-0).
    #2 When using the extended MIB object definition file provided in Cosminexus Manager 06-00 and later versions, use hitachi-cosmiMng-MIB_V-R_forESA.
    Use the latest version of the extended MIB object definition file.

Notes