Table of Contents
From the title of today’s blog, you must have come to know that today we are going to discuss “OpenStack Database (Trove)” component and after that, we are going to continue our discussion with installation and configuration of it for openSUSE and SUSE Linux, and installation and configuration of Trove Dashboard. I guarantee you today’s blog will be really interesting and simple to understand!
Therefore without wasting our time, let’s start the discussion!
Trove is a Database which was constructed to work completely on the OpenStack, with an aim of letting the users swiftly and effortlessly make use of the characteristics of relational databases excluding the stress of managing the complicated administration processes. Thus we can say that Trove is a database like service for the OpenStack. Therefore it is possible for all the cloud users and administrators of the database to be able to provide as well as handle more than one database events as per the requirement.
First of all the Trove service focuses on supplying the isolation of resources with a top-level performance at the same time the complicated administration works can be automated along with the other processes like installation, constitution, taking backups, restoring data and resolving problems, regulating, etc.
Now our next discussion is about how to install and configure the database Trove service:
Installation and configuration of Database service:
Points to be considered:
Today, we are going to discuss the installation and configuration only for the openSUSE and SUSE Linux Enterprise distribution, and the process of installation and configuration for other two types of distributions will be discussed in the next blog.
Now let’s first look at the points which we are going to consider for installing and configuring for the openSUSE and SUSE Linux Enterprise:
As mentioned earlier, we are going to describe the process of installation and configuration for the openSUSE Leap 42.2 and for SUSE Linux Enterprise Server 12 SP2.
Before performing the installation and configuration of the database service, you should first create a database; also create credentials for the database and API endpoints.
$ mysql -u root -p
CREATE DATABASE trove;
GRANT ALL PRIVILEGES ON trove.* TO ‘trove’@’localhost’ \
IDENTIFIED BY ‘TROVE_DBPASS’;
GRANT ALL PRIVILEGES ON trove.* TO ‘trove’@’%’ \
IDENTIFIED BY ‘TROVE_DBPASS’;
Then substitute the TROVE_DBPASS with an appropriate password.
$ . admin-openrc
$ openstack user create –domain default –password-prompt trove
User Password:
Repeat User Password:
+———–+———————————–+
| Field | Value |
+———–+———————————–+
| domain_id | default |
| enabled | True |
| id | ca2e175b851943349be29a328cc5e360 |
| name | trove |
+———–+———————————–+
$ openstack role add –project service –user trove admin
Important Note:
It is important to keep in mind that, the above command does not provide any output.
$ openstack service create –name trove \
–description “Database” database
+————-+———————————–+
| Field | Value |
+————-+———————————–+
| description | Database |
| enabled | True |
| id | 727841c6f5df4773baa4e8a5ae7d72eb |
| name | trove |
| type | database |
+————-+———————————–+
$ openstack endpoint create –region RegionOne \
database public http://controller:8779/v1.0/%\(tenant_id\)s
+————–+———————————————-+
| Field | Value |
+————–+———————————————-+
| enabled | True |
| id | 3f4dab34624e4be7b000265f25049609 |
| interface | public |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 727841c6f5df4773baa4e8a5ae7d72eb |
| service_name | trove |
| service_type | database |
| url | http://controller:8779/v1.0/%\(tenant_id\)s |
+————–+———————————————-+
$ openstack endpoint create –region RegionOne \
database internal http://controller:8779/v1.0/%\(tenant_id\)s
+————–+———————————————-+
| Field | Value |
+————–+———————————————-+
| enabled | True |
| id | 9489f78e958e45cc85570fec7e836d98 |
| interface | internal |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 727841c6f5df4773baa4e8a5ae7d72eb |
| service_name | trove |
| service_type | database |
| url | http://controller:8779/v1.0/%\(tenant_id\)s |
+————–+———————————————-+
$ openstack endpoint create –region RegionOne \
database admin http://controller:8779/v1.0/%\(tenant_id\)s
+————–+———————————————-+
| Field | Value |
+————–+———————————————-+
| enabled | True |
| id | 76091559514b40c6b7b38dde790efe99 |
| interface | admin |
| region | RegionOne |
| region_id | RegionOne |
| service_id | 727841c6f5df4773baa4e8a5ae7d72eb |
| service_name | trove |
| service_type | database |
| url | http://controller:8779/v1.0/%\(tenant_id\)s |
+————–+———————————————-+
# zypper –quiet –non-interactive install python-oslo.db \
python-MySQL-python
# zypper –quiet –non-interactive install openstack-trove-api \
openstack-trove-taskmanager openstack-trove-conductor \
openstack-trove-guestagent
[DEFAULT]
log_dir = /var/log/trove
trove_auth_url = http://controller/identity/v2.0
nova_compute_url = http://controller:8774/v2
cinder_url = http://controller:8776/v1
swift_url = http://controller:8080/v1/AUTH_
…
[database]
connection = mysql+pymysql://trove:TROVE_DBPASS@controller/trove
[DEFAULT]
…
rpc_backend = rabbit
transport_url = rabbit://<rabbit_userid>:<rabbit_password>@<rabbit_host>:5672
If the API-paste.ini file is not present in /etc/trove, then you can find it at the following location:
[DEFAULT]
auth_strategy = keystone
…
# Config option for showing the IP address that nova doles out
add_addresses = True
network_label_regex = ^NETWORK_LABEL$
…
api_paste_config = /etc/trove/api-paste.ini
…
[keystone_authtoken]
…
www_authenticate_uri = http://controller/identity
auth_url = http://controller/identity_admin
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = trove
password = TROVE_PASS
[DEFAULT]
…
# Configuration options for talking to nova via the novaclient.
# These options are for an admin user in your keystone config.
# It proxy’s the token received from the user to send to nova
# via this admin users creds,
# basically acting like the client via that proxy token.
nova_proxy_admin_user = admin
nova_proxy_admin_pass = ADMIN_PASS
nova_proxy_admin_tenant_name = service
taskmanager_manager = trove.taskmanager.manager.Manager
# Inject configuration into guest via ConfigDrive
use_nova_server_config_drive = True
# Set these if using Neutron Networking
network_driver=trove.network.neutron.NeutronDriver
network_label_regex=.*
rabbit_host = controller
rabbit_password = RABBIT_PASS
trove_auth_url = http://controller/identity_admin/v2.0
# su -s /bin/sh -c “trove-manage db_sync” trove
…
2016-04-06 22:00:17.771 10706 INFO trove.db.sqlalchemy.migration [-]
Upgrading mysql+pymysql://trove:dbaasdb@controller/trove to version latest
Important Note:
Always ignore any messages related to minimization in this output.
For finalizing the installation, first of all enable the Database services and then configure them such that they will enable when the system boots:
# systemctl enable openstack-trove-api.service \
openstack-trove-taskmanager.service \
openstack-trove-conductor. Service
# systemctl start openstack-trove-api.service \
openstack-trove-taskmanager.service \
openstack-trove-conductor.service
Up to here we saw overview of the database trove service and how to install and configure it for the openSUSE and SUSE Linux Enterprise. I hope you understand these topics. Now we are moving on to another section, which is about how to install and configure the trove dashboard:
# pip install trove-dashboard
That’s all for today! I hope you find this information helpful. Please do not forget to leave a comment in the comment section below. Thank you for reading the blog! See you soon with another interesting blog!
People also read:
In today's digital landscape, timing is everything. Whether you're a social media manager, business owner, or content creator, the success…
Are you a website owner? Maintaining the website is the prime concern for any website owner. Yes, it’s equally important…
If you’ve planned to launch a WordPress website, you might get a question, “How do I log in to WordPress?”…
As the demand for virtual private servers (VPS) continues to grow, businesses and individuals are faced with a crucial decision:…
Web hosting is a large industry, as many other factors help any web hosting provider to form a company. The…
View Comments