DalgoT4D / maintenance

maintenance scripts for our ec2 machines
0 stars 0 forks source link

monitor everything machine with grafana #31

Closed fatchat closed 2 months ago

fatchat commented 2 months ago

infra metrics from prometheus

@Ishankoradia can you guide himanshu through this please

fatchat commented 2 months ago

https://jayanthkumar777.hashnode.dev/comprehensive-guide-to-monitoring-infrastructure-databases-django-app-metrics-with-grafana-and-prometheus

himanshudube97 commented 2 months ago

@fatchat

image

Current setup-> One instance of Prometheus and Grafana on everything machine and Multiple node-exporter instances.

Prometheus pulls (or scrapes) the data from Node Exporter.

How to setup the grafana dashboard for future machines->

  1. Install Node Exporter on the machine you want to monitor.
  2. Ensure Node Exporter is running and accessible on port 9100
  3. Configure the prometheus.yml file on the EVERYTHING machine.
  4. Add the IP address of the new machine under the _scrapeconfigs section with the port Node Exporter is running on. :9100
  5. Save and restart Prometheus.
  6. Go to https://grafana.projecttech4dev.org/ OR localhost:3000/ there you will see a list of node-exporter ips under the Host dropdown. Select the one which you want to monitor.

P.S: To access the grafana , prometheus, node-exporter locally on our system, we will have to do the port forwarding from the remote machine.