Friday, May 25, 2018

Creating a new instance on openstack

In order to create new instance (it is called server in openstack command), you need to know beforehand a few information to feed to the create instance command. Refer below for those information:

check available flavor

$ openstack flavor list

check available images
$ openstack image list

check available network
$ openstack network list

check available security group
$ openstack security group list

check available keypair
$ openstack keypair list


Once you get all the above information, to create the new instance, just use below command, providing the above information as option to openstack server create command
$ openstack server create \
--image centos-7-20180520 \
--key-name my-keypair \
--flavor m1.medium \
--security-group defaults \
--network private-140 \
thenewinstancename


To check whether your new instance has been created and active:
$ openstack server list


No comments: