← 返回命令列表

Linux command

nova 命令

文本

复制后可按需替换文件名、目录或参数。

常用示例

List VMs

nova list

Example

nova list --all-tenants

Boot a VM

nova boot --nic net-id=[net_id] --image [image_id] --flavor [flavor] --availability-zone nova:[host_name] [vm_name]

Start

nova start [server]

Stop

nova stop [server]

Attach a network interface

nova interface-attach --net-id [net_id] [server]

说明

nova is the command-line client for OpenStack Compute (Nova), which manages virtual machine instances in OpenStack clouds. It handles VM lifecycle operations: creating, starting, stopping, and deleting instances. Nova integrates with other OpenStack services: Glance for images, Neutron for networking, Cinder for block storage, and Keystone for authentication. Authentication credentials are typically provided through environment variables (OS_USERNAME, OS_PASSWORD, etc.). The client communicates with the Nova API to provision compute resources according to specified configurations (flavor, image, network).

参数

list
List virtual machines
boot
Create and boot a new VM
start
Start a stopped VM
stop
Stop a running VM
delete
Delete a VM
show
Show details of a VM
interface-attach
Attach a network interface to a VM
--nic net-id=_id_
Network to attach
--image _id_
Image ID to boot from
--flavor _name_
Instance type/size
--availability-zone _zone:host_
Placement specification
--all-tenants
Show VMs from all tenants (admin)

FAQ

What is the nova command used for?

nova is the command-line client for OpenStack Compute (Nova), which manages virtual machine instances in OpenStack clouds. It handles VM lifecycle operations: creating, starting, stopping, and deleting instances. Nova integrates with other OpenStack services: Glance for images, Neutron for networking, Cinder for block storage, and Keystone for authentication. Authentication credentials are typically provided through environment variables (OS_USERNAME, OS_PASSWORD, etc.). The client communicates with the Nova API to provision compute resources according to specified configurations (flavor, image, network).

How do I run a basic nova example?

Run `nova list` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does list do in nova?

List virtual machines