Chapter 2. Installing Metrics Store Prerequisites Computing resources: 4 CPU cores 30 GB RAM 500 GB SSD disk For the Metrics Store Installer virtual machine: 4 CPU cores 8 GB RAM Note The computing resource requirements are for an all-in-one installation, with a single Metrics Store virtual machine. The all-in-one installation can collect data from up to 50 hosts, each running 20 virtual machines. Operating system: Red Hat Enterprise Linux 7.7 or later Software: Red Hat Virtualization 4.3.5 or later Network configuration: see Configuring networking for Metrics Store virtual machines 2.1. Creating the Metrics Store virtual machines To create the Metrics Store virtual machines, perform the following tasks: Configure the Metrics Store installation. Create the following Metrics Store virtual machines: The Metrics Store Installer virtual machine - a temporary virtual machine for deploying Red Hat OpenShift and services on the Metrics Store virtual machines. One or more Metrics Store virtual machines. Verify the Metrics Store virtual machines. 2.1.1. Configuring the Metrics Store installation Procedure Log in to the Manager machine using SSH. Update the packages: Copy metrics-store-config.yml.example to create metrics-store-config.yml : Edit the parameters in metrics-store-config.yml to match your installation environment, and save the file. The parameters are documented in the file. To set the logical network that is used for the metrics-store-installer and Metrics Store virtual machines, add the following lines to metrics-store-config.yml : On the Manager machine, copy /etc/ovirt-engine-metrics/secure_vars.yaml.example to /etc/ovirt-engine-metrics/secure_vars.yaml : Edit the parameters in /etc/ovirt-engine-metrics/secure_vars.yaml to match the details of your specific environment. Encrypt the secure_vars.yaml file: 2.1.2. Creating Metrics Store virtual machines Procedure Go to the ovirt-engine-metrics directory: Run the ovirt-metrics-store-installation playbook to create the virtual machines: Note To enable verbose mode for debugging, add -vvv to the end of the command, or add '-v' to enable light verbose mode, or add -vvvv to enable connection debugging. For more extensive debugging options, enable debugging through the Ansible playbook as described in Enable debugging via Ansible playbook 2.1.3. Verifying the creation of the virtual machines Procedure Log in to the Administration Portal. Click Compute Virtual Machines to verify that the metrics-store-installer virtual machine and the Metrics Store virtual machines are running. 2.1.4. Changing the default LDAP authentication identity provider (optional) In the standard Metrics Store installation, the allow_all identity provider is configured by default. You can change this default during installation by configuring the openshift_master_identity_providers parameter in the inventory file integ.ini . You can also configure the session options in the OAuth configuration in the integ.ini inventory file. Procedure Locate the integ.ini in the root directory of the metrics-store-installer virtual machine. Follow the instructions for updating the identity provider configuration in Configuring identity providers with Ansible . 2.2. Configuring networking for Metrics Store virtual machines 2.2.1. Configuring DNS resolution for Metrics Store virtual machines Procedure In the metrics-store-config.yml DNS zone parameter, public_hosted_zone should be defined as a wildcard DNS record ( *. example.com ). That wildcard DNS should resolve to the IP address of your master0 virtual machine. Add the hostnames of the Metrics Store virtual machines to your DNS server. 2.2.2. Setting a static MAC address for a Metrics Store virtual machine (optional) Procedure Log in to the Administration Portal. Click Compute Virtual Machines and select a Metrics Store virtual machine. In the Network Interfaces tab, select a NIC and click Edit . Select Custom MAC Address , enter the MAC address, and click OK . Reboot the virtual machine. 2.2.3. Configuring firewall ports The following table describes the firewall settings needed for communication between the ports used by Metrics Store. Table 2.1. Configure the firewall to allow connections to specific ports ID Port(s) Protocol Sources Destinations Purpose MS1 9200 TCP RHV Red Hat Virtualization Hosts RHV Manager Metrics Store VM Transfer data to ElasticSearch. MS2 5601 TCP Kibana user Metrics Store VM Give users access to the Kibana web interface. Note Whether a connection is encrypted or not depends on how you deployed the software. 2.3. Deploying Metrics Store services on Red Hat OpenShift Deploy and verify Red Hat OpenShift, Elasticsearch, Curator (for managing Elasticsearch indices and snapshots), and Kibana on the Metrics Store virtual machines. Procedure Log in to the metrics-store-installer virtual machine. Run the install_okd playbook to deploy Red Hat OpenShift and Metrics Store services to the Metrics Store virtual machines: Note To enable verbose mode for debugging, add -vvv to the end of the command, or add '-v' to enable light verbose mode, or add -vvvv to enable connection debugging. Verify the deployment by logging in to each Metrics Store virtual machine: Log in to the openshift-logging project: Check that the Elasticsearch, Curator, and Kibana pods are running: If Elasticsearch is not running, see Troubleshooting related to ElasticSearch in the OpenShift Container Platform 3.11 documentation. Check the Kibana host name and record it so you can access the Kibana console in Chapter 4, Verifying the Metrics Store installation : Cleanup Log in to the Administration Portal. Click Compute Virtual Machines and delete the metrics-store-installer virtual machine.

Commands:
yum update
cp /etc/ovirt-engine-metrics/metrics-store-config.yml.example /etc/ovirt-engine-metrics/config.yml.d/metrics-store-config.yml
ovirt_template_nics - the following are the default values for setting the logical network used by the metrics_store_installer and the Metrics Store virtual machines ovirt_template_nics: - name: nic1 profile_name: ovirtmgmt interface: virtio
cp /etc/ovirt-engine-metrics/secure_vars.yaml.example /etc/ovirt-engine-metrics/secure_vars.yaml
ansible-vault encrypt /etc/ovirt-engine-metrics/secure_vars.yaml
cd /usr/share/ovirt-engine-metrics
ANSIBLE_JINJA2_EXTENSIONS="jinja2.ext.do" ./configure_ovirt_machines_for_metrics.sh --playbook=ovirt-metrics-store-installation.yml --ask-vault-pass
ANSIBLE_CONFIG="/usr/share/ansible/openshift-ansible/ansible.cfg" ANSIBLE_ROLES_PATH="/usr/share/ansible/roles/:/usr/share/ansible/openshift-ansible/roles" ansible-playbook -i integ.ini install_okd.yaml -e @vars.yaml -e @secure_vars.yaml --ask-vault-pass
oc project openshift-logging
oc get pods
oc get routes