Instances can be created into a given AZ by passing the --availability-zone
parameter as part of the creation process. Additionally, AZ can be selected in OpenStack Horizon as part of the instance creation wizard.
The following information is required to boot an instance into an AZ:
openstack
command-line clientopenrc
file containing appropriate credentialsTo boot an instance into a specific AZ, the --availability-zone
parameter is specified when running the openstack server create
command:
openstack server create --flavor openstack.cookbook --image 08b822ba-be44-4639-b577-45e8dd37c06d --nic net-id=6cb5a4ce-1ea5-4817-9c34-a2212a66f394 --security-group bd7d5e0f-538a-4d93-b123-98cc3207b3d2 --key-name cookbook_key --availability-zone cookbook-az cookbook.test-03
This will bring back an output like the following, showing the AZ (the OS-EXT-AZ:availability-zone
field) where the instance was scheduled to:
18.117.158.165