Tuesday, 30 October 2012

HP OMU 9.10 - opccfgdwn, download.dsf man pages



opccfgdwn - download configuration data from the HPOM database to flat files

opccfgdwn [ -help ] [ -silent ] [ -force ] [ -backup ] [ -anonymous ]
<specification file> <target directory>

The command opccfgdwn can be used to copy configuration data from the HPOM database to flat files. The data to be downloaded is specified in a file which is created by the user interface. The specification allows to download all data, complete entity data (such as the Node Bank) or selected entity data (such as nodes out of the Node Bank).


Options

-help
Display the usage message of opccfgdwn.
All other options and parameters are ignored.
-silent
Perform a silent download and report only warnings and errors. If not specified, verbose messages about progress are generated and written to the standard output.
-force
Overwrite existing files in the target directory.
-backup
Download data for the upload on a backup server.
By default, opccfgdwn writes the management server node address as variable into the download file. If uploaded on a backup server, the backup server will get the attributes and policy assignments of the primary manager and the primary manager will not be in the node bank. In backup server environments, it is however sometimes desired to have both management servers in the node banks of both management servers. This can be achieved by specifying the -backup option of opccfgdwn. In this case, the real node address of the primary server is downloaded and both systems will be in the node bank of the backup server with exactly the configuration they had on the primary server.
-anonymous
Node names, ip addresses and passwords are replaced with anonymized ones. To upload the configuration the first line in index file must be removed. To anonymize node names and ip addresses nodes must be selected for download otherwise the apperance of nodes in other parts of configuration data will remain original.
The process generates two additional files in <target directory>/<language_utf8>.
- private_nodes_list (used to identify real nodes, move this file to a safe location)
- nodes_list (anonymized nodes list that can be appended to /etc/hosts)
<specification file>
The name of the the file containing the download specification.
If no complete path is specified, the file is searched in the <target directory>/<language_utf8> directory.
<target directory>
The name of the directory where the file tree of downloaded data will be positioned.
If no complete path is specified, the directory is used/created in the /var/opt/OV/share/tmp/OpC_appl directory.

Data Entities

The following table lists the entities which can be downloaded and the available granularity for the data.
Node Groups
Entire Node Group Bank or selected node groups identified by their group name.
Managed Nodes
Entire Node Bank or selected nodes identified by their node name or pattern.
Node Defaults
Node default data for all or for selected platform types identified by platform selector.
Node Hierarchies
Entire Node Hierarchy Bank or selected node hierarchies identified by their name.
Message Groups
Entire Message Group Bank or selected message groups identified by their group name.
Applications
Entire Application Bank or selected application groups identified by their group name or selected applications identified by their name and application group name.
Operators
Entire Operator Bank or selected operators identified by their operator name. For each operator, it is possible to further restrict the configuration data to be downloaded: all data, operator desktop and/or responsibility and/or node layout. If the complete desktop is not to be downloaded, only selected applications (see Applications) are processed.
Categories
All or selected categories identified by their category name and instrumentation of those categories.
Policy Types
All or selected policy types identified by name or ID.
Policies
All or selected policies identified by their name/type/version combination or their ID. It is also possible to download all versions of one policy of a certain type by specifying only the name and the type of the policy.
Policy Groups
All or selected policy groups identified by their full path name.
Notification Services
All or selected notification services identified by their name.
Instruction Text Interface
All or selected instruction text interfaces identified by their name.
Administrator Configuration
The configuration data for the HPOM Administrator.
Regroup Conditions
All or selected regroup conditions identified by their description.
Database Maintenance
The database maintenance configuration data.
Management Server Configuration
The configuration data of the management server.
Trouble Ticket Configuration
The configuration data for the trouble ticket system.
Responsible Manager Configuration
The configuration data for the responsible manager. Note that for downloaded nodes, the node specific configuration file is processed, too. Also the MSI configuration and the Service Hours and Scheduled Outages Policies will be downloaded.
Executables
The directory tree of executables, starting at directory /var/opt/OV/share/databases/OpC/mgd_node/customer.
Message Forwarding Manager Configuration
The configuration data for the message forwarding manager.
Selective Distribution Configuration
The configuration data for the selective distribution.
Service Navigator Configuration
The configuration data for the Service Navgator.
Event Correlation Libraries
The directory of the event correlation libraries.
Event Correlation Modules
The directory of the event correlation modules.
Java GUI Message View Filters.
Message view filters defined in Java GUI.

Directory Hierarchy

Depending on the selected entities, the file tree created will look similar to the following hierarchy (directories for data entities not downloaded will not be created). Directory names are listed with a trailing slash (/).
<target directory>/<language_utf8>/
<target directory>.idx
- POLICIES/
<UUID>_header.xml
<UUID>_data

this pair of files will be created for each policy version in the HPOM database
- POLTYPES/
all_policy_types
- or -
<policy type name> - an XML file named after a policy type defined within
- POLGROUPS/
files defining policy groups
- CATEGORY/
categories
- INSTRUMENTATION
<contents of the instrumentation directory>
(from /var/opt/OV/share/databases/OpC/mgd_node/instrumentation)
- REGROUP/
regroup.dat
- NODES/
nodes.dat
- NODEHIER/
nodehier.dat
- NODEGROUPS/
nodegroups.dat
- OPERATORS/
operators.dat
- MSGGROUPS/
msggroups.dat
- APPLICATIONS/
applications.dat
- OVREGFILES/
<common application registration files>
- OTHER/
- DBMAINT/
dbmaint.dat
- MGMTSV/
mgmtsv.dat
- NODE_DEF/
node_def.dat
- NOTIFY/
notify_def.dat
- TROUBLET/
troublet_def.dat
- INSTINTF/
instintf.dat
- RESPMGRS/
allnodes
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/respmgrs/allnodes)
<node specific files for the responsible manager configuration>
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/respmgrs/<hex-ip-address>)
msgforw
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/respmgrs/msgforw)
msiconf
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/msiconf)
outage
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/respmgrs/outage)
seldist
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/seldist)
- SERVICES/
services
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/opcsvcm/services)
loggings
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/opcsvcm/loggings)
- ECLIBRARIES/
<event correlation libraries>
- ECMODULES/
<event correlation modules>
- JGUI/MVFS/
Java GUI message view filters from
(from /etc/opt/OV/share/conf/OpC/mgmt_sv/jgui/filter)
- ADMIN/
admin.dat
- EXECUTABLES/
<same structure as the directory tree starting at /var/opt/OV/share/databases/OpC/mgd_node/customer>
The target file tree is checked for already existing files. If the file tree does not exist, it will be created. If it is already existing and empty, the correct ownership and permissions are set (all files and directories will be owned and writable by the superuser only). If there are files already existing in the destination directories, the program issues a warning and removes all files if the -force flag was specified, otherwise the program opccfgdwn exits.
Logging information for each specified entity and the identifiers of all instances processed are written to an index file. This file is created by the opccfgdwncommand and has the same name as the last component of the target directory (truncated to 8 characters) with the extension .idx. The index file is located at the top of the download directory tree (<target directory>/<language_utf8>). It is created as a read-only file and should not be edited under any circumstances.
The index file contains the management server character set to ensure that only data of the same character set is uploaded.
NOTE, the following data is not processed by the download:
Nodes:
- HPOM software status on this node
- HPOM configuration distribution to this node
- is managed node license counted on this management server
Management Server Configuration:
- management server node is not changed
- character set of management server is not changed
Operators:
- flag for domain changes since last login
- flag for realm layout changes since last login
- flag for desktop changes since last login
For Active or History Messages, see opchistdwn(1m) and opchistupl(1m) .
If you download parts of the configuration, make sure that these parts are not changed during the download neither via command line tools (like opcnode, opcservice, opctempl, ...) nor the config APIs.
Downloaded data can be uploaded to another system or another platform. For more information please see opccfgupld(1m) .

Download Specification File (DSF)

The following section describes the syntax of DSF which is used to specify which configuration entities are to be downloaded. Most keywords can be followed by one or more entries that specify the granularity of downloaded configuration data. All custom strings (names, IDs, ...) must be placed in double quotes and each line in DSF must be followed by a semicolon.
Full download

To download the complete configuration, simply use the asterisk symbol followed by a semicolon.
Selected download

Node groups
  Use keyword NODE_GROUP followed by the node group
  name to download a specific node group, or use
  NODE_GROUP_BANK keyword to download all configured
  node groups.

Managed nodes
  In order to download a single managed node, use the
  keyword NODE followed by either keyword _OPC_MGMTSV_
  (to download the management server node) or one of
  the following combinations:

  IP { <IPv4/IPv6 address> [ <node name> ] [ IP_FLAGS <flags> ]
       | OTHER <node name> [ IP_FLAGS <flags> ]
       | PATTERN_IP_ADDR <IP pattern> [ IP_FLAGS <flags> ]
       | PATTERN_IP_NAME <name pattern> [ IP_FLAGS <flags> ] }
  Also, the entire node bank can be downloaded by using
  the NODE_BANK keyword. Specific node layout groups
  are downloaded by specifiying the keyword
  NODE_LAYOUT_GROUP followed by the layout group name.

Node defaults
  Download specific node defaults by using
  NODE_DEFAULTS keyword followed by the network number
  and machine type. To download all node defaults,
  follow the NODE_DEFAULTS keyword by an asterisk.

Node hierarchies
  In order to download a single node hierarchy, use
  keyword NODE_HIERARCHY followed by the name of
  the hierarchy. All node hierarchies can be downloaded
  by using the keyword NODE_HIERARCHY_BANK instead.

Message groups
  All message groups can be downloaded by using the
  keyword MESSAGE_GROUP_BANK. Alternatively, single
  message groups can be retrieved with keyword
  MESSAGE_GROUP followed by the name of the message
  group.

Applications
  Use the keyword APPLICATION_BANK to download all
  applications configured on a HPOM management server.
  Keywords APPLICATION_GROUP and
  MEMBER_APPLICATION_GROUP followed by the application
  group name can be used to download top level and
  lower level (member) application groups respectively.
  To download single applications, use the following
  expression:

  APPLICATION <application name> [ IN <application group name> ]

Operators
  The complete operator configuration can be downloaded
  with keyword OPERATOR_BANK. In order to download
  specific configuration of single operator, use the
  expression below:

  OPERATOR <operator name> CONFIGURATION { * |
    [ DATA ] [ RESPONSIBILITY ] [ NODE_LAYOUT ]
    [ BROWSER_SETTING ]
    [ DESKTOP { * |
      { <application name> [ IN <app group name> } }
  }

Categories
  Categories and their instrumentation can be downloaded
  by using the keyword CATEGORY followed either by an
  asterisk (for all categories) or a specific category
  name.

Policy types
  Keyword POLICY_TYPE is used when download of policy
  types is desired. It needs to be followed either by
  an asterisk (for all policy types) or by the policy
  type name.

Policies
  Policies can be downloaded by using the syntax below.
  If asterisk is specified after the POLICY keyword,
  all configured policies are downloaded. If it is
  followed by a type name, all policies of that type
  are retrieved.
  Full syntax is as follows:
  POLICY { * | <policy UUID> | * <policy type name> |
    <policy name> <policy type name> |
    <policy name> <policy type name> <policy version> }

Policy groups
  Use keyword POLICY_GROUP followed either by an
  asterisk or by a policy group name to download all
  or specific policy group respectively. If policy
  group name is followed by the keyword WITH_POLICIES,
  all policies belonging to the specified group are
  downloaded as well.

Notification services
  Downloading notification services is done by
  specifying the keyword NOTIFICATION_SERVICE and
  following it by an asterisk (for all notification
  services) or by a name of a desired service.

Instruction interface
  Instruction interface download follows the same rules
  as categories and notification services, except that
  the keyword INSTRUCTION_INTERFACE is used instead.

Other configuration
  In the following table are listed other configuration
  items and the keywords that should be used for their
  download. There are no additional arguments to the
  keywords, they are used directly in the DSF.

   Administrator configuration - ADMIN_CONFIGURATION
   Regrouping conditions       - REGROUP_CONDITION
   Database maintenance config - DB_MAINTENANCE
   Management server config    - MANAGEMENT_CONFIG
   Trouble ticket config       - TROUBLE_TICKET
   Responsible manager config  - RESPONSIBLE_MANAGER
   Message forwarding config   - FORWARD_MANAGER
   Services                    - SERVICES_LOGGINGS
   Selective distribution cfg  - SELECTIVE_DISTRIBUTION
   Executables                 - EXECUTABLES
   Event correlation libraries - EC_LIBRARIES
   Event correlation modules   - EC_MODULES
   Message view filters        - JGUI_MSG_VIEW_FILTERS

Localization

HPOM 9.00 introduces Unicode support. Both the Oracle database and the management server work exclusively with the UTF-8 character set, which provides multilingual support. Because of that all downloaded data is always encoded in UTF-8, independent of the user's OS character set. For that reason the download directory <language> is added an UTF-8 suffix. This suffix is platform dependent: .utf8 for HP-UX and .UTF-8 for Solaris and Linux. Note that if your $LANG variable has no UTF-8 character set suffix, the download directory will have the name of the default OMU locale, with the UTF-8 suffix appended (i.e. $LANG=de_DE.iso88591 would result in <download_path>/C.utf8 or <download_path>/en_US.UTF-8 respectively, but$LANG=de_DE.UTF-8 or $LANG=de_DE.utf8 would use that value as the name for the download directory, without any changes).

Exit Values

This command will exit with value 0 after successful operation; otherwise the exit value will be set to 1 and an appropriate message will be displayed on stderr.

Restrictions

This command can only be issued by the superuser.
This command is only available on the Management Server.
Customized background graphics and symbol types and shapes are not downloaded.
Downloading modified symbol types is not supported. Only symbol types used at object creation time are downloaded.

Examples

The following example uses the target directory /tmp/dwn1 for the download of the HPOM configuration data. The specification file spec1 is searched in the directory /tmp/dwn1/C, assuming the language is "C". The download generates verbose progress messages. If the target directory tree contains data files, opccfgdwn aborts with an error. The index file is created with the pathname /tmp/dwn1/C/dwn1.idx.
opccfgdwn spec1 /tmp/dwn1
The following example uses the target directory /var/opt/OV/share/tmp/OpC_appl/dwn2 for the download of the HPOM configuration data. The specification file /tmp/spec2 is parsed, no progress messages are generated. Data files are removed from the target directory tree before the download. The index file is created with the pathname /var/opt/OV/share/tmp/OpC_appl/dwn2/japanese/dwn2.idx, assuming the language is "japanese".
opccfgdwn -silent -force /tmp/spec2 dwn2

No comments:

Post a Comment