Using the tpvm command

The tpvm command is available at the SLX-OS CLI on a device.

The tpvm command, in privileged EXEC mode, allows you to manage TPVM with a variety of subcommands that do the following:
  • Install, start, stop, and uninstall TPVM
  • Specify the default behavior when SLX-OS boots
  • Add or remove disks and show the disk information
  • Print out IP addresses set on TPVM
  • Change the root password on TPVM
  • Use the help keyword for details on all options

Example

Install TPVM:

tpvm install

device# tpvm install

Example

Uninstall TPVM:

tpvm uninstall [ force ]  

force: clear installation or uninstallation error(s) then try to uninstall (forcefully)

device# tpvm uninstall
uninstallation succeeds

Example

To force the clearing of installation or uninstallation errors, use the force keyword:

device# tpvm uninstall
TPVM uninstallation failed

device# tpvm uninstall force
uninstallation succeeds

Example

To start TPVM:
tpvm start 

device# tpvm start
start succeeds

Example

To stop TPVM:
tpvm stop    

device# tpvm stop
stop succeeds

Example

To automatically start TPVM at the next reboot of SLX-OS use auto-boot enable:
tpvm auto-boot enable 

device# tpvm auto-boot enable

Example

To prevent TPVM from starting at the next reboot of SLX-OS:
tpvm auto-boot disable 

device# tpvm auto-boot disable
auto-boot disable succeeds

Note

Note

In this case, the tpvm start command is required to enable TPVM.

Example

To display the current status of TPVM, or any errors, use the following:
show tpvm status [ clear-tag <tag name> ] 

clear-tag: clear the runtime error when the 'command' ran

device# show tpvm status
TPVM is running, and AutoStart is disabled on this host.

Example

To clear errors use the clear-tag<tag name> keywords, where the error in this example is "vm_disks":
device# tpvm start
start succeeds

device# show tpvm status
TPVM had runtime error(s) -- these error(s) seem not fatal, and the operation(s) could be retryable
vm_disks: virsh list timed out. TPVM cannot transit to 'running' state

TPVM is installed but not running, and AutoStart is disabled on this host.

device# show tpvm status clear-tag vm_disks
TPVM is installed but not running, and AutoStart is disabled on this host.

Note

Note

The runtime error can be also removed automatically when the same subcommand succeeds.

Example

To add a new disk to TPVM, use the following commands:
tpvm disk add name <vd[b-x] | auto> size <number | number[bkmg]> 


name: The disk name added to TPVM.
            The name must be 'vd[b-x]' or 'auto'.
            Note. The disk name must be the next disk if it‘s not ‘auto‘. For example, if the last disk added to the system is 'vdb', the disk name must be 'vdc'. When ‘auto‘ is used, the system automatically assigns the next disk name.


size: Any positive number.
        Also the following suffix can be added to the end.
               b or B for bytes
               k or K for KiB bytes
               m or M for MiB bytes
               g or G for GiB bytes
         Note. When no suffix is used, the size is taken as GiB bytes. For example, '5' means '5g'.
device# tpvm disk add name auto size 10g
disk add succeeds

device# tpvm disk add name vdd size 512m
disk add succeeds


Note

Note

The maximum number of disks is currently 3. If the number of allocated disks exceeds this list, the add_disk keyword fails. Also, the total disk capacity is limited to 50 Gbytes on the SLX 9540. If you exceed this limit when you create a disk, the add_disk keyword fails.

Example

Use the disk remove command to remove an additional disk from TPVM:
tpvm disk remove name <vd[b-x] | auto> 

name: The disk name removed from TPVM.
            The name must be 'vd[b-x]' or 'auto'
            Note. When 'auto' is passed, the system removes the latest disk automatically.
                       Otherwise, the disk name must be the last disk added to the system.
                       For example, if the last disk added to the system is 'vdx', the disk removed from the system must be this disk, 'vdx'.
device# tpvm disk remove name auto
'umount' is needed before this disk is removed. Continue? [y/n]: y
disk remove succeeds

device# tpvm disk remove name vdc
'umount' is needed before this disk is removed. Continue? [y/n]: y
disk remove succeeds


Note

Note

Disks must be unmounted before removal from the system. Otherwise, the next added disk will be labeled incorrectly. If the system falls, TPVM must be rebooted to recover.

Example

Display disk information:
show tpvm disk name <vd[b-x] | all> 

name: The disk name whose information is shown.
            The name must be 'vd[b-x]' or 'all'
            Note. When 'all' is passed, the information about all disks is shown.
device# show tpvm disk
Value for 'name' : all
disk: vdb
Capacity: 10.00 GiB
Allocation: 196.00 KiB

total:
Capacity: 100.00 GiB
Allocation: 10.00 GiB
Available: 90.00 GiB

device# show tpvm disk name vdb
disk: vdb
Capacity: 10.00 GiB
Allocation: 196.00 KiB

total:
Capacity: 100.00 GiB
Allocation: 10.00 GiB
Available: 90.00 GiB


Example

Display IPv4 and IPv6 addresses:
show tpvm ip-address 

device# show tpvm ip-address 
IPv4:
eth0 10.24.7.149
IPv6:
eth0 fe80::629c:9fff:fe01:fe43
eth1 fe80::7:d0ff:fe02:100


Note

Note

The show_ip_addr parameter requires the qemu-guest-agent package on TPVM. If this package is removed, the operation fails.

Example

Change the root password on TPVM:
tpvm password 

device# tpvm password 
root password: ****
re-enter root password: ****
password succeeds