How to do it...

To build a new KVM instance using the OpenStack command-line interface (CLI), perform the following steps:

  1. Ensure that we have an available Glance image to use:
root@controller:~# openstack image list+--------------------------------------+--------------+--------+| ID                                   | Name         | Status |+--------------------------------------+--------------+--------+| abce08d2-2f9f-4545-a414-32019d41c0cd | ubuntu_16.04 | active |+--------------------------------------+--------------+--------+root@controller:~#
  1. Create a new instance flavor type:
root@controller:~# openstack flavor create --id 0 --vcpus 1 --ram 1024 --disk 5000 kvm.medium+----------------------------+------------+| Field                      | Value      |+----------------------------+------------+ ...

Get KVM Virtualization Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.