Install Db Monitor service

Prerequisites

Limitations and Expectations

The DB Monitor service is used for collecting and monitoring the MySQL NDB Cluster metrics. These Metrics are monitored and are used to raise the alerts when an anomaly occurs or when a potential failure is round the corner.

The below procedure are used to install the db monitor service

  1. All procedures in Bare Metal Installation Procedure is complete.
  2. The host running the docker image must have dockerMySQL NDB Cluster should be installed.
  3. A docker image named 'occne/db_monitor_svc' must be available in the customer repository.

All steps are executable from a SSH application (putty) connected laptop accessible via the Management Interface.

Procedure

Table B-17 Install Db Monitor service

Step No # Procedure Description
1.

Install Db Monitor Service
  1. Retrieve the Db Monitor Service docker image from docker registry to bastion host.

    1. Login to bastion host
    2. Pull the Db Monitor Service Docker image.
      $ docker pull <Docker_Common_registry:5000>/occne/db_monitor_svc:1.3.0
      $ docker tag <Docker_Common_registry:5000>/occne/db_monitor_svc:1.3.0 <bastion_host:5000>/occne/db_monitor_svc:1.3.0
      $ docker push <bastion_host:5000>/occne/db_monitor_svc:1.3.0
       
      For Example: if Docker_Common_registry is winterfell and bastion host is stark-bastion1
       
      $ docker pull winterfell:5000/occne/db_monitor_svc:1.3.0
      $ docker tag winterfell:5000/occne/db_monitor_svc:1.3.0 stark-bastion1:5000/occne/db_monitor_svc:1.3.0
      $ docker push stark-bastion1:5000/occne/db_monitor_svc:1.3.0
  2. Install Db Monitor Service using helm

    1. Update values.yaml file, update repository, tag, public IP of the SQL node (primary_sql_host_ip, secondary_sql_host_ip)
      $ cd <directory for Db Monitor Service>
      # update repository, tag, primary_sql_host_ip, secondary_sql_host_ip
      $ vi values.yaml
      image:
        repository: <bastion_host:5000>/occne/db_monitor_svc
        tag: 1.3.0
        pullPolicy: Always
       
      mysql:
        primaryhost: "primary_sql_host_ip"
        secondaryhost: "secondary_sql_host_ip"
        port: "3306"
    2. Run the HELM install command to install NF using HELM chart.
      $ cd <directory for Db Monitor Service>
      # HELM chart should be present in the repository with the chart name specified in the below command  
      $ helm install --name occne-db-monitor-svc --namespace occne-infra -f values.yaml
        
      Example:
      $ cd /home/admusr/db-monitor-service
      $ helm install --name occne-db-monitor-svc --namespace occne-infra -f values.yaml
2.

Verify Db Monitor Service Installation
  1. Once Db Monitor Service is installed using the above HELM Install command, Run the below command to check the status of Db Monitor Service.
    $ kubectl get pods --namespace=occne-infra
  2. To verify if the above command was executed successfully and whether the Db Monitor Service was installed properly, the output shown below can be taken as reference.
    NAME                   READY   STATUS    RESTARTS   AGE
    occne-db-monitor-svc    1/1     Running   0          98m