#sudo wget https://github.com/prometheus/prometheus/releases/download/v2.33.1/prometheus-2.33.1.linux-amd64.tar.gz

#tar xvfz prometheus-2.33.1.linux-amd64.tar.gz

#sudo mv prometheus-2.33.1.linux-amd64 /opt/prometheus

#sudo useradd -rs /bin/false prometheus

#sudo chown -R prometheus:prometheus /opt/prometheus

#cat /opt/prometheus/prometheus.yml

Create a systemd service file for Prometheus;

#sudo nano /etc/systemd/system/prometheus.service

Add the following content:

[Unit]
Description=Prometheus
Wants=network-online.target
After=network-online.target

[Service]
User=prometheus
Group=prometheus
Type=simple
ExecStart=/opt/prometheus/prometheus --config.file=/opt/prometheus/prometheus.yml --storage.tsdb.path=/opt/prometheus/data

[Install]
WantedBy=multi-user.target

#sudo systemctl daemon-reload
#sudo systemctl start prometheus
#sudo systemctl enable prometheus


http://localhost:9090

One response to “PROMETHEUS-INSTALLATION;”

  1. […] INSTALLATION-PROMOTHEUS […]

    Like

Leave a comment

Recent posts

Quote of the week

in learning you will teach and in teaching you will learn

~ Phil Collins
Design a site like this with WordPress.com
Get started