Using OpenStack After Kolla Ansible Deployment
1. Install the OpenStack CLI client
pip3 install python-openstackclient -c https://releases.openstack.org/constraints/upper/master
2. OpenStack requires a clouds.yaml
file where credentials for the admin user are set. To generate this file:
kolla-ansible -i multinode post-deploy -vvv
Note:
The file will be generated in
/etc/kolla/clouds.yaml
, you can use it by copying it to/etc/openstack
or~/.config/openstack
, or by setting theOS_CLIENT_CONFIG_FILE
environment variable.
3. Verify OpenStack cluster, see everything is great and check Ceph Cluster was integrated with OpenStack
source ~/kolla-venv/bin/activate; source /etc/kolla/admin-openrc.sh
openstack endpoint list
openstack service list; openstack compute service list; openstack network agent list
openstack volume service list; cinder get-pools
4. Depending on how you installed Kolla Ansible, there is a script that will create openstack resources like networks, images, router, flavor, keypair and so on.
Warning
You are free to use the following
init-runonce
script for demo purposes but note it does not have to be run in order to use your cloud. Depending on your customisations, it may not work, or it may conflict with the resources you want to create. You have been warned.
kolla-venv/share/kolla-ansible/init-runonce
The output should be like this
openstack volume create \
--image cirros \
--size 3 \
boot-cirros
sleep 20
openstack server create \
--volume boot-cirros \
--flavor m1.tiny \
--key-name mykey \
--network demo-net \
vm-cirros
Below is network topology from our OpenStack resource
Access console instance and test connection to internet
5. Look at Ceph Cluster so we can verify that image and volumes are store there.
ceph df
References :
#OpenStack #kolla #ansible #ceph #CloudComputing #PrivateCloud #OpenSource