Searching the Help
To search for information in the Help, type a word or phrase in the Search box. When you enter a group of words, OR is inferred. You can use Boolean operators to refine your search.
Results returned are case insensitive. However, results ranking takes case into account and assigns higher scores to case matches. Therefore, a search for "cats" followed by a search for "Cats" would return the same number of Help topics, but the order in which the topics are listed would be different.
Search for | Example | Results |
---|---|---|
A single word | cat
|
Topics that contain the word "cat". You will also find its grammatical variations, such as "cats". |
A phrase. You can specify that the search results contain a specific phrase. |
"cat food" (quotation marks) |
Topics that contain the literal phrase "cat food" and all its grammatical variations. Without the quotation marks, the query is equivalent to specifying an OR operator, which finds topics with one of the individual words instead of the phrase. |
Search for | Operator | Example |
---|---|---|
Two or more words in the same topic |
|
|
Either word in a topic |
|
|
Topics that do not contain a specific word or phrase |
|
|
Topics that contain one string and do not contain another | ^ (caret) |
cat ^ mouse
|
A combination of search types | ( ) parentheses |
|
Name
nnmmanagementmode.sh — Change the NNM management mode of one or more nodes or interfaces.
SYNOPSIS
nnmmanagementmode.sh
-node.name <nodename>
-mode <mode>
nnmmanagementmode.sh
-t <object type>
-f <csv_filename>
nnmmanagementmode.sh
-t <object type>
-s <csv_line>
nnmmanagementmode.sh
-t <object type>
-f <uuid_file>
-mode <MODE_SPEC>
[-format <format>
] [-fields <fields>
]
DESCRIPTION
nnmmanagementmode.sh
allows the system administrator
to set the management mode of a node or interface in the NNM database.
Parameters
nnmmanagementmode.sh
recognizes the following options.
Any unrecognized options are reported by a usage message.
-h
-
Prints the usage statement.
-node.name
<nodename>
-
The name of a node to change management mode on.
-mode
<mode>
-
The desired management mode to set. Valid values are MANAGED, NOTMANAGED, or OUTOFSERVICE for nodes and INHERITED, NOTMANAGED or OUTOFSERVICE for interfaces
-mode
<MODE_SPEC>
-
When using the input uuid file to perform a batch change the mode argument accepts two styles. The first is a simple mode with values of MANAGED, NOTMANAGED, or OUTOFSERVICE (INHERITED, NOTMANAGED or OUTOFSERVICE for interfaces). The second style consists of a current and new mode in the form
CURRENT
:NEW
whereCURRENT
andNEW
have the same values of MANAGED, NOTMANAGED, or OUTOFSERVICE. In the second form the tool will only update objects that have the supplied current value and skip any that have a different value. -t
<object type>
-
Supply the object type to set the management mode on. Valid values are "node" or "interface".
-f
<csv_filename>
-
Supply the CSV file name (with path, e.g. /opt/tmp/mynodes.csv) from where you want to set the management mode. If the file contains incorrect entries (too many/few columns, incorrect mode) the command will report these but will not execute any of the entries.
-b
<batch_size>
-
If the input comes from a file, the command will process all entries and send the request to the server in chunks specified by this option. The default is 1000 entries at a time.
-s
<csv_line>
-
Supply a single CSV formatted line. Eliminates the need to create a file for a simple change.
-format (
csv
|list
|text
|xml
)-
Changes the output format when tabular data is being presented.
-fields
<comma_separated_fields>
-
Selects the output fields when tabular data is being presented.
-jndiHost
<hostname>
-
The server jndi host; the default is localhost.
-jndiPort
<port>
-
The server jndi port; the default is auto-detected.
-u
<username>
-
Supply the NNMi administrator username to run the script.
-p
<password>
-
Supply the NNMi administrator password to run the script.
Batch changing management modes
To perform a batch change of management modes the following command may be used. Input to this command is from a file containing the UUIDs of the objects to update and the mode supplied on the command line. All objects listed in the file will be processed according to the supplied mode.
nnmmanagementmode.sh -t
<type>
-f <filepath>
-mode <MODE_SPEC>
In this mode the command output will consist of a table of the input UUIDs and the result code for that object. The result codes are:
-
UPDATED
- The object has been updated to the new mode. -
NOT_FOUND
- No object with the specified UUID was found in the system. -
SKIPPED
- The object did not match the current mode filter. -
NO_CHANGE
- The object already has the requested mode. -
ACCESS_DENIED
- The user does not have permission to change the management mode for the object.
For example if the neighbors.txt
file contains a list of interface UUIDs each on a single line then the following command
would change each of those interfaces to the OUTOFSERVICE mode only if it was currently INHERITED. Interfaces in the UNMANAGED mode would be left unchanged.
nnmmanagementmode.sh -t interface -f neighbors.txt -mode INHERITED:OUTOFSERVICE
+--------------------------------------+---------+ | UUID | State | +--------------------------------------+---------+ | 6f988a0f-c759-42d0-8e99-f3adce84fdd7 | UPDATED | | 4dd87c33-9d0d-4713-b484-68c964ede6a6 | UPDATED | | bc0af80f-d729-40d6-bb2f-ad8bd68e2deb | SKIPPED | | bed3fff5-2385-4b09-9e3a-2572caaa624d | UPDATED | | bd0723c0-6c53-47b1-ac13-41ecab16994e | UPDATED | +--------------------------------------+---------+
Syntax of Comma Separated File for node management mode
The CSV file you supply must have the following syntax for setting management mode on nodes.
Empty lines are ignored.
Lines that begin with the # character are ignored.
All columns are mandatory
-
Column 1(A) : Node DNS|IP Address
Specify the DNS name of the node OR the IP address. The search algorithm is as follows:
- find a node that has a matching management ip address
- find a node that has a matching ip address in the default domain
- find a node that has a matching host name
- find a node that has a matching name
-
Column 2(B) : Management mode
The mode to set the node to. Valid values are "MANAGED", "NOTMANAGED", or "OUTOFSERVICE"
Example lines:
192.168.1.1,OUTOFSERVICE
my.fqdn.com, MANAGED
Syntax of Comma Separated File for interface management mode
The CSV file you supply must have the following syntax for setting management mode on interfaces.
Empty lines are ignored.
Lines that begin with the # character are ignored.
All columns are mandatory
-
Column 1(A) : Node DNS|IP Address
Specify the DNS name of the node OR the IP address. The search algorithm is the same as specified above.
-
Column 2(B) : Interface id
Interface Id Specify the identifier of the interface on the node specified in the previous field. The search algorithm is as follows:
- ifIndex
- ifName
- ifAlias
- ifDescription
-
Column 3(C) : Mode
The management mode to set the interface to. Valid entries are "INHERITED", "NOTMANAGED", or "OUTOFSERVICE"
Example lines:
192.168.1.1,1,OUTOFSERVICE
my.fqdn.com, myAlias, MANAGED
RETURN VALUE
nnmmanagementmode.sh
exits with the status
0
(zero) if no errors were encountered, 1 otherwise.
We welcome your comments!
To open the configured email client on this computer, open an email window.
Otherwise, copy the information below to a web mail client, and send this email to network-management-doc-feedback@hpe.com.
Help Topic ID:
Product:
Topic Title:
Feedback: