Prometheus: Unterschied zwischen den Versionen

Aus Info-Theke
Zur Navigation springen Zur Suche springen
(Die Seite wurde neu angelegt: „Kategorie:ServerApplikation = Installation = <syntaxhighlight lang="bash"> apt install prometheus </syntaxhighlight>“)
 
 
(3 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt)
Zeile 3: Zeile 3:
= Installation =
= Installation =
<syntaxhighlight lang="bash">
<syntaxhighlight lang="bash">
apt install prometheus
apt install prometheus gnupg2 curl software-properties-common
curl -fsSL https://packages.grafana.com/gpg.key | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/grafana.gpg
add-apt-repository "deb https://packages.grafana.com/oss/deb stable main"
apt update && apt -y install grafana
systemctl start grafana-server
</syntaxhighlight>
</syntaxhighlight>
= Konfiguration =
* /etc/prometheus/prometheus.yaml
<pre>
openssl req -new -newkey rsa:2048 -days 365 -nodes -x509 -keyout node_exporter.key -out node_exporter.crt \
  -subj "/C=DE/ST=Bavaria/L=infeos/O=infeos.de/OU=IT/CN=prometheus.infeos.de" \
  -addext "subjectAltName = IP:167.86.105.27"
</pre>
* /etc/default/prometheus
<pre>
ARGS="--web.listen-address=19090"
</pre>
* /etc/grafana/grafana.ini
= Dateien/Verzeichnisse =
* /lib/systemd/system/prometheus.service

Aktuelle Version vom 14. Februar 2023, 18:01 Uhr


Installation[Bearbeiten]

apt install prometheus gnupg2 curl software-properties-common
curl -fsSL https://packages.grafana.com/gpg.key | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/grafana.gpg
add-apt-repository "deb https://packages.grafana.com/oss/deb stable main"
apt update && apt -y install grafana
systemctl start grafana-server

Konfiguration[Bearbeiten]

  • /etc/prometheus/prometheus.yaml
openssl req -new -newkey rsa:2048 -days 365 -nodes -x509 -keyout node_exporter.key -out node_exporter.crt \
  -subj "/C=DE/ST=Bavaria/L=infeos/O=infeos.de/OU=IT/CN=prometheus.infeos.de" \
  -addext "subjectAltName = IP:167.86.105.27"
  • /etc/default/prometheus
ARGS="--web.listen-address=19090"
  • /etc/grafana/grafana.ini

Dateien/Verzeichnisse[Bearbeiten]

  • /lib/systemd/system/prometheus.service