Get the App
SLTechnology News&Howtos  ›  Servers  › 

How to use Grafana to monitor Docker in Ubuntu

Shulou Source: shulou.com Published: 2022-06-01 23:24:19 10月02日 Update

How to use Grafana to monitor Docker in Ubuntu? I believe that many inexperienced people are at a loss about this, so this article summarizes the causes and solutions of the problem. Through this article, I hope you can solve this problem.

Install grafana

We can build our grafana in docker. There is an official grafana docker image.

Run the following command to build the grafana container.

1 2 3 4 5 6 7 8 9root@ubuntu:~# docker run-d-p 3000 influxdb_host=localhost-e influxdb_port=8086-e influxdb_name=cadvisor-e influxdb_user= root-e influxdb_pass=root-- link influxsrv:influxsrv-- name grafana grafana/grafana f3b7598529202b110e4e6b998dca6b6e60e8608d75dcfe0d2b09ae408f43684a

Now we can log in to grafana to configure the data source. Visit http:// your ip address: 3000 or http:// your ip address (if you have done port mapping earlier):

User name-admin

Password-admin

Once we have installed grafana, we can connect to influxdb. Log in to the dashboard and click the grafana icon (the fireball) in the upper left corner of the panel. Click the data source (data sources) to configure.

Addingdatabsource

Now you can add a new graphic (graph) to our default data source, influxdb.

Panelgraph

We can adjust our graphics by editing and adjusting our query on the metric page.

Grafana-grafana dashboard 2016-08-01 14-53-40

After reading the above, have you mastered how to use Grafana to monitor Docker in Ubuntu? If you want to learn more skills or want to know more about it, you are welcome to follow the industry information channel, thank you for reading!

Tags: Data data source monitoring content graphics address method more problem login adjustment configuration helpless for this instrument dashboard reason can be passed command icon Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Microsoft Redmi NVidia Huawei Docker