PowerVM NovaLink command-line interface

The PowerVM® NovaLink command-line interface (CLI) is a Python-based CLI for administrative functions on a system that is managed through PowerVM NovaLink.

pvmctl command

The command-line interface uses the pvmctl command for most operations. The command can be entered at the command line of the PowerVM NovaLink partition.

The pvmctl command can be run only by users who are in the pvm_admin group. To add a user to the pvm_admin group, enter the following command.
sudo adduser user_id pvm_admin
The admin user for the PowerVM NovaLink partition is added to the pvm_admin group automatically when PowerVM NovaLink is installed.

Displaying version information

To display version information for the PowerVM NovaLink software, enter the command pvmctl --version.

Command help

The pvmctl command includes help information that lists the operations that are used by the command. To view the help information, enter one of the following commands.

To view a list of objects on which you can perform actions, enter the command pvmctl help or pvmctl --help.

To view a list of operations for a specific object type, enter the command pvmctl object_type help or pvmctl object_type --help.

To view information about the arguments for a specific object type and operation, enter the command pvmctl object_type operation help or pvmctl object_type operation --help.

Supported object types

The following object types are supported by the PowerVM NovaLink CLI. You can use either the full object type or the indicated short names for each object type.
  • ManagedSystem (sys)
  • LogicalPartition (lpar or vm)
  • VirtualIOServer (vios)
  • SharedStoragePool (ssp)
  • IOSlot (io)
  • LoadGroup (lgrp)
  • LogicalUnit (lu)
  • LogicalVolume (lv)
  • NetworkBridge (nbr or bridge)
  • PhysicalVolume (pv)
  • SharedEthernetAdapter (sea)
  • SharedStoragePool (ssp)
  • VirtualEthernetAdapter (vea or eth)
  • VirtualFibreChannelMapping (vfc or vfcmapping)
  • VirtualMediaRepository (vmr or repo)
  • VirtualNetwork (vnet or net)
  • VirtualOpticalMedia (vom or media)
  • VirtualSCSIMapping (scsi or scsimapping)
  • VirtualSwitch (vswitch or vsw)

Command structure

The CLI uses the following command structure.

pvmctl [--version] [object] [operation] [arguments...] [help | --help]
For example, to list the logical partitions on the managed system, enter the following command:
pvmctl LogicalPartition list
To list all Virtual I/O Server names, IDs, states, and their associated I/O Adapter device names, use the --display-fields (or -d) argument:
pvmctl vios list -d name id state IOAdapter.dev_name
To list the names, IDs, states, and associated I/O Adapter device names of all Virtual I/O Servers that are not running, use the --where argument to add the condition to the command:
pvmctl vios list -d name id state IOAdapter.dev_name --where VirtualIOServer.state!=running
To list a network bridge with a port VLAN ID of 10, use the --object-id (or -i) argument:
pvmctl bridge list --object-id pvid=10
To update the desired memory of a logical partition with name mylpar to 512 MB, use the --set-fields argument:
pvmctl lpar update -i name=mylpar --set-fields PartitionMemoryConfiguration.desired=512 
To delete a virtual Ethernet adapter, specify its parent identifier with the --parent-id (or -p) argument:
pvmctl vea delete -i pvid=1 --parent-id name=lpar_name

To create a new logical partition, view the required arguments by using the command pvmctl lpar create help.

The following command creates an AIX®/Linux logical partition named new_lpar with one dedicated processor and 512 MB of memory:
pvmctl lpar create --name new_lpar --proc 1 --proc-type dedicated 
--sharing-mode normal --type AIX/Linux --mem 512

Virtual terminal command

Enter the mkvterm command to open a virtual terminal connection to an AIX or Linux logical partition.

For example, to open a virtual terminal connection to a partition with partition ID 3, enter the following command:
mkvterm --id 3

To exit the virtual terminal, press Control + ].

Partition configuration backup and restore commands

Enter the bkprofdata and rstprofdata commands to back up and restore the partition configuration data of a managed system. These commands back up and restore only the partition configuration data in the hypervisor.

For example, to backup the partition configuration to the /tmp/mybackup.bak file, enter the following command:
bkprofdata -o backup -f /tmp/mybackup.bak
To restore the partition configuration data from the /tmp/mybackup.bak file by using phase 2 restoration, enter the following command:
rstprofdata -l 2 -f /tmp/mybackup.bak

Virtual I/O Server command

Use the viosvrcmd command to run commands on an instance of the Virtual I/O Server.

For example, to run the lsmap -all command on the Virtual I/O Server with partition ID 2, enter the following command:
viosvrcmd --id 2 -c "lsmap -all"

Last updated: Fri, December 06, 2019