最近和朋友一起做的监控配置,拿出来共享一下

1.下载prometheus安装包(linux版)到 /opt/minitor/prometheus 。

下载地址:https://download.csdn.net/download/a15565772151/11111904

不知道为啥,csdn没法自己设置不需要积分了,可能是我没找到在哪里操作,可以私聊我一下我发你资源

2.运行 tar -zxvf prometheus-2.0.0.linux-amd64.tar.gz ,解压文件到当前目录。

3.执行 vim /opt/minitor/prometheus/prometheus.yml。 如果vim不可用,可以使用vi,这里使用vim主要是为了好看。额。。。。或者可以yum install vim

# my global config
global:
scrape_interval: 5s # Set the scrape interval to every 15 seconds. Default is every 1 minute.
evaluation_interval: 5s # 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: ['localhost:9093'] # Load rules once and periodically evaluate them according to the global 'evaluation_interval'.
rule_files:
# - "/opt/prometheus/prome/prometheus-2.0.0.linux-amd64/rules/rules.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: ['ip地址:9090']
labels:
instance: prometheus

一定要注意缩进,同一级别的一定得对其

4.启动prometheus。

nohup ./prometheus --config.file=prometheus.yml --web.listen-address=:9090 &

5.去prometheus自带的web页面上查看  http://IP地址:9090/graph

6.prometheus状态为up,说明配置成功。

监控服务器配置(一)-----Prometheus安装配置的更多相关文章

  1. 监控服务器配置(四)-----OracleDb_exporter安装配置

    1.下载oracle客户端安装包(linux版)到 /opt/minitor/oracleDb . 下载地址:https://download.csdn.net/download/a155657721 ...

  2. 监控服务器配置(二)-----Grafana安装配置

    1.下载grafana安装包(linux版)到 /opt/minitor/grafana . 下载地址:https://download.csdn.net/download/a15565772151/ ...

  3. 监控服务器配置(三)-----Node_exporter安装配置

    此安装主要是为了监控服务器运行状况 1.下载node_exporter安装包(linux版)到 /opt/minitor/node_exporter . 下载地址:https://download.c ...

  4. 监控服务器配置(五)-----Redis_exporter安装配置

    1.下载redis_exporter安装包(linux版)到 /opt/minitor/redis_exporter . 下载地址:https://download.csdn.net/download ...

  5. Icingaweb2监控oracle数据库的安装配置流程

    Icinga2安装配置check_oracle_health流程 1.安装 由于check_oracle_health是使用perl语言编写的,因此在安装该插件之前,首先要安装oracle的客户端实例 ...

  6. Prometheus安装配置

    一.什么是Prometheus? Prometheus受启发于Google的Brogmon监控系统(相似的Kubernetes是从Google的Brog系统演变而来),从2012年开始由前Google ...

  7. 【ZABBIX】SNMPtrap实现主动监控的原理与安装配置

    工欲善其事,必先利其器.作为一款强大的开源软件,Zabbix号称“Monitor Everything”,其所依赖的,很大程度上便是SNMP的数据采集支持.SNMP 协议是用来管理设备的协议,目前SN ...

  8. 天兔(Lepus)监控邮件推送安装配置

    好吧,我承认官网的邮件配置教程我又没看懂,这里记录下我的配置方法 [root@HE3]# vi /usr/local/lepus/test_send_mail.py #!/usr/bin/envpyt ...

  9. Apache ActiveMQ实战(1)-基本安装配置与消息类型

    ActiveMQ简介 ActiveMQ是一种开源的,实现了JMS1.1规范的,面向消息(MOM)的中间件,为应用程序提供高效的.可扩展的.稳定的和安全的企业级消息通信.ActiveMQ使用Apache ...

随机推荐

  1. struct 对齐和补齐原则

    // 对齐原则:每一成员需对齐为后一成员类型的倍数 // 补齐原则:最终大小补齐为成员类型最大值的倍数 struct A {  int a;     // 4  short b;   // (4) + ...

  2. CVTE前端一面

    1.如果不设置cookie失效时间:  关闭浏览器自动关闭. 有没有手写过cookie HttpOnly 2.跨域的几种方式 如何实现cors 2.web安全: xss,csrf    如何防范 3. ...

  3. Oracle 生成Guid;Oracle 生成多个Guid;Oracle 生成带''-"的Guid

    Oracle 生成Guid select sys_guid() from dual Oracle 生成多个Guid Oracle 生成带''-"的Guid , ) , ) || '-' || ...

  4. vue+axios完美实现前端路由拦截

    一.路由拦截 1.首先在router的index.js里配置一个自定义字段requireAuth,用该字段来判断进入该路由是否需要登录.如果已经登陆则进入该路由,反之则进入登录页面. 如图是路由配置: ...

  5. maven 版本发布添加上时间戳

    使用插件添加时间戳 我使用的是spring boot - 2.0.3.RELEASE版本 pom中加入 <!-- 加入这个 就可以直接在配置文件中取到时间戳了,注意: 由于${}方式会被mave ...

  6. LeetCode 24. Swap Nodes in Pairs 成对交换节点 C++/Java

    Given a linked list, swap every two adjacent nodes and return its head. You may not modify the value ...

  7. 2522 和为K的倍数

    2522 和为K的倍数 2 秒 262,144 KB 10 分 2 级题   小b喜欢和为K的倍数的序列. 现在有一个长度为n的序列A,请问A有多少个非空连续子序列是小b喜欢的. 收起   输入 第一 ...

  8. zabbix解决监控图中出现中文乱码问题

    首先确定zabbix开启了中文支持功能:登录到zabbix服务器的数据目录下(前面部署的zabbix数据目录是/data/www/zabbix),打开 locales.inc.php文件[root@Z ...

  9. easyUI 学习

    )省份-城市-区域三级联动[struts2 + ajax +非数据库版] (1)省份-城市-区域,基于jQuery的AJAX三级联动,用Struts2整合AJAX[非数据库版] $.ajax( { t ...

  10. MySQL后台线程整理总结

    本文整理自<MySQL技术内幕 InnoDB存储引擎> MySQL通过后台各种线程.内存池.文件交互来实现对外服务的,不同线程实现不同的资源操作,各个线程相互协助,共同来完成数据库的服务. ...