Grafana

Version 18.1 by Peter Wurbs on 2025/04/10 08:23

Grafana Icon Logo PNG vector in SVG, PDF, AI, CDR format

Content

Introduction

Grafana is an open-source platform for monitoring and visualizing time-series data from sources like Prometheus, Loki, Databases etc. It allows users to create interactive dashboards and alerts to track system performance and trends in real time.

Vendor Page

There is good documentation to start using Grafana:

Grafana Documentation

Grafana Tutorials

There is a great possibility to play with Grafana using the Grafana Playground

Accessing Grafana

  • Grafana as part of the DevOps-as-a-Service toolchain can be accessed by either
  • Preconditions in DevOps portal to access Grafana:
    • A Grafana license must be assigned to the user
    • Grafana must be added to the tool list of the project
  • If you are not already logged in to another tool in the toolchain, then you have to login using your configured SSO credentials.
  • When you see this message after entering your credentials, then you don't have a Grafana license assigned in the DevOps portal:
    1744266590219-161.png

Users, Projects, Organizations and Roles

  • Projects, users and their roles in projects are managed in the DevOps portal, the corresponding functions in Grafana are disabled (UI and API)
  • Projects in DevOps portal are mapped to Organizations in Grafana. This means, when there is a new project in the portal having Grafana as a configured tool, then there is a new Grafana "Org". Users assigned to a project in the portal are then assigned to a Grafana Org applying the configured roles.
    • Role mapping: 
      Project Role in DevOps PortalGrafana Organization RolePermissions in Grafana
      ViewerViewerCan view dashboards and alerts
      Developer / MasterEditorCan create/edit dashboards and alerts and use the Explore function
      AdminAdminHas full permissions within the Grafana org, e.g. can setup datasources, manage folders, teams and service accounts

      A detailed description of the Grafana role model can be found here.

  • There is an additional permission management possible on folder level. A folder contains a set of dashboards. A project admin can create folders and manage specific permissions for this folder using Grafana. See this link for further information. Folder permissions management is out of scope of the user management in the DevOps portal.
  • A project admin is entitled to create and manage "Service Accounts" in Grafana and grant permissions in the specific organization. A Service Account belongs to an Organization (Project) and not to an user. Service Accounts can be used for systems which want to work wit the Grafana API for any automation purposes. See this link for further information. Service Account management is done directly in Grafana and is out of scope of the user management in the DevOps portal.
  • If you are assigned to more than one project in the DevOps portal, having Grafana configured as tool, then you can switch between Organizations in Grafana. Go to the top left corner, click on the Org list and select any other Grafana Organization (project), you want to switch to.
    When you work in Grafana, always make sure that you chose the intended Organization.
    1744272203893-682.png

Main Functions

Datasources

  • Before you can setup dashboards and alerts, you have to setup datasources. Grafana itself is only a visualization tool, for data gathered via datasources.
  • Datasources are created/managed per Grafana Organization.
  • The Admin role is required to setup and manage datasources.
  • When a datasource is available in an Organization, every user assigned to this Organization (Project) with Admin or Edit role can access/explore the data provided by this datasource. 

  • Most common datasources are configured for
    • Prometheus to visualize metrics
    • Loki to search and visualize logs
    • MySQL, PostgreSQL to access and visualize database data
  • Many possible datasource types are preinstalled as built-in plugins and can be used
  • Datasource are set up via menu panel --> Connections --> Datasources
    1744273328067-517.png
  • Detailed information can be found via this link.