🚀Day 76: Build a Grafana dashboard😃

¡

2 min read

🚀Day 76:  Build a Grafana dashboard😃

Welcome back to the #90DaysOfDevOps Challenge. On Day 76, we’ll dive into the exciting world of Grafana dashboards. Grafana dashboards provide an intuitive and visual way to monitor your data, presenting it through various visualizations and panels. Let’s learn how to build a Grafana dashboard step by step!

Grafana Dashboard

A Grafana dashboard offers a comprehensive view of your data, allowing you to track metrics and trends through different visualizations. Dashboards are made up of panels, each representing a specific aspect of the data story you want to convey. Each panel consists of a query, defining the data you wish to display, and a visualization, defining how the data is presented.

Task: Build a Simple Grafana Dashboard

  1. In the sidebar, hover your cursor over the Create (plus sign) icon and then click “New Dashboard”.

2. Click “Add visualization” and select Prometheus as your data source.

3. In the Query editor below the graph, enter the below query and then press Shift + Enter:

 100 - (avg by(instance) (irate(node_cpu_seconds_total{mode="idle"}[5m])) * 100)

4. This query calculates the CPU usage percentage by subtracting the average idle CPU time (node_cpu_seconds_total) from 100.

5. In the Panel editor on the right, under Settings, change the panel title to “CPU Usage Percentage”.

6. Click “Apply” in the top-right corner to save the panel and go back to the dashboard view.

7. Click the “Save dashboard” (disk) icon at the top of the dashboard to save your dashboard.

8. Enter a name in the Dashboard name field and then click Save.

Congratulations! You’ve successfully built a simple Grafana dashboard with the CPU usage percentage. Grafana’s powerful visualization and customization options enable you to create informative and visually appealing dashboards for monitoring and analyzing your data.

Stay tuned for Day 77 of the #90daysofdevops challenge, where we’ll explore Alerting and Grafana Cloud.

I hope you learned something from this blog. If you have, don’t forget to follow & show your support 😄. Subscribe to my blogs so that you won’t miss any future posts.

If you have any questions or feedback, feel free to leave a comment below. Thanks for reading and have an amazing day ahead!

Â