2016-01-08 08:25:56 -05:00
Deploying Operational Tools
===========================
TripleO comes with an optional suite of tools designed to help operators
maintain an OpenStack environment. The tools perform the following functions:
- Availability Monitoring
- Centralized Logging
2017-03-03 13:22:08 +01:00
- Performance Monitoring
2016-01-08 08:25:56 -05:00
This document will go through the presentation and installation of these tools.
Architecture
------------
2017-03-03 13:22:08 +01:00
#. Operational Tool Server:
2016-01-08 08:25:56 -05:00
- Monitoring Relay/proxy (RabbitMQ_)
- Monitoring Controller/Server (Sensu_)
2017-03-03 13:22:08 +01:00
- Data Store (Redis_)
2016-01-08 08:25:56 -05:00
- API/Presentation Layer (Uchiwa_)
- Log relay/transformer (Fluentd_)
- Data store (Elastic_)
- API/Presentation Layer (Kibana_)
2017-03-03 13:22:08 +01:00
- Performance receptor (Collectd_)
- Aggregator/Relay (Graphite_)
- An API/Presentation Layer (Grafana_)
#. Undercloud:
- There is no operational tools installed by default on the undercloud
2016-01-08 08:25:56 -05:00
#. Overcloud:
- Monitoring Agent (Sensu_)
- Log Collection Agent (Fluentd_)
2017-03-03 13:22:08 +01:00
- Performance Collector Agent (Collectd_)
2016-01-08 08:25:56 -05:00
.. _RabbitMQ: https://www.rabbitmq.com
.. _Sensu: http://sensuapp.org
2017-03-03 13:22:08 +01:00
.. _Redis: https://redis.io
2016-01-08 08:25:56 -05:00
.. _Uchiwa: https://uchiwa.io
.. _Fluentd: http://www.fluentd.org
.. _Elastic: https://www.elastic.co
.. _Kibana: https://www.elastic.co/products/kibana
2017-03-03 13:22:08 +01:00
.. _Collectd: https://collectd.org
.. _Graphite: https://graphiteapp.org
.. _Grafana: https://grafana.com
2016-01-08 08:25:56 -05:00
2017-03-03 13:22:08 +01:00
Deploying the Operational Tool Server
-------------------------------------
2016-01-08 08:25:56 -05:00
2022-05-30 22:59:58 +05:30
There is an ansible project called opstools-ansible (OpsTools_) on github that helps to install the Operator Server, further documentation of the operational tool server installation can be founded at (OpsToolsDoc_).
2016-01-08 08:25:56 -05:00
2017-03-03 13:22:08 +01:00
.. _OpsTools: https://github.com/centos-opstools/opstools-ansible
.. _OpsToolsDoc: https://github.com/centos-opstools/opstools-doc
2016-01-08 08:25:56 -05:00
2017-03-03 13:22:08 +01:00
Deploying the Undercloud
------------------------
2016-01-08 08:25:56 -05:00
2017-03-03 13:22:08 +01:00
As there is nothing to install on the undercloud nothing needs to be done.
2016-01-08 08:25:56 -05:00
2017-03-03 13:22:08 +01:00
Before deploying the Overcloud
------------------------------
2016-01-08 08:25:56 -05:00
.. note ::
2019-08-16 09:32:58 -06:00
The :doc: `../deployment/template_deploy` document has a more detailed explanation of the
2016-01-08 08:25:56 -05:00
following steps.
2017-10-02 11:02:55 +02:00
1. Install client packages on overcloud-full image:
2022-04-04 11:25:09 +12:00
- Mount the image and create a chroot::
2017-10-02 11:02:55 +02:00
2022-04-04 11:25:09 +12:00
temp_dir=$(mktemp -d)
sudo tripleo-mount-image -a /path/to/overcloud-full.qcow2 -m $temp_dir
sudo mount -o bind /dev $temp_dir/dev/
sudo cp /etc/resolv.conf $temp_dir/etc/resolv.conf
sudo chroot $temp_dir /bin/bash
2017-10-02 11:02:55 +02:00
2022-04-04 11:25:09 +12:00
- Install the packages inside the chroot::
2017-10-02 11:02:55 +02:00
2022-04-04 11:25:09 +12:00
dnf install -y centos-release-opstools
dnf install -y sensu fluentd collectd
exit
- Unmount the image::
sudo rm $temp_dir/etc/resolv.conf
sudo umount $temp_dir/dev
sudo tripleo-unmount-image -m $temp_dir
2017-10-02 11:02:55 +02:00
2017-09-15 14:19:35 -06:00
- Upload new image to undercloud image registry::
2017-10-02 11:02:55 +02:00
openstack overcloud image upload --update-existing
2. Operational tools configuration files:
2017-03-03 13:22:08 +01:00
2017-09-15 14:19:35 -06:00
The files have some documentation about the parameters that need to be configured
2017-03-03 13:22:08 +01:00
2017-09-15 14:19:35 -06:00
- Availability Monitoring::
2017-03-03 13:22:08 +01:00
2017-09-15 14:19:35 -06:00
/usr/share/openstack-tripleo-heat-templates/environments/monitoring-environment.yaml
2017-03-03 13:22:08 +01:00
2017-09-15 14:19:35 -06:00
- Centralized Logging::
2017-03-03 13:22:08 +01:00
2017-09-15 14:19:35 -06:00
/usr/share/openstack-tripleo-heat-templates/environments/logging-environment.yaml
2017-03-03 13:22:08 +01:00
2017-09-15 14:19:35 -06:00
- Performance Monitoring::
2017-03-03 13:22:08 +01:00
2017-09-15 14:19:35 -06:00
/usr/share/openstack-tripleo-heat-templates/environments/collectd-environment.yaml
2017-10-02 11:02:55 +02:00
3. Configure the environment
2017-03-03 13:22:08 +01:00
2020-07-15 15:12:08 +05:30
The easiest way to configure our environment will be to create a parameter file, let's called parameters.yaml with all the parameters defined.
2017-09-15 14:19:35 -06:00
- Availability Monitoring::
MonitoringRabbitHost: server_ip # Server were the rabbitmq was installed
MonitoringRabbitPort: 5672 # Rabbitmq port
MonitoringRabbitUserName: sensu_user # the rabbitmq user to be used by sensu
MonitoringRabbitPassword: sensu_password # The password of the sensu user
MonitoringRabbitUseSSL: false # Set to false
MonitoringRabbitVhost: "/sensu_vhost" # The virtual host of the rabbitmq
- Centralized Logging::
LoggingServers: # The servers
- host: server_ip # The ip of the server
port: 24224 # Port to send the logs [ 24224 plain & 24284 SSL ]
LoggingUsesSSL: false # Plain or SSL connections
# If LoggingUsesSSL is set to false the following lines can
# be deleted
LoggingSharedKey: secret # The key
LoggingSSLCertificate: | # The content of the SSL Certificate
-----BEGIN CERTIFICATE-----
2022-05-30 22:59:58 +05:30
...contents of server.pem here...
2017-09-15 14:19:35 -06:00
-----END CERTIFICATE-----
- Performance Monitoring::
CollectdServer: collectd0.example.com # Collectd server, where the data is going to be sent
CollectdServerPort: 25826 # Collectd port
# CollectdSecurityLevel: None # Security by default None the other values are
# Encrypt & Sign, but the two following parameters
# need to be set too
# CollectdUsername: user # User to connect to the server
# CollectdPassword: password # Password to connect to the server
# Collectd, by default, comes with several plugins
# extra plugins can added on this parameter
CollectdExtraPlugins:
- disk # disk plugin
- df # df plugin
ExtraConfig: # If the plugins need to be set, this is the location
collectd::plugin::disk::disks:
- "/^[vhs]d[a-f][0-9]?$/"
collectd::plugin::df::mountpoints:
- "/"
collectd::plugin::df::ignoreselected: false
2016-01-08 08:25:56 -05:00
2017-10-02 11:02:55 +02:00
4. Continue following the TripleO instructions for deploying an overcloud::
2016-01-08 08:25:56 -05:00
2017-09-15 14:19:35 -06:00
openstack overcloud deploy --templates \
[-e /usr/share/openstack-tripleo-heat-templates/environments/monitoring-environment.yaml] \
[-e /usr/share/openstack-tripleo-heat-templates/environments/logging-environment.yaml] \
[-e /usr/share/openstack-tripleo-heat-templates/environments/collectd-environment.yaml] \
-e parameters.yaml
2016-01-08 08:25:56 -05:00
2017-10-02 11:02:55 +02:00
5. Wait for the completion of the overcloud deployment process.