当前位置: 首页 > news >正文

建站平台 绑定域名网站提交

建站平台 绑定域名,网站提交,上海游玩攻略必去的地方,官方网站开发商环境部署,接着上一篇文章Docker容器部署(Cadvisor InfluxDBGrafana)开始 目录 1、先清理一下容器 2、部署Cadvisor 3、访问Cadvisor页面 4、部署Prometheus 5、准备配置 6、运行prometheus容器 7、访问prometheus页面 8、部署Grafan…

环境部署,接着上一篇文章Docker容器部署(Cadvisor +InfluxDB+Grafana)开始

目录

1、先清理一下容器

2、部署Cadvisor

3、访问Cadvisor页面

4、部署Prometheus

5、准备配置

6、运行prometheus容器

7、访问prometheus页面

8、部署Grafana 

9、配置Grafana

 10、测试


1、先清理一下容器

[root@localhost ~]# docker rm -f $(docker ps -aq)
11201213a39a
63844f017e3d
f70fa681a8ab
e729bfb694a1

2、部署Cadvisor

[root@localhost ~]# docker run -d \
> --volume=/:/rootfs:ro \
> --volume=/var/run:/var/run:ro \
> --volume=/sys:/sys:ro \
> --volume=/var/lib/docker/:/var/lib/docker:ro \
> --volume=/dev/disk/:/dev/disk:ro \
> --publish=8080:8080 \
> --detach=true \
> --name=cadvisor \
> google/cadvisor:latest
82cb584af19a643a643489ee43b6b9c461c5f5a78d24a36d613c8adb8fe6ef00

3、访问Cadvisor页面

4、部署Prometheus

[root@localhost ~]# docker pull prom/prometheus
Using default tag: latest
latest: Pulling from prom/prometheus
3cb635b06aa2: Pull complete 
34f699df6fe0: Pull complete 
33d6c9635e0f: Pull complete 
f2af7323bed8: Pull complete 
c16675a6a294: Pull complete 
827843f6afe6: Pull complete 
3d272942eeaf: Pull complete 
7e785cfa34da: Pull complete 
05e324559e3b: Pull complete 
170620261a59: Pull complete 
ec35f5996032: Pull complete 
5509173eb708: Pull complete 
Digest: sha256:cb9817249c346d6cfadebe383ed3b3cd4c540f623db40c4ca00da2ada45259bb
Status: Downloaded newer image for prom/prometheus:latest
docker.io/prom/prometheus:latest

5、准备配置

[root@localhost ~]# vim /tmp/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:# - alertmanager:9093# Load rules once and periodically evaluate them according to the global 'evaluation_interval'.
rule_files:# - "first_rules.yml"# - "second_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: ['localhost:9090']- job_name: 'docker'      ##定义一个叫docker的组static_configs:
- targets: ['192.168.147.139:8080']   ##填写一个或多个cadvisor的主机地址用逗号隔开

 

 

 

6、运行prometheus容器

[root@localhost ~]#  docker run -d \
> --name=prometheus  -p 9090:9090  \
> -v /tmp/prometheus.yml:/etc/prometheus/prometheus.yml \
>  -v /etc/localtime:/etc/localtime \
> prom/prometheus
d1cddcd4cbf4a8981dd8b9b6a68311c666d3434b12b354ef39dc04aa1c92a160
[root@localhost ~]# docker ps -a
CONTAINER ID   IMAGE                    COMMAND                   CREATED             STATUS          PORTS                                       NAMES
d1cddcd4cbf4   prom/prometheus          "/bin/prometheus --c…"   3 seconds ago       Up 3 seconds    0.0.0.0:9090->9090/tcp, :::9090->9090/tcp   prometheus
82cb584af19a   google/cadvisor:latest   "/usr/bin/cadvisor -…"   About an hour ago   Up 29 seconds   0.0.0.0:8080->8080/tcp, :::8080->8080/tcp   cadvisor

7、访问prometheus页面

进入Targets页面

 

看到docker组状态up为正常

查询项是可以查到数据的

8、部署Grafana 

[root@localhost ~]# docker run -d \
> --name=grafana \
> -p 3000:3000 \
> grafana/grafana
3478eb756c58868cd2a0f1492b68dca9ef52c91eb877a89ac2c2c51e222312af

9、配置Grafana

访问http://192.168.147.139:3000默认账户admin 密码 admin首次登陆需要修改密码

 

 

添加add data source

 

 

save test

 import

 

最下面选择prometheus再import

 

 10、测试

[root@localhost ~]# docker run --name=nginx -d -p 80:80 nginx
de08a1a9e25b0436ea2433166b69eea81afc3bca3c45ab8ab59515ec7ae80d33

 

保存就好了

 

 到此Cadvisor +Prometheus+Grafana基本架构部署完毕

http://www.mmbaike.com/news/101900.html

相关文章:

  • 上海哪家公司提供专业的网站建设百度百科词条入口
  • 东莞网站建设效果快速排名方案
  • 溧阳企业网站建设价格seo服务是什么
  • 政府网站 英文版 建设 需求好项目推荐平台
  • 电子商务网站的管理交换友情链接的途径有哪些
  • 纯js做网站黄冈黄页88网黄冈房产估价
  • 微信如何做商城网站seo搜索引擎优化心得体会
  • 如何加快网站打开速度网络推广学校
  • wordpress 餐饮订餐重庆seo什么意思
  • 上海网站建设引擎搜索大全
  • 一般网站用什么数据库最近新闻
  • 机加工如何用网站开发客户广州seo工程师
  • 网站友情链接 关键词经常改动怎么让百度收录我的网站
  • 做服务的网站吗网络推广有几种方法
  • 邯郸网站优化公司新手怎么入行seo
  • 电脑网站页面怎么调大小英文网站建设
  • 武汉学网站建设合肥网络seo
  • 滁州市建设工程管理处网站seo推广效果怎么样
  • 仙桃做网站建站模板哪个好
  • 做pc网站如何实时预览常用的网络推广的方法有哪些
  • 全屏网站大小网易疫情实时最新数据
  • 苏州电信网站备案如何开发网站平台
  • 做网站为什么能挣钱祁阳seo
  • 网站测试页面怎么做百度站长管理平台
  • pc做任务赚钱的网站提高工作效率英语
  • 网站开发的层级结构社群营销
  • 比较出名的网站域名在线咨询
  • 网站建设需要准备什么软件免费广告网
  • 网站登录页做多大尺寸的seo外链发布平台有哪些
  • 网站后台扫描插件网站品牌推广公司