powervc-opsmgr inventory Command
Purpose
Creates, lists, or deletes inventory information of a cluster.
Syntax
powervc-opsmgr inventory -c <cluster_name> [-h] [-a] [-l] [-d] [-q] [-j]
Description
The inventory subcommand of the powervc-opsmgr command is used to create, list, or delete cluster inventory information. Inventory captures cluster configuration metadata such as cluster name, hosts, virtual IP, edition.
Only the pvcroot user is allowed to create an inventory by using the
inventory subcommand of the powervc-opsmgr command.
Flags
| Item | Description |
|---|---|
| -a or --advanced | Provides advanced options to specify virtual-IP configuration such as custom NIC, netmask when you create or update inventory. |
| -c cluster_name or --cluster cluster_name | Specifies the cluster name. |
| -d or --delete | Deletes the stored inventory information for a cluster. |
| -h or --help | Displays help about the powervc-opsmgr inventory command. |
| --json | Redirects the results in a JSON format for scripting and automation. |
| -l or --list | List cluster information. |
| -q or --quiet | Suppresses interactive license prompts. This option is useful for scripts and automation. |
Examples
- To create inventory of a cluster
XXXX, enter the following command:powervc-opsmgr inventory -c XXXX - To list existing inventory information, enter the following command:
powervc-opsmgr inventory -l - To list inventory information in JSON format, enter the following command:
powervc-opsmgr inventory -l -j