Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 

OpenStack Services Monitoring Using Service Group Profiles

 

A service group tests the connectivity and latency between the Contrail Insights Agent and one or more endpoints. A service group consists of a list of endpoints with certain specifications. There are two ways to add service groups: either by using Ansible or the Contrail Insights Dashboard. To add service groups from the Dashboard, see Endpoint Monitoring with Service Groups.

Profile Overview

In the directory agent/tools/ansible/profiles/, there are five profiles, each pertaining to an OpenStack service. The prefix of each file is the name of the OpenStack service; either cinder, glance, keystone, neutron, or nova. The suffix is *_default_service_profile.json.j2. For example, the profile for the OpenStack service "Glance" is named glance_default_service_profile.json.j2.

The default layout of the "Glance" profile is shown. The other profiles have an identical layout, just with the corresponding OpenStack service listed:

Setting Up a Profile

Profiles support unauthenticated and authenticated endpoints.

Adding an Unauthenticated Endpoint

To add an unauthenticated endpoint, simply add the variable that the Url key is mapped to in your group_vars. Verify this variable is mapped to a working endpoint. For example, in the group_vars, if you are using the "Glance" profile, add the glance_url variable as shown:

Adding an Authenticated Endpoint

To add an endpoint that needs authentication, a RefreshToken is required. A refresh token enables access to endpoints that require authentication and retains that access by getting a new token when the current one is about to expire.

To procure a refresh token, set the RefreshToken field in the RefreshTokenData dictionary to be True. Then provide Username, Password, and AuthUrl in the same RefreshTokenData.

GET Example:

POST Example:

Adding a Profile to Ansible

Using Ansible, a profile corresponding to an OpenStack service can be added to the Contrail Insights Dashboard during installation.

To do this, add the variable appformix_service_connectivity_profiles: to your group_vars. The variable should be mapped to a list of dictionaries. Each dictionary in the list should only contain one key and one value. The key should always be connectivity_profiles. The value should be the path of the profile you want to be added to the Contrail Insights Dashboard during installation. Following is an example:

Note

In the example, the profile path is prefaced by ../../../. This is a necessary addition to the path of any profiles in the profiles/ directory. It is due to how the Contrail Insights Ansible structure is setup.

After the url and appformix_service_connectivity_profiles variables are added to group_vars, the specified profile will be added to the Contrail Insights Dashboard during installation.

Adding Multiple Profiles to Ansible

To add multiple profiles, simply repeat the previous steps for as many profiles as needed:

  1. Add url to group_vars.

  2. Add dictionary to appformix_service_connectivity_profiles variable in group_vars.