User-Profile-Image
hankin
  • 5
  • centos7
  • docker
  • mysql
  • PostgreSQL
  • git/gitlab
  • ELK
  • python
    • python-Tornado
    • python-django
  • redis
  • nginx
  • kvm
  • proxmox
  • mongo
  • kubernetes
  • prometheus
  • GlusterFs
  • nfs
  • freeswitch
  • httpd
  • shell脚本
  • linux
  • fastdfs
  • nextcloud
  • openssl
  • openvpn
  • rabbitmq
  • sqlite
  • svn
  • java
  • ubuntu
  • vue2
  • wordpress
  • php
  • IOT物联网
  • 项目
  • 故障处理
  • 树莓派
  • 博客存档
  • 未分类
  • 杂项
  • #1742(无标题)
  • 新视野
  • 分类
    • 项目
    • 树莓派
    • 杂项
    • 未分类
    • 新视野
    • 故障处理
    • 博客存档
    • 交换机
    • wordpress
    • vue2
    • ubuntu
    • svn
    • sqlite
    • shell脚本
    • redis
    • rabbitmq
    • python-django
    • python
    • proxmox
    • prometheus
    • PostgreSQL
    • php
    • openvpn
    • openssl
    • nginx
    • nfs
    • nextcloud
    • mysql
    • mongo
    • linux
    • kvm
    • kubernetes
    • java
    • IOT物联网
    • httpd
    • GlusterFs
    • git/gitlab
    • freeswitch
    • fastdfs
    • ELK
    • docker
    • centos7
  • 页面
    • #1742(无标题)
  • 友链
      请到[后台->主题设置->友情链接]中设置。
Help?

Please contact us on our email for need any support

Support
    首页   ›   prometheus   ›   正文
prometheus

prometheus-operator部署

2022-10-28 23:33:37
958  0 0

在k8s上部署prometheus

环境
k8s版本 1.23.5
准备
下载镜像
git clone https://github.com/coreos/kube-prometheus

替换镜像
vim kubeStateMetrics-deployment.yaml
      修改 image: k8s.gcr.io/kube-state-metrics/kube-state-metrics:v2.3.0
      为   image: quay.io/coreos/kube-state-metrics
vim prometheusAdapter-deployment.yaml
      修改 image: k8s.gcr.io/prometheus-adapter/prometheus-adapter:v0.9.1
      为   image: directxman12/k8s-prometheus-adapter-amd64
修改services端口,直接暴露到主机
type: NodePort           
  nodePort: 30xxx
安装
kubectl create -f manifests/setup/
kubectl apply -f manifests/
temp-镜像下载太慢
可手动下载镜像,复制到每台主机
docker pull quay.io/prometheus/prometheus:v2.37.0
docker pull quay.io/prometheus/alertmanager:v0.24.0
docker save -o
docker load -i
scp -PXX ip:/xxx
测试
浏览器可能无法直接访问到内网服务器上的grafana,使用xshell代理下grafana的端口到本地即可访问
配置数据源
参考https://www.cnblogs.com/tangshow/p/16374897.html
其中需要注意 数据库的ip地址和端口设置成 services集群ip和端口

导入模板
参考https://www.cnblogs.com/tangshow/p/16374897.html
模板id    13105 15661

评论 (0)

点击这里取消回复。

欢迎您 游客  

Copyright © 2025 网站备案号 : 蜀ICP备2022017747号
smarty_hankin 主题. Designed by hankin
主页
页面
  • #1742(无标题)
博主
tang.show
tang.show 管理员
linux、centos、docker 、k8s、mysql等技术相关的总结文档
213 文章 2 评论 201641 浏览
测试
测试