OpenStack Victoria 集群部署 -prometheus监控接入- Ubuntu20.04

本文只是用做prometheus监控参考,非全面监控,请各位看官,根据实际环境进行调整。

1 环境准备

#系统环境

root@prometheus113:~# lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.2 LTS
Release:	20.04
Codename:	focal

#基础软件安装&ntp时间同步

sed -i 's/security.ubuntu.com/mirrors.ustc.edu.cn/g' /etc/apt/sources.list
sed -i 's/archive.ubuntu.com/mirrors.ustc.edu.cn/g' /etc/apt/sources.list
#刷新源
apt-get update

#安装基础软件

apt install net-tools wget vim bash-completion lrzsz unzip zip ntpdate -y

#ntp时间同步

#修改时区
sudo cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

ntpdate ntp3.aliyun.com 

echo "*/3 * * * * ntpdate ntp3.aliyun.com  &> /dev/null" > /tmp/crontab

crontab /tmp/crontab

#安装docker
#阿里脚本安装

curl -fsSL https://get.docker.com | bash -s docker --mirror Aliyun

or

apt install docker -y
apt install docker.io -y

2 配置安装prometheus-本机监控

#创建prometheus.yml,这里放在/data/prometheus文件目录下,这个配置用来监控本机
#vim /data/prometheus/prometheus.yml

global:
  scrape_interval:     15s # Set the scrape interval to every 15 seconds. Defaul
  evaluation_interval: 15s # Evaluate rules every 15 sec
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值