Monitoring Grafana
Prometheus Install
1 - Download latest software version
wget https://github.com/prometheus/prometheus/releases/download/v2.30.2/prometheus-2.30.2.linux-amd642 - Unzip
tar -xvf prometheus-2.30.2.linux-amd64.tar.gz3 - Copying contents from the prometheus directory to the appropriate directory
sudo cp -r ./prometheus-2.30.2.linux-amd64 /usr/local/bin/prometheus4 - Remove downloaded files
rm prometheus-2.30.2.linux-amd64.tar.gz
rm -r prometheus-2.30.2.linux-amd645 - Creating service to run prometheus
5.1 - Create Prometheus Service File
5.2 - Reload daemons
6 - Execute the prometheus
7 - Checking if prometheus is really running
8 - Enabling service in boot
Node exporter install
1 - Download latest software version
2 - Unzip
3 - Copying contents from the node_exporter directory to the appropriate directory
4 - Remove downloaded files
5 - Creating service to run node_exporter
5.1 - Create Node exporter Service File
5.2 - Reload daemons
6 - Execute the node_exporter
7 - Checking if node_exporter is really running
8 - Enabling service in boot
Grafana Install
1 - Download latest software version and install
2 - Remove downloaded package
3 - Start grafana-server service
4 - Checking if grafana-server is really running
5 - Enabling service in boot
6 - Access Grafana


7 - Define Data Source




8 - Import Dashboard




Grafana Alerts
1 - Access the Alert menu and then click Admin

2 - Click the "Add Alertmanager" button

3 - Set the URL where your external alertmanager instance is installed and click on the "Add alertmanagers" button

4 - Access the panel inside the Dashboard that you want to add the alert, right-click on the panel and then click "Edit"

5 - Click the "Alert" tab and click the "Create alert rule from this panel" button to create an alert with a direct link to this panel.

6 - Define the name of the alert, the folder, the function, select the query and the limit that will be used for the alert.

7 - Set the field "evaluate every" and "for", if necessary add a custom label and then click "Save and exit"

Nginx Install and enable HTTPS connections with Let's Encrypt
Configuring names in hosts file
1 - Edit /etc/hosts file
2 - Test configuration with ping command
GitHub OAuth2 Authentication
1 - Register your application with GitHub







2 - Set root_url in grafana.ini file
3 - Enable GitHub in Grafana in grafana.ini file
4 - Restart grafana-server service
5 - After logout we have a login option with github

Last updated