Hello and welcome to this video on Oracle Private Cloud Appliance.
In this video, you will learn how to create, update, start, stop, and delete
an instance pool using an instance configuration.
An instance pool is a group of compute instances within the same region.
The advantage of creating an instance pool is that a single operation, such as start,
or stop for example, is performed on all instances that are members of the pool.
Creating an instance pool requires an instance configuration and at least one placement
configuration.
To learn how to create an instance configuration, view the video
Managing an instance configuration.
Also, instances that are added to the pool in a update can be created with
different instance and placement configurations, if necessary.
Let's get started and retrieve a list of instance configurations in our Private
cloud appliance by running the command:
oci compute-management instance-configuration list -c followed by the compartment OCID
From the returned results, the instance configuration we'll use is my-instance-01.
Great!
Now let's create a placement configuration file.
You can download a template placement configuration file by running the command:
oci compute-management instance-pool create --generate-param-json-input placement-configurations
> placement_configurations.json
Next we'll copy and rename this file to customize our new placement configuration file
using the command:
cp placement_configurations.json my_placement_configurations.json
Edit this new file with vi and enter the values required.
As you can see, I've reduced this file to only the required fields to
create an instance pool, which are
availabilityDomain, faultDomains, and
the primarySubnetID which is the OCID of the desired subnet.
Save and exit editing this file by typing :x.
Next run the following command to create the instance pool:
oci compute-management instance-pool create \
--compartment-id followed by the compartment OCID
--display-name my-instance-pool-01 --instance-configuration-id followed by the
instance configuration OCID --placement-configurations file://my_placement_configurations.json
\ --size 3
Let's verify that the new instance pool was created by turning to the web interface.
After logging in and from the dashboard, click on the menu and then Compute and
then Instance Pools.
As you can see, the new instance pool, my-instance-pool-01 was created.
I'll click on my-instance-pool-01 to see the general information in addition to the
three attached compute instances running in this pool.
Let's now update the instance pool by increasing the size by 1 using the command:
oci compute-management instance-pool update \
--instance-pool-id followed by the instance pool OCID
--instance-configuration-id followed by the instance configuration OCID
--size 4 to increase the pool from 3 compute instances to 4
Let's check to see if my-instance-pool-01 was updated using the web interface.
Returning to the GUI, we see that my-instance-pool-01 was updated
and now has a pool size of 4 as we requested.
We can also stop the instance pool by using the command:
oci compute-management instance-pool stop --instance-pool-id followed by the
instance pool OCID
Again let's return to the GUI interface and we see that the my-instance-pool was
stopped.
Let's restart the my-instance-pool-01 by issuing the command:
$ oci compute-management instance-pool start --instance-pool-id followed by then
instance pool OCID.
Let's check the GUI again, and we can see the my-instance-pool-01 has started again.
Lastly, let's delete the instance pool using the GUI.
Click on Controls to reveal a drop down menu then click on Delete.
When asked to confirm the deletion, click confirm.
As we can see, my-instance-pool-01 was successfully deleted from the compartment.
For more information, please check our additional information on Oracle Private
Cloud Appliance documentation or in the Oracle Private Cloud Appliance Learning
Library.
This concludes the video.
Thank you for watching.