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
nnmfindattachedswport.sh — Find the switch port to which the input end node is attached
SYNOPSIS
nnmfindattachedswport.sh [-u <user>] [-p <password>] { -i <end node file> | -n <end node> } [-o <output file>]
DESCRIPTION
The nnmfindattachedswport.sh script displays the switch port that is connnected to an end node. When using the nnmfindattachedswport.sh script, specify the end node as a MAC address, an IP address, or a hostname. Specify the MAC address in upper case with no leading 0x
or 0X
. You can also specify the input as a seed file, using one line per entry within the seed file.
The display consists of the following:
-
The end node.
-
The switch hostname.
-
The interface name of the switch port that is connected to an end node.
-
The VLAN name that the end node belongs to.
-
The VLAN ID that the end node belongs to.
-
A status code for the interface.
The status code indicates either Success
, if NNMi successfully retrieved the end node information, or an error code. The display is in Comma Separated Value (CSV) format. If any of the values are not present then NNMi displays the value -1
instead. NNMi indicates the completion of the script by displaying a CSV with all the values being -1
.
NNMi initially displays a header naming each of the values in the CSV. There is an option to redirect the output to a file. The file can then be imported into Microsoft™ Excel.
Parameters
nnmfindattachedswport.sh
supports the following parameters:
-u <user name>
-
Supply an NNMi user name to use when running the script. The user could be system, an administrator or a Level 2 operator.
-p <password>
-
Supply the password for the user.
-i <end node file>
-
Use
-i
to provide an input file containing a list of end nodes. NNMi then searches for the switch port connected to each end node. The file should have only one entry per line. The value on each line could be a MAC address, an IP address or a hostname. The MAC address needs to be specified in upper case with no leading0x
or0X
. This parameter is required if the-n
is not specified. -n <end node>
-
Use the
-n
to provide an end node for the nnmfindattachedswport.sh script. The nnmfindattachedswport.sh script finds the switch port that is connected to this end node. The end node could be a MAC address, an IP address or a hostname. The MAC address needs to be specified in upper case with no leading0x
or0X
. -o <output file>
-
Use
-o
to supply a file name to which the output of the script will be redirected.
EXAMPLES
An example of an input file is given below:
10.45.130.2 # this is a comment line con5.acme.com 000087D064CB 10.12.149.4 laserj.acme.com
An example of the display looks similar to the following:
EndNode,SwitchName,IfName,VLANName,VLANId,StatusCode 10.45.130.2,-1,-1,-1,-1,UNABLE_TO_LOCATE_ENTRY_IN_FDB con5.acme.com,-1,-1,-1,-1,UNABLE_TO_LOCATE_ENTRY_IN_ARP_CACHE 000087D064CB,10.45.130.143,2/1,Network_B_IPv4,4,SUCCESS 10.12.149.4,sw1-loop0.acme.com,Fa2/21,VLAN0490,490,SUCCESS laserj.acme.com,sw1-loop0.acme.com,Fa2/12,mpls-intercon,169,SUCCESS -1,-1,-1,-1,-1,-1
AUTHOR
nnmfindattachedswport.sh
was developed by Hewlett Packard Enterprise.
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: