当前位置:网站首页>Prometheus deployment
Prometheus deployment
2022-06-24 16:37:00 【kevin_ yyc】
One 、 Environmental preparation
1、 Firewall configuration
The firewall is closed here , Or you can turn on the firewall 9100、9093 port [[email protected] ~]# systemctl stop firewall [[email protected] ~]# systemctl disable firewalld
2、selinux To configure
[[email protected] ~]# vim /etc/selinux/config SELINUX=disabled [[email protected] ~]# setenforce 0
3、 to update yum
[[email protected] ~]# yum update
Two 、Prometheus Deploy
1、 Download installation package
Download link :https://prometheus.io/download/
2、 Package decompression
tar xvfz prometheus-*.tar.gz
3、 To configure Prometheus monitor
cd prometheus-* [[email protected] prometheus-2.26.0.linux-amd64]# vi prometheus.yml # my global config global: scrape_interval: 15s # Set the scrape interval to every 15 seconds. Default is every 1 minute. evaluation_interval: 15s # Evaluate rules every 15 seconds. The default is every 1 minute. # scrape_timeout is set to the global default (10s). # Alertmanager configuration alerting: alertmanagers: - static_configs: - targets: - 172.16.1.x:9093 # Load rules once and periodically evaluate them according to the global 'evaluation_interval'. rule_files: - "rules/*_rules.yml" - "rules/*_alerts.yml" # A scrape configuration containing exactly one endpoint to scrape: # Here it's Prometheus itself. scrape_configs: # The job name is added as a label `job=<job_name>` to any timeseries scraped from this config. - job_name: 'prometheus' # metrics_path defaults to '/metrics' # scheme defaults to 'http'. static_configs: - targets: ['localhost:9090'] - job_name: 'linux172.16.1.4x' static_configs: - targets: ['172.16.1.4x:9100'] labels: instance: linux172.16.1.4x
4、 Deploy node_exporter
Download address :https://prometheus.io/download/
Download and upload installation package :node_exporter-1.1.2.linux-amd64.tar.gz [[email protected] prometheus]# tar -xzvf node_exporter-1.1.2.linux-amd64.tar.gz $ To configure node Boot up [[email protected] node_exporter-1.1.2.linux-amd64]# sudo groupadd -r prometheus [[email protected] node_exporter-1.1.2.linux-amd64]# sudo useradd -r -g prometheus -s /sbin/nologin -M -c "prometheus Daemons" prometheus [[email protected] node_exporter-1.1.2.linux-amd64]# cat << EOF > /usr/lib/systemd/system/node_exporter.service [Service] User=prometheus Group=prometheus ExecStart=/opt/prometheus/node_exporter-1.1.2.linux-amd64/node_exporter [Install] WantedBy=multi-user.target [Unit] Description=node_exporter After=network.target EOF $ start-up , Check the status , Configure boot up systemctl start node_exporter systemctl status node_exporter systemctl enable node_exporter
5、Master Node editing “prometheus.yml” increase “node_exporter”IP
[[email protected] plugins]# vi prometheus.yml - job_name: 'linux172.16.1.4x' static_configs: - targets: ['172.16.1.4x:9100'] labels: instance: 172.16.1.4x
6、 Hot update Prometheus.yml
curl -XPOST http://localhost:9090/-/reload
7、Web visit Prometheus Address :localhost:9090/targets
边栏推荐
- MySQL Advanced Series: locks - locks in InnoDB
- Handling of communication failure between kuberbetes pod
- Istio FAQ: virtualservice route matching sequence
- Mathematics in machine learning -- point estimation (IV): maximum posteriori probability (map)
- [go] concurrent programming channel
- The mystery of redis data migration capacity
- SQL multi table updating data is very slow
- Applet wxss
- Memo list: useful commands for ffmpeg command line tools
- A survey on dynamic neural networks for natural language processing, University of California
猜你喜欢

C. Three displays codeforces round 485 (Div. 2)

A survey on model compression for natural language processing (NLP model compression overview)

Applet wxss

C. K-th Not Divisible by n(数学+思维) Codeforces Round #640 (Div. 4)

Problems encountered in the work of product manager
![[go] concurrent programming channel](/img/6a/d62678467bbc6dfb6a50ae42bacc96.jpg)
[go] concurrent programming channel

Applet - use of template

There are potential safety hazards Land Rover recalls some hybrid vehicles

ZOJ - 4104 sequence in the pocket
MySQL進階系列:鎖-InnoDB中鎖的情况
随机推荐
An error is reported during SVN uploading -svn sqlite[s13]
Principle analysis of robot hardware in the loop system
Applet - use of template
Introduction of thread pool and sharing of practice cases
B. Ternary Sequence(思维+贪心)Codeforces Round #665 (Div. 2)
Bitwise Operators
Abnormal dockgeddon causes CPU 100%
Video structured intelligent analysis platform easycvr video recording plan function optimization / regularly delete expired videos
Dismantle the industrial chain of synthetic rubber industry, and the supply chain may become a sharp weapon for breakthrough
Tencent blue whale Zhiyun community version v6.0.3 was officially released together with the container management platform!
嵌入式开发基础之线程间通信
Where is the most formal and safe account opening for speculation futures? How to open a futures account?
What is a reptile
Goby+AWVS 实现攻击面检测
Finite element simulation in design
What is cloud development? Why cloud development? Talk about our story
Private domain defense in the cotton Era
Load MySQL table data consumption quick installation configuration through kafka/flink
C. Three displays codeforces round 485 (Div. 2)
对深度可分离卷积、分组卷积、扩张卷积、转置卷积(反卷积)的理解