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 |
|
- Add scripts to extensible discovery
- Scripts provided with extensible discovery
- Software policies provided with extensible discovery
- Write your own scripts for extensible discovery
- Add your own scripts to extensible discovery
- Upgrade your scripts in extensible discovery
- Remove your scripts from managed servers
- Output from extensible discovery scripts
Write your own scripts for extensible discovery
This section describes requirements and guidelines for writing scripts for use with Extensible Discovery. For instructions on how to add your scripts to Extensible Discovery, see Add your own scripts to extensible discovery.
- HPE provides several sample scripts you can use in the software policy “HPE provided Scripts”. You can view these scripts in /Library/Opsware/Tools/Extensible Discovery/HPE provided Components. For more information, see Scripts provided with extensible discovery.
- A best practice is to store your script in a version control system.
- Your script needs to handle error situations within your script and return an accurate exit status. The following explains various error situations and how Extensible Discovery handles them.
- The exit status of a shell script is the exit status of the last command in the script. A script that returns zero status is considered successful.
- A script could return zero status but also send some output to stderr. This case is treated as a success. The output from stderr will be treated the same as stdout.
- A script that returns zero status and outputs nothing to stdout or stderr will be considered a success and the blank value will be written to the appropriate custom attribute or custom field. You could use this method to set the custom attribute or custom field to ““.
- A script that returns a non-zero value is treated as an error. A message including the script's stdout and stderr will be stored in the HPSW_ED_error custom attribute.
- A script that is not executable or has syntax errors is treated as an error. A message including the script's stdout and stderr will be stored in the HPSW_ED_error custom attribute.
- If a script determines that it has nothing to collect on a server (for example, if the get_eeprom_version.sh is run on a Solaris x86 server, where there is no EEPROM), it should return an exit status of 3, which will be interpreted by Extensible Discovery as not applicable, and will return nothing for that particular data item.
- For UNIX shell scripts, if you want the script to fail when any individual command in the script fails, start the script with the line
#!/bin/sh -e
. For more information, see the documentation for the UNIX shell.
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 hpe_sa_docs@hpe.com.
Help Topic ID:
Product:
Topic Title:
Feedback: