π Install Prometheus Server
π Overview
There are two ways to deploy Prometheus Server:
- Manual Download the installation script and define Environment Variable
- Upload the install script from EdgeHit Controller that presets all the Necessary Value
Both way are invoking the installation Script at
The generated script from EdgeHit Controller is just a Script that predifine Environment Variable and run the script above.Note
Node-Exporter are installed to EdgeHit Controller and Load Proxy with Authentication using HTTP AUTH. Therefore the Prometheus Server needs to be configured with the coresponding PSK for each target
For reference, below shows what are the Environment Variable defined in install-prometheus.sh:
| Variable | Configured Value |
|---|---|
| DASH_SERVER_DOMAIN | same as the value defined during EdgeHit Controller installation |
| DASH_HTTP_AUTH_PASS | PSK generated for HTTP AUTH of Node-Exporter running on EdgeHit Controller |
| EDGE_HTTP_AUTH_PASS | PSK generated for HTTP AUTH of Node-Exporter running on Load Proxy |
| PROM_SERVER_DOMAIN | same as DASH_SERVER_DOMAIN |
Info
You need to change the PROM_SERVER_DOMAIN value to match the Domain Name of the Prometheus Server if it is not deployed on EdgeHit Controller.
The best way to install Prometheus server is by using the install-prometheus.sh on EdgeHit Controller.
πͺ Installation Step
-
Defining Prometheus Server Domain Name before installation
install-prometheus.shassume that Prometheus Server is Downloaded to EdgeHit Controller by default. In production Environment. You need to change Environement Value to Domain Name pointing to the taget installation Server.Redundant Prometheus Target Scenario
The installation Script itself contain a Node-Exporter Installation. If the Prometheus Server is installed on EdgeHit Controller, it will result in two Node-Exporter instance on the Same Machine
For reference, you need to change the value below for the script
Environment Variable Value PROM_SERVER_DOMAIN Domain Name of Installation Target
2. Upload the Script to Target Machine
-
Execute the script
-
Once the installation is done, installation info and administrative tools will be stored in
/usr/local/edgehit/prometheus/the directory content will be similiar as below: -
.envcontain secret value such as the PSK for Connecting to Node-Exporter using HTTP-AUTH that is mounted to docker container runtime -
install-info.txtcontain info such as default user and password for Grafana, Prometheus, and Alert Manager Web Dashboard
-
After installation, you can configure the initial setting of the prometheus and grafana server. Detail will be discussed in Configuring Prometheus Target section.