HP Systems Insight Manager 5.
© Copyright 2003-2009 Hewlett-Packard Development Company, L.P. Legal notices The information contained herein is subject to change without notice. The only warranties for HP products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. HP shall not be liable for technical or editorial errors or omissions contained herein.
Table of Contents 1 About this guide.........................................................................................9 Intended audience..................................................................................................................................9 Prerequisites...........................................................................................................................................9 Related documentation.............................................................
Synopsis.........................................................................................................................................25 Description......................................................................................................................................25 Options..........................................................................................................................................26 Return values.......................................................
Limitations.......................................................................................................................................43 Examples........................................................................................................................................43 mxmib.................................................................................................................................................44 Synopsis.......................................................
See also.........................................................................................................................................75 mxreport..............................................................................................................................................75 Synopsis.........................................................................................................................................75 Description....................................................
Synopsis.........................................................................................................................................97 Description......................................................................................................................................98 XML file support...............................................................................................................................99 Options...............................................................
List of Tables 2-1 HP SIM CLI commands....................................................................................................................
1 About this guide This guide provides information about: • Logging in to the command line interface (CLI) • Logging out of the CLI • CLI command reference NOTE: In this guide, the terms node and node group are the same as system and system group, which are also used in the HP Systems Insight Manager (HP SIM) documentation set.
• Error messages • Operating system type and revision level • Detailed questions For continuous quality improvement, calls may be recorded or monitored. Other HP web sites For additional information, see the following HP web sites: 10 • HP Systems Insight Manager web site at http://www.hp.com/go/hpsim/ for general product information and links to software downloads, documentation, and troubleshooting information. • HP Technical Documentation web site at http://www.docs.hp.
2 About the HP SIM Command Line Interface Introduction HP SIM provides a command line interface (CLI) in addition to the graphical user interface (GUI). Many functions available in the GUI are also available in the CLI. Commands HP SIM commands are installed in the following locations on the central management server (CMS): • HP-UX and Linux: /opt/mx/bin/ • Windows: C:\Program Files\HP\Systems Insight Manager\bin\ NOTE: The Windows path varies if HP SIM is not installed in the default location.
NOTE: The manpage section numbers for CLI command line usage manpages are different for each operating system (OS). The CLI command line usage manpage section number is 1M for HP-UX and Windows, and 8 for Linux. The CLI XML usage manpage section number is 4 for all operating systems.
Command Functionality Available manpages mxngroup Allows you to create, modify, remove, and mxngroup(1M, 8), mxngroup(4) list system groups in HP SIM. mxnode Adds, modifies, identifies, removes, or lists mxnode(1M, 8), mxnode(4) systems in HP SIM. mxnodesecurity Adds, modifies, or removes security credentials for sign-in, SNMP, SSH, WS-MAN, and WBEM protocols. mxoracleconfig Allows you to configure HP SIM to use an mxoracleconfig(1M, 8) Oracle database. This command does not initiate the database.
Remotely using an SSH client NOTE: The preferred way to log in remotely is to use an SSH client. Telnet and rlogin work, but neither provides a secure connection. 1. 2. Open an SSH client application on any network client. Log in to the CMS through the SSH client software, using a valid user name and password. HP SIM grants authorizations based on your OS login. Entering commands Application requirement Most of the commands in the CLI work only when HP SIM is running.
• mxuser • mxwbemsub On a Windows CMS, if you are not a member of the local Administrators group, add the options --user username and --pass password when running any of the listed commands. For example, to list information about one or more authorizations in compact or table form, enter mxauth [-lt] --user username --pass password.
3 Command descriptions This chapter describes the commands in the HP SIM CLI. The commands in this chapter use the following conventions: • Optional items are enclosed in square brackets [ ]. • Required parameters are in italics. • The | character indicates a choice between options. • Curly brackets { } indicate an option that requires one or more values. mcompile Compiles SNMP mib files into intermediate format (.cfg) files.
Processing import file: RFC1155-SMI.mib Processing import file: RFC1155-SMI.mib Processing import file: rfc1213.mib Processing import file: RFC-1212.mib Processing import file: RFC-1215.mib Processing import file: rfc1213.mib Mib Compilation completed successfully. See also mxmib(1) mxagentconfig Configures the agent to work with a CMS.
-o host|user Specify whether to configure the managed node with SSH host-based authentication or user key-based authentication. If this option is not specified, the default is host-based authentication. -u login Enter the user name to enable SSH execution. -p password Enter the password of the specified user on the managed node. If the password contains special characters that the shell might interpret, for example, $ or &, enclose the string in quotation marks.
Linux mxexec(8) mxauth Adds, removes, or lists authorizations in HP SIM. Synopsis mxauth -a|r -u username -R toolboxname -n nodename mxauth -a|r -u username -R toolboxname -g groupname mxauth -a|r -f filename mxauth [-l t] mxauth -l f [-b encoding ] Description mxauth is used to manage authorizations. These associations between users, toolboxes, and nodes or node groups can be added or removed only by full configuration rights users. Any HP SIM user can list authorizations.
In the simple listing format, the Auto Update state for a node group authorization is appended and displayed as :Auto if Auto Update is enabled, or :Manual if you must manually click the Update button to update an authorization. For example: user:toolboxname:g:groupname:Auto user:toolboxname:g:groupname:Manual In the tabular listing format, a new AUTO column is included. The Auto Update state for a node group authorization is Auto if Auto Update is enabled. If Auto Update is disabled, the column is blank.
-b encoding Specify the character encoding for the XML file. This is used with -l f. -u username Specify the user for the authorization. This option does not support user groups. -R toolboxname Specify the toolbox name for the authorization. Enclose toolbox names with embedded spaces in quotation marks. -n nodename Specify the node name for the authorization. The wildcard character (*) is supported for nodename. -g groupname Specify the node group name for the authorization.
The first section in my_auths.xml gives user1 the toolbox webadmin on node1.corp.com. The second section gives user2 the toolbox operator on node1.corp.com. The third section gives user3 the toolbox dbadmin on node2.corp.com.
Limitations • This command can only be run on the CMS. • It is not an error to remove an authorization that does not exist. This operation results in a return value of 0. • An authorization is nonexistent if all of its attributes (user name, toolbox name, node or node group name) are valid HP SIM objects, but they are not associated as an authorization. • It is not an error to add an authorization that already exists in HP SIM. This operation results in a return value of 0.
-t [ -f filespec ] Import a trusted certificate from the specified file -i Import a signed server certificate from the standard input. -t Import a trusted certificate from the standard input. -r alias|CN Remove the certificate with the specified alias or certificate name. -ln [alias|CN] List the certificate with the specified alias or certificate name in the short format. -ld [alias|CN] List the certificate with the specified alias or certificate name in detailed format.
Example 3 To list the certificates in the keystore (short format), enter mxcert -ln. Example 4 To list the certificates in the keystore (long format), enter mxcert -ld. Note: The mxcert output includes the alternative names only for the -ld option. mxcollection Adds, lists, modifies, or removes collections and members of collections in HP SIM.
• mxcollection -d existcollname This command allows you to delete collections. When deleting a collection, you must be the collection owner or a full configuration rights user. If you specify a nonexistent collection name, HP SIM notifies you that it cannot delete the collection. Collections cannot be deleted if they are used by tasks, reports, authorizations, or the banner status area. Collections with members cannot be deleted.
-f filename Specify the file name and path of a collection definition file. This option is used with -a, -a mem, -m mem and -r mem. -lf existcollname Write a complete definition of the specified collection to stdout in XML format. -ln Display the names of all collections in a hierarchical tree. -b encoding Specify the character encoding for the XML file. This is used with -lf. -mv existcollname Move an existing collection from one parent collection to another.
Value Meaning 2 Command line syntax error. -1 An error occurred during operation. Examples Example 1 To add the collections cupertino site and building 45, each with two members, enter: mxcollection -a -f my_collections.xml . The contents of my_collections.xml might look like: PAGE 29mxconfigrepo -a mxconfigrepo -r Description mxconfigrepo allows you to recreate the database (init), merge in updated SQL files for an upgrade, or search for corrupted records or database inconsistencies. The tool will search the database for any known issues and verify or fix the database to enable HP SIM to start without requiring a re-install. • mxconfigrepo –c This command allows you to detect and log errors. Run this command from the lbin directory.
Description mxexec executes an HP SIM tool with associated arguments on specific managed nodes and node groups. A tool and its arguments, specified to run on one or more nodes, is called a task. An instance of the task running at a particular time is called a job. • mxexec -t toolname [-A argvalue... ] [-h|-O filename|-o directory ] [-n target...|-q queryname... ] This command allows you to run HP SIM tools.
user-specified The target list specified in the tool definition file is used as the target list. The value of defTargets is ignored if a target list is specified on the command line. Authorization for each target node is verified before a tool is executed. Target execution environment When a job is executing on a node, its environment contains information gathered on the CMS and sent to the HP SIM agent on the target nodes.
and after it exits, it gathers up the stdout, stderr, and exit code of the process to be returned to the DTF. The results are returned to the DTF and the connection is closed. • Complete. The job is finished and any available results are sent to the user interface and the log file. Task termination Tasks can be terminated if they have not reached the Running tool state. Termination has no effect on target nodes in the Running tool or Complete state.
For security reasons HP SIM prohibits the following characters from being entered as part of an argvalue: grave accents (`), semicolon (;), ampersand (&), bar (|), left parenthesis ('('), hash mark (#), greater than sign (>), less than sign (<), and the new line character. -h Suppress job information headers and send the job output directly to stdout or stderr as appropriate. Exception information is sent to stderr.
List jobs in long format, including the task name, job ID, user, toolname, and state for each specified job ID, or for all jobs if no job IDs are specified. Only one -l option can be specified. External influences The language setting of the command shell in which you execute this command is used as the preferred language that you want the command line tool to execute with on the target nodes.
Running tool bdf with job id 143 Job ID : 4 Tool Name : bdf Job State : Some Failures User Name : root Start Time : Wednesday, March 15, 2000 3:18:46 PM MST End Time : Wednesday, March 15, 2000 3:18:47 PM MST Elapsed Time : 500 milliseconds Node : db1.myco.
Exit Code : 1 STDOUT : ======= 09/15/99 16:19:56 MDT BEGIN swinstall SESSION (non-interactive) * Session started for user "bozo@machine2.myco.com". * Beginning Selection * Target connection failed for "depotsys.myco.com:/patches/PHCO_98765". * Selection had errors. ======= 09/15/99 16:19:56 MDT END swinstall SESSION (non- interactive) STDERR : ERROR: More information may be found in the daemon logfile on this target (default location is machine2.myco.com:/var/adm/sw/swagentd.log). Node : machine3.myco.
-h Display the hostname of the server on which the database is installed. -p Display the TCP/IP port used to connect to the database on the database server. -d Display the name of the database/instance used by HP SIM. -u Display the username used by HP SIM to log in to the database. -t Display the database type, for example, SQLServer, PostgreSQL, or Oracle. -r Display the path to the PostgreSQL program directory (HP-UX only). -b Display the path to the PostgreSQL program directory (HP-UX only).
Options -k Display the resolved local host name. -i Display the IP address and DNS name of the CMS. -n Display information for the specified host. Return values Value Meaning 0 Successful completion. >0 An error occurred during operation. Example To view information for the host rose.co.com, enter mxgethostname -n rose.co.com. mxglobalprotocolsettings Manages global protocol settings in HP SIM. Synopsis mxglobalprotocolsettings -s [-f file-name|- ] mxglobalprotocolsettings -s {setting=value}...
Return values Value Meaning 0 Successful completion. 2 Command line syntax error. -1 An error occurred during operation. Examples Example 1 To list the global protocol settings in detailed format, enter mxglobalprotocolsettings -ld.
Description mxglobalsettings manages the settings in globalsettings.props. Changes are effective immediately, and do not require a restart of HP SIM. When you make a change with this command, the globalsettings.props file is updated automatically. Options -s {setting=value}... Set one or more global settings on the command line. The setting is a key name in the globalsettings.props file, and the value is the value to assign to that setting.
Synopsis mxinitconfig -a mxinitconfig -r mxinitconfig -l Description mxinitconfig allows you to perform the initial HP SIM configuration, remove the HP SIM configuration information, or list the current configuration status. If no options are entered, the configuration status is listed ( -l ). When HP SIM is running, you can use -l to list the configuration status, but you cannot run mxinitconfig -a or mxinitconfig -r. • mxinitconfig -a This command performs the initial configuration procedure.
Windows • \HP SIM directory\logs\initconfig.log • \HP SIM directory\config\initconfig.properties Examples Example 1 To configure the server, enter mxinitconfig -a. Example 2 To view the current configuration status, enter mxinitconfig -l. mxlog Logs or prints a log entry.
Specify the name of the object or application that is making the logging call. You must specify a value if -n is used. If -n is not used, the default is NONE (which appears as a "<>" string). The value must be a string, and if it includes spaces, it must be enclosed in double quotation marks. If this option is not specified, the default is NONE. -o object_type Specify the type of object or application making this logging call. You must specify a value if -o is used.
Example 2 To preview a default entry with a simple message, enter: mxlog -p -m "This is a test". The output will be: 2005-08-08 13:13:07 MDT APP root START <> NONE START SUCCESS SUMMARY This is a test. mxmib Adds, deletes, processes a list of mibs, list registered mibs, and lists traps for a specific registered mib.
Examples Example 1 To view the list of registered mibs, enter mxmib -l. Example 2 To register the mib testmib.cfg, enter mxmib -a testmib.cfg. Example 3 To update a MIB file in HP SIM, complete the following steps: 1. Download the new mib and copy it into the mibs directory. 2. Run mcompile to update the existing .cfg file. NOTE: 3. If the existing .cfg file had any customizations, these must be reapplied. Run mxmib -a updatedfile.cfg to update the MIB data in the HP SIM database.
These commands allow you to modify system group information. As with adding system groups, the group can be specified on the command line or in an XML file in the format described in the mxngroup(4) manpage. When you modify a system group, HP SIM updates the authorization information for any authorizations associated with the modified system group. • mxngroup -r -g groupname mxngroup -r -f filename These commands allow you to remove a system group.
Add a group. -m Modify a group. -r Remove a group. -l d Display a detailed screen-viewable list of system group information. -l f Display a file-formatted list of system group information (see mxngroup(4) ). -l m Display the member systems of the system group. -l n Display the names of the system groups. -f filename Specify the path and name of the input file for an add, modify, or remove operation. -g groupname Specify the name of the group to be added, modified, removed, or listed.
Return values Value Meaning 0 Successful completion. 2 Command line syntax error. 3 Nonexistent system or system group error. 5 Duplicate name. 21 Invalid name. 50 Unauthorized user. 102 Database error. 222 The CMS is not initialized. 249 Unable to connect to the session manager. 250 Remote exception. Examples Example 1 To create the system group group1 containing systems systema, systemb, and systemc, enter mxngroup -a -g group1 -d "Example system group" -n systema systemb systemc.
Example 9 To use the XML file test2.xml to define a system group named group1 with a description and the member systems, system1.corp.com and system2.corp.com, with auto-update enabled, enter mxngroup -a -f test2.xml The test2.xml file might look like: This is group1. PAGE 50XML format for input files. To view an example, enter mxnode -lf mysystem, and substitute one of your system names for mysystem . Only full configuration rights users can add, modify or remove systems. Any user can view system information.
Route (MRO), which specifies the routing information to an associated MAO, which may reside on this system or another system. One or more MPOs can reside on a system. • -lf provides an XML list of systems. Optionally, you can specify the character encoding of the XML file. The value for the character encoding must match a valid character encoding. If no encoding is specified, the system attempts to write the file in the encoding currently defined on the system. See http://www.iana.
• Asset Number . The asset number of the system. • OS Description . The description of the system's OS. • Contact . The person to contact if system maintenance is needed. • Location . The physical location of the system. • AgentUUID . The unique identifier value from the SNMP agent installed on the system. On Proliant servers, this is the cpqHoGUID MIB value from the Proliant Insight Agent. For certain switches, this value is the same as the switch serial number from the SNMP agent.
NOTE: The attribute name in parentheses is the actual attribute name that would be used in the mxnode XML file. Software attributes • Preferred Node Name (PreferredNodeName) . An alternate system/node name of your choosing which can make it easier for you to identify, find, or organize systems/nodes in the database. • System Description (SystemDescription) . This attribute describes the device. Any displayable text can be used as a value for this attribute. • Asset Number (AssetNumber) .
GUI name mxnode attribute name Printer Printer Switch Switch Hub Hub Remote Access Device RAS Unknown Unknown Management Processor MgmtProc Tape Library TapeLibrary Shared Resource Domain SRD Resource Partition RESPAR Application Application • 54 Device Subtype (DeviceSubType) . The subtype of the device within the major type. Only the following predefined valid device subtypes can be used as values for a device subtype.
GUI name mxnode attribute name HP Virtual Partition Server vParMonitor Storage Essentials Managed StorageEssentials HP 9000 Superdome HP9000Superdome HP Integrity HPIntegrity HP Alpha Station HPAlphaStation Virtual Machine Host VMHost HP Serviceguard HP Serviceguard High Availability Cluster HighAvailabilityCluster nPar nPar HP Deskpro HPDeskpro HP Integrity Superdome HPSuperdome MSCS MSCS HP Integrity Workstation HPIntegrityWorkStation High Availability Array HighAvailabilityAr
Warranty data can be added or modified. MPO or Contract and Warranty data for a system can be added, modified or removed only through the use of an external XML file. This data cannot be specified directly on the command line for add, modify or remove operations. -f filename Specify a filename containing systems to be added, modified, or removed. The contents and format of the xml file are shown in the Examples section. See mxnode(4) for additional information about using XML input files with mxnode.
Return values Value Meaning 0 Successful completion. 2 Command line syntax error. 3 Undefined system error. 5 Duplicate system error. 6 Nonexistent user error. 7 System is locked error. 8 Nonexistent system group error. 21 Invalid name. 31 Unknown network host. 33 Missing mxnode plug-in identification collector. 38 Undefined node name. 50 Unauthorized user. 102 Database error. 221 Authentication failure. 222 The CMS is not initialized. 224 System installation error.
IP addresses: 192.1.2.3 OS name: HPUX OS revision: 11.00 OS revision text: 11.00 OS vendor: HP Protocols: SNMP:1.0 GUID: 00000000864162de0f07e31d86c00000 Hardware device ID: 00000000864162de0f07e31d86b00000 Device type: UnixWorkstation Device subtype: HP9000 Model: 9000/785 Added by: root Added on: Sep 24, 2002 4:15:46 PM Monitoring: Not suspended OS description: Preferred node name: LABabc System description: Hardware: x86 Family Contact: ph: 555-1234 Location: Bldg 6,Room123 UUID: n...
One method for modifying a system is to use the mxnode -lf > filename command to output the XML data to an external output file. The output file can then be edited to change or add attributes that need to be modified or locked. After editing the file, modify the system by entering mxnode -m -f filename and specifying the edited file as the input file. The sample XML includes the method for locking the lockable attributes.
L your data here L your data here L your data here L your data here L your data here L your data here OS name str OS vendor info
An MRO provides the information required to access an agent (MAO). An MRO always has an associated MAO included in its overall information. An MRO on a node points to an MAO residing on the same node, or another node. The following sample XML list shows a node with one MAO and one MRO residing on the node. A node's MPOs are included in the XML within the block.
root .... nn...nn nnnnnnnnnnn nn...nn dpiwin5 WBEM_CIMOM nnnn nn.nn.nnn.
Notes • When modifying a node with the mxnode -m -f filename command, your XML file must include only the attributes you want to modify. You must always include the three attribute lock flags and set all three flags to true or false. In most cases, you will want to use the false setting so the lockable attributes will not be overwritten by the Discovery and Identification processes.
The add option lets you add a default or node credential. You can specify an input XML file that describes credentials for one or more target nodes, or you can declare credentials and (optionally) a node name on the command line. If you specify a file name on the command line, the file must be an XML file. See XML file support section and the mxnodesecurity(4) manpage for details on the required XML file format. You can also specify the credential characteristics on the command line with the node name.
XML file support This command requires the following format for XML input files: If the CMS detects a formatting error while processing an input file, it will not make any changes to the node security repository. The CMS will interrupt processing and issue an error message. See mxnodesecurity(4) for more XML usage information.
-t fc|fcd Forces the removal of the specified default or global credentials that might be currently in use by one or more nodes or systems. The fd option completely removes the default or global credential which might result in the loss of communications with the associated systems. The fcd option, copies the credential to any system(s) using the credential first, preserving communications with the systems. -n nodename Specify a node name. This should be the fully-qualified name, if available.
NOTE: A node name is not specified when adding default or global credentials. Default credential names use the format @defaultN, where N is an automatically assigned numerical indicating usage. Example 5 To add a default or global credential to the HP SIM database with a specified sign-in protocol for the node mycomputer.ak.hp.com, enter mxnodesecurity -a -p sign-in|signin -c username:password -n mycomputer.ak.hp.com.
Example 13 To list default or node WBEM credentials, enter mxnodesecurity -l -p wbem. Example 14 To list the WBEM credentials for the node mycomputer.ak.hp.com, enter mxnodesecurity -l -p wbem -n mycomputer.ak.hp.com. Limitations • This command can only be run on the CMS. • For an HP-UX or Linux CMS, this command can be run only by the root user.
-f Force re-run. Typically, mxoracleconfig should be run only once. Use the force flag if you need to re-run this command. Return values Value Meaning 0 Required configuration files were updated correctly.. -1 An error occurred during operation. See also HP-UX mxinitconfig(1M) Linux mxinitconfig(8) Example To configure HP SIM to use Oracle database hpsim50 on server oradbsrv11x with user id sim, password simpw, and the Oracle thin driver jar file ojdbc14.
Remove an existing password. -l List the passwords stored by HP SIM. -g Start the mxpassword GUI. IMPORTANT: An error might occur if you use -g in a non-graphical environment (such as a telnet session). -x key [ =value ] The key is the name of the password, and the value is the new value of the password in text format. -n Create a new server certificate. HP SIM and the System Management Homepage must not be running when you run mxpassword with the -n option.
Example 7 To add the passwords myPw1 and myPw2 with the values myPw1Value and myPw2Value, enter mxpassword -a -x myPw1=myPw1Value -x myPw2=myPw2Value. Example 8 To check if the HP SIM keystore exists, enter mxpassword -c. A typical result is Keystore exists. mxquery Adds, lists, modifies, execute, or removes queries in HP SIM. Synopsis mxquery -a -f filename [–x force] mxquery -m -f filename mxquery -r queryname... mxquery -r -f filename mxquery -e queryname [-x xml] mxquery [-l n|t] [ queryname...
• mxquery -m -f filename This command allows you to modify the definition of one or more queries. Query information is provided in a query definition file. When modifying a query, you must be the query owner or a full configuration rights user. • mxquery -r queryname mxquery -r -f filename These commands allow you to remove queries. Only a full configuration rights user or the query owner can remove a query.
Execute the specified query. -r Remove one or more queries. queryname Specify the name of the query to be removed, listed, or executed. Entering an undefined query name results in mxquery operating on zero queries and a return value of SUCCESS. Specifying an invalid query name (one that violates the rules for query names (see mxquery(4)), results in an invalid name return value.
Display the output of query execution results in xml format when used with -e. You can also use this option with force to force the addition of a query. NOTE: When duplicate options are specified, the last instance of the option is used. For example, if you enter -f file1 -f file2, mxauth uses file2. External influences For HP-UX or Linux, LANG determines the default encoding that the system will use to output XML data if no encoding is specified on the command line.
Example 9 To display the criteria names and their associated query type, enter mxquery -lcrit. Example 10 To display the operation modes associated with the criteria CriteriaByIPAddress, enter mxquery -lmode CriteriaByIPAddress. Example 11 To display the defined criteria values for the criteria CriteriaByProductType, enter mxquery -lval CriteriaByProductType. Limitations This command can only be run on the CMS.
• mxreport -r existing-report-category-name This command allows you to remove a report category. Only a full configuration rights user or the report owner can remove a report category. HP SIM notifies you if you specify a nonexistent report category name. • mxreport -c -f fully-qualified-file-name This command allows you to create a new report category. The category is defined in an XML file. You must have the REPORT_MODIFICATION_PRIVILEGE to create a new report category.
Add one or more reports specified in a report definition file. -d Remove the specified report. -r Remove the specified report category. -c -f Add the category specified in the listed file. -e Run the specified report. -S Replace the system collection in the specified report with the listed system collection. -n Indicate that a comma-separated list of system names is used with -S instead of a collection name. -E Filter the specified report by the listed query.
External influences For HP-UX or Linux, LANG determines the default encoding that the system will use to output XML data if no encoding is specified on the command line. If LANG is not specified or null, or LANG does not correspond to a recognized encoding, it defaults to C (see lang (5)). In this case, use the -b option to specify the encoding of the XML data. Return values Value Meaning 0 Successful completion. 1 Command completed with an error. 2 Specified command arguments constituted bad usage.
Example 9 To list the contents of the report category White Noise, enter mxreport -l -x category -n "White Noise". Example 10 To run a report from the Inventory category with the system collection All Servers and the event filter All Events, enter mxreport -eCat Inventory -S "All Servers" -E "All Events" -x XML.
mxstm -l [-p snmp|dmi] [-f filespec ] Description mxstm allows you to add, remove, and list system type manager rules for use with HP SIM. Options -a Add a new rule. Optionally, use -f to import one or more rules from an XML file. The XML file must be encoded in UTF-8 and must be declared with encoding="UTF-8". -r Remove an existing rule. Optionally, use -f to delete one or more rules from an XML file.
Return values Value Meaning 0 Successful completion. 2 Command line syntax error. >0 An error occurred during operation. Examples Example 1 To add a rule for a Digital LN07 printer using an XML file named printer-rule.xml, create printer-rule.xml with the following contents:
Return values Value Meaning 0 Successful completion. >0 An error occurred during operation while attempting to stop HP Systems Insight Manager. Example To stop the HP SIM daemons, enter mxstop. See also HP-UX mxstart(1M) Linux mxstart(8) mxtask Lists, executes, removes, creates tasks, or changes task ownership in HP SIM.
task information was modified, the task type, and any tool user parameters (in XML format) that might be associated with the specified tool. • mxtask -lf taskname [-b encoding ] mxtask -lf all [-b encoding ] This command lists the specified task in task-specific XML format. Output from this command is written to stdout, and can be redirected (with >) to an external file. The output file can be modified and used as the XML input file when creating a new task with -cf.
Display an XML file listing for a specified task. This output can be redirected (>) to a file and used as input to the -f option when creating a new task. For example, -lf taskname >filename. -lf all Display an xml format list of all HP SIM tasks. This output can be redirected to a file and used as input to -f when creating a new task. -r taskname Remove a specified task immediately. -rf taskxmlfile Indicates that the specified Systems Insight Manager task(s) is to be removed.
-o taskowner Specify a task owner for the new task that will be created. This optional value can be used with the create task (-c) command. If no owner is specified, the currently logged in user is assigned as the task owner. -i timefiltername Specify an existing time filter to associate with the task that will be created. This optional value can be used with the create task (-c) command. If no time filter name is specified, the new task will be created with no associated time filter.
External influences The language setting of the command shell in which you execute this command is used as the preferred language that you want the command line tool to execute with on the target nodes. If creating a scheduled task, this language is saved in the scheduled task and used each time it is executed. The same is true when modifying an existing task. If manually running a scheduled task, this language is used to override the language stored in the task for this single execution.
Example 6 To run the existing task test_task, enter mxtask -e test_task. Example 7 To change ownership for the existing task test_task to comp/test_user, enter mxtask -o test_task comp/test_user. The specified task owner must have the format MachineName/User. Example 8 To create a task named task1 with the associated query query1 and tool toolexample that already exists in the database, with the task type add, enter mxtask -c task1 -q query1 -t toolexample -w Tadd.
In this example, there are no tool (user) parameters required for the tool being specified, so -A and -f are not required. Example 15 To create task1, which runs every 7 days on Tuesday at 6:00 PM, with the associated query query1 and tool toolexample that already exists in the database, with the task type schedule, enter mxtask -c task1 -q query1 -t toolexample -w Tschedule.Idays.P7.Dtuesday.M18:00.
All required task configuration information must be specified in a predefined task-specific XML format. See the mxtask(4) manpage for a detailed description of the required XML format. The general format is shown below.
from the tool. By default, when a full configuration rights user removes the owner field, the toolbox enabled flag is set to true. A full configuration rights user can set the toolbox enabled flag to false to explicitly disable the tool in all toolboxes except All Tools. During an add operation, HP SIM adds only tools whose names do not reference existing tools. If a duplicate tool is detected, HP SIM will notify you and continue to add all non-duplicate tools.
• mxtool -lf [-b encoding ] [-c category...|-t toolname... ] This command lists the tools in an XML file. Optionally, you can specify the character encoding of the XML file. The value for the character encoding must match a valid character encoding. If no encoding is specified, the system attempts to write the file in the encoding currently defined on the system. See http://www.iana.org/assignments/character-sets for the list of valid character sets.
Specify the character encoding of an XML file when used with -lf. -x Specify an extended option value. This is used with the force keyword. force This option forces a tool into the system when used with -m -f, and specifies the forced removal of a tool when used with -r -f. NOTE: When duplicate options are specified, the last instance of the option is used. For example, if you enter -f file1 -f file2, mxauth uses file2.
See also HP-UX mxexec(1M), mxtool(4). Linux mxexec(8), mxtool(4). mxtoolbox Adds, modifies, removes, or lists toolboxes in HP SIM.
• mxtoolbox -r toolboxname This command allows a full rights user to remove a single toolbox from the database. • mxtoolbox -r -f filename This command allows a full rights user to remove multiple toolboxes based on information provided in a file. The file must be formatted in the XML format defined for toolboxes. See mxtoolbox(4) for additional information. • mxtoolbox [-l n|t] This command allows a full rights user to list HP SIM toolbox names or to view the details of all toolboxes.
Specify the toolbox enablement (t is enabled and f is disabled). -f filename Specify the filename that contains information about users to be added, modified or removed (see mxuser(4)). -l n Display a columnar list of the names of all enabled and disabled toolboxes. This produces the same result as not specifying any options. -l t Display a tabular list of toolbox attributes for all toolboxes. -lf Specify that the system should generate the toolbox information in XML format.
Examples Example 1 To add toolboxes from the file toolboxlist.xml, enter mxtoolbox -a -f toolboxlist.xml. Example 2 To disable the HP ASE toolbox, enter mxtoolbox -m "HP ASE" -e f. Example 3 To modify the toolboxes in the file toolboxlist.xml, enter mxtoolbox -m -f toolboxlist.xml. Example 4 To remove the HP ASE toolbox, enter mxtoolbox -r "HP ASE". Example 5 To remove the toolboxes in the file toolboxlist.xml, enter mxtoolbox -r -f toolboxlist.xml.
A read-only toolbox for operators Database Administrator LVM Administrator Limitations • Valid toolbox names
mxuser -r -f filename mxuser -r -gf -f filename mxuser [-l d|f|n|t] [ username... ] mxuser [-l dg|fg|ng|tg] [ usergroupname... ] mxuser -lf [-b encoding ] [ username... ] NOTE: The following commands are retained for backward compatibility.
• mxuser -r username mxuser -r -g usergroupname mxuser -r -f filename mxuser -r -gf -f filename These commands enable full rights or CMSSecurity rights users to remove specified users or user groups. This form of the command can only remove one user or group at a time. All authorizations for the specified user or group are removed. HP SIM must have at least one full configuration rights user, so the last full configuration rights user cannot be removed.
Add a user or user group. -r Remove a user or user group. -m Modify a user or user group by granting or denying privileges. Modifying a comment replaces any existing comment. -f filename Specify the XML file that contains information about users or user groups to be added, modified, or removed (see mxuser(4)). -l d Display a detailed screen-viewable list of users and user attributes. -l f Display an XML list of users and user attributes (see mxuser(4)). -l n Display a list of user names (with no details).
Specify the rights granted to a user or user group. Full configuration or CMSSecurity rights allows all CMS configuration operations. Limited configuration rights allows tool creation and all listing operations. No configuration rights allows only listing operations. +T grants full configuration rights, and -T grants limited configuration rights. NOTE: 3.0. The +T and -T options are provided for compatibility with Service Control Manager -g Specify the name of a user group to add, modify, or remove.
Example 3 To add the user group mygroup, enter mxuser -a -g mygroup. Example 4 To assign limited configuration rights to fred, enter mxuser -m fred -p limited. Example 5 To remove fred from the list of users, enter mxuser -r fred. Example 6 To add the list of users in the local file updates.xml, enter mxuser -a -f updates.xml. Example 7 To display the list of user names, enter mxuser -l. Example 8 To display a detailed screen-viewable list of the users, enter mxuser -l d.
mxwbemsub -m [ current destination ] new destination (-n nodenames|-f filename) [-t indication type ] Description mxwbemsub allows you to: • Add, delete, list, or move WBEM event subscriptions from nodes managed by the CMS. • Add or remove health lifecycle event subscriptions for HP NonStop Kernel servers.
List the WBEM subscriptions for the specified CMS. If a destination is not specified, the default is to list subscriptions to the CMS on which the command is run. -m Move WBEM subscriptions from one CMS to another. If the current CMS is not specified the default is the CMS on which the command is run. The new destination CMS is required. -n nodenames Specify a list of node names. This option is used with -a, -r, -l and -m. -f filename Specify a list of node names with a file.
Example 7 To move WBEM event subscriptions from the nodes mycomputer.ak.hp.com, and yourcomputer.ak.hp.com from the default CMS to newcms.ak.hp.com, enter mxwbemsub -m newcms.ak.hp.com -n mycomputer.ak.hp.com yourcomputer.ak.hp.com. This command moves subscriptions whose destination is the CMS on which the command is running. Example 8 To move subscriptions from the nodes mycomputer.ak.hp.com, and yourcomputer.ak.hp.com, from currentcms.ak.hp.com to newcms.ak.hp.com, enter mxwbemsub -m currentcms.ak.hp.
Index A mxwbemsub, 102 about the CLI, 11 this guide, 9 R C viewing manpages, 11 CLI command descriptions, 16 logging in on the CMS, 13 logging in remotely, 14 signing out, 15 commands install locations, 11 summary, 11 related documentation, 9 V I install location commands, 11 L logging in to the CLI on the CMS, 13 remotely, 14 M manpages viewing, 11 mcompile, 16 mxagentconfig, 17 mxauth, 19, 25 mxcert, 23 mxcollection, 25 mxconfigrepo, 28 mxexec, 29 mxgetdbinfo, 36 mxgethostname, 37 mxglobalproto