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 the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.