Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Info

The below steps and explanations are specific to Bahmni AWS Helm Charts Implementation of Grafana monitoring and Loki centralised logging.

Table of Contents

Introduction

The current Bahmni setup is using below tools for Monitoring & Observability:

...

2. Centralised Logging: https://grafana.com/oss/loki/ consisting of Promtail, Loki and https://grafana.com/
Grafana: Grafana is a multi-platform open source analytics and interactive visualisation web application. It provides charts, graphs, and alerts for the web when connected to supported data sources.

Loki: Loki is a horizontally scalable, highly available, multi-tenant log aggregation system inspired by Prometheus. It is designed to be very cost effective and easy to operate. It does not index the contents of the logs, but rather a set of labels for each log stream.

Bahmni setup

Bahmni is managing its monitoring & observability using the latest official helm-charts published & maintained by providers (Prometheus/Grafana). Bahmni comes with out of the box dashboards and metrics configured.

...

Currently all the kubernetes components & application logs for all namespaces are available in Loki.

Monitoring & Logging Installation:


🔸 Using Github Actions

You can fork the helm-umbrella-charts repository and run the Github actions workflow to provision infrastructure.

...

a) Deploy Monitoring and Logging: This pipeline would provision monitoring & logging resources using helm-charts.

...

Please refer the Bahmni-docker wiki page.

Steps for login Grafana

  1. Navigate to Bahmni-Lite Monitoring dashboard.

  2. Click on Sign in with Github.

  3. Authorise Bahmni Github to allow Github authorisation. You are IN (smile)

Viewing Grafana Dashboards

  1. To View dashboards, click on the below sign.

  2. This will open a search Dashboards.

...

For more deeper understanding about Grafana Dashboards & usage refer their official documentation.

Steps to view logs


1. Once logged in, navigate to Explore in Grafana.

...


Similarly can be done for other label as well.

...

Demo Video

To understand more details around how to use Monitoring & centralised Logging we have recorded the following DEMO on Youtube. This explains the login process & how to view logs. This is a demo that was done during the weekly PAT call some time ago.

...

Widget Connector
overlayyoutube
_templatecom/atlassian/confluence/extra/widgetconnector/templates/youtube.vm
width400px
urlhttps://www.youtube.com/watch?v=sz_Xw_jcdSY
height300px

(Duration: 20 mins)

...

Examples

Name

Query

1

QA server monitoring link

https://monitoring-lite.mybahmni.in/goto/OYnNoCKVz?orgId=1

2

QA server bahmni-web logs

(app: bahmni-web, namespace: qa)

3

QA server openmrs logs

(app: openmrs, namespace: qa)

4

All POST requests logs to QA server

Code Block
{namespace="ingress-nginx"} |= `POST` |= `qa.lite.mybahmni` != `monitoring.lite`
5

All OpenMRS Admin UI login requests on QA server

Code Block
{namespace="ingress-nginx"} |= `POST` |= `qa.lite.mybahmni` != `monitoring.lite` |= `/openmrs/ms/legacyui/loginServlet`

NOTE: Please contact Infra squad (Slack: #bahmni-infra) if you are facing any issues while accessing Grafana dashboards.