- 浏览: 610296 次
- 性别:
- 来自: 杭州
文章分类
- 全部博客 (334)
- java core (12)
- struts2.x (2)
- spring (3)
- hibernate (8)
- jpa (6)
- maven (2)
- osgi (5)
- eclipse (4)
- struts2.x+spring2.x+hibernate 整合 (5)
- ebs (0)
- html (0)
- vaadin (1)
- css (0)
- jquery (0)
- javascript (0)
- svn (1)
- cvs (0)
- axas2.x (0)
- eclipse+maven (9)
- annotation (0)
- 基于OSGi的动态化系统搭建 (1)
- notenet (1)
- jboss eclipse (4)
- eclipse工具 (4)
- jdk1.6+maven3.0.3+nuxeo+svn+felix+cxf+spring+springDM (6)
- spring dm (1)
- Nexus介绍 (1)
- proxool listener (0)
- oracle (4)
- mysql (8)
- 搭建你的全文检索 (1)
- hibernatehibernatehibernate (0)
- cvsearchcvsearch (0)
- mycvseach (0)
- asdfasdfasdf (0)
- propertiey (0)
- hibernate annotation (0)
- libs (0)
- icam (2)
- start 数据库配置 (0)
- jboss (1)
- 让Eclipse启动时显示选择workspace的对话框 (1)
- table表头固定 (1)
- s2s3h4 (0)
- leaver (0)
- mycvsaerchddd (0)
- 关于jboss5.0.1部署 (4)
- bookmarks (0)
- PersistenceUnitDeployment (0)
- mycom (0)
- HKEY_CURRENT_USER = &H80000001 (0)
- syspath (1)
- css div (1)
- Dreamweaver CS5 (0)
- generate (0)
- mysql查看表结构命令 (1)
- LOG IN ERROR EMAIL TO SB (0)
- struts2 handle static resource (1)
- jsf (2)
- log4j (1)
- jbpm4.4 (2)
- down: jbpm4.4 (1)
- jstl1.2 (1)
- spring annotation (1)
- java design pattern (1)
- cache (1)
- ehcache (1)
- 11111 (0)
- myge (0)
- pom.xml (0)
- springquartz (0)
- OpenStack (9)
- hadoop (2)
- nginx (1)
- hadoop openstack (1)
- os (1)
- hadoop-2.6.0 zookeeper-3.4.6 hbase-0.98.9-hadoop2 集群 (5)
- hadoop2.7.0 ha Spark (2)
- tess (0)
- system (1)
- asdf (0)
- hbase (2)
- hbase create table error (1)
- ekl (1)
- gitignore (1)
- gitlab-ci.yml (1)
- shell (1)
- elasticsearch (2)
- Azkaban 3.0+ (1)
- centos用命令 (1)
- hive (1)
- kafka (1)
- CaptureBasic (0)
- CentOS7 (1)
- dev tools (1)
- README.md (1)
- Error (1)
- teamviewerd.service (1)
- scala (1)
- spark (1)
- standard (1)
- gitlab (1)
- IDEA (0)
- ApplicationContext (1)
- 传统数仓 (1)
- redis install (1)
- MYSQL AND COLUME (1)
- java版本选择 (1)
- hue (1)
- npm (1)
- es (1)
- 版本管理 (1)
- 升级npm版本 (1)
- git (1)
- 服务器参数设置 (1)
- 调大 IDEA 编译内存大小 (0)
- CentOS8安装GitLab (1)
- gitlab安装使用 (1)
最新评论
-
ssydxa219:
vim /etc/security/limits.confvi ...
ekl -
Gamehu520:
table中无数据
hbase 出现的问题 -
Xleer0102:
为什么都是只有问没有答,哭晕在厕所
hbase 出现的问题 -
jiajiao_5413:
itext table -
CoderDream:
不完整,缺com.tcs.org.demostic.pub.u ...
struts2.3.1.1+hibernate3.6.9Final+spring3.1.0+proxool+maven+annotation
###### 服务器信息
### 生产环境
IP 101.192.3.179
### 开发环境
IP 101.192.7.76
###### PMM构构图
PMM监控工具自带监控LINUX,MySQL,MongoDB
pmm重要组件 grafana,prometheus
https://grafana.com/ //grafana作为数据展示
https://prometheus.io/ //数据采集数据库
###### mysql数据库服务配置
https://www.percona.com/doc/percona-monitoring-and-management/conf-mysql.html
innodb_monitor_enable = all
docker run -d -p 80:80 --volumes-from pmm-data --name pmm-server -e SERVER_USER=pmm -e SERVER_PASSWORD=123456 -e METRICS_MEMORY=786432 --restart always --init percona/pmm-server:1.2.0
PMM 1.2.0需要加 METRICS_MEMORY=786432
https://www.percona.com/forums/questions-discussions/percona-monitoring-and-management/49047-pmm-1-2-0-a-lot-of-data-is-not-shown
###### PMM监控工具安装
参考:https://www.percona.com/doc/percona-monitoring-and-management/deploy/index.html
https://docs.docker.com/engine/installation/linux/centos
### 第一步:安装docker
1.yum remove docker docker-common container-selinux docker-selinux docker-engine
yum install -y yum-utils
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
yum makecache fast
yum list docker-ce.x86_64 --showduplicates |sort -r
yum install docker-ce.x86_64
### 修改默认存储路径
vim /usr/lib/systemd/system/docker.service
ExecStart=/usr/bin/dockerd -g /apps/docker/pmm (线上环境179的配置)
1. mkdir /home/docker(你想要docker存放image的目录)
2. systemctl stop docker
3. vi /usr/lib/systemd/system/docker.service
4. 添加 -g /home/docker (本地开发环境10.0.2.76的配置)
[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com
After=network.target docker.socket
Requires=docker.socket
[Service]
Type=notify
ExecStart=/usr/bin/docker daemon -g /home/docker -H fd://
MountFlags=slave
LimitNOFILE=1048576
LimitNPROC=1048576
LimitCORE=infinity
[Install]
WantedBy=multi-user.target
### 启动
systemctl start docker
### 第二步:安装PMM服务端安装
# 配置加速镜像
1.curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://396e823a.m.daocloud.io //开启镜像加速,由于docker镜像被墙
[root@pgxl-71 ~]# curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://396e823a.m.daocloud.io
docker version >= 1.12
{"registry-mirrors": ["http://396e823a.m.daocloud.io"]}
Success.
You need to restart docker to take effect: sudo systemctl restart docker
systemctl restart docker // docker重启
# 添加pmm-server镜像
docker pull percona/pmm-server:latest
# 添加数据容器
2.Create a PMM Data Container //数据目录
$ docker create \
-v /opt/prometheus/data \
-v /opt/consul-data \
-v /var/lib/mysql \
-v /var/lib/grafana \
--name pmm-data \
percona/pmm-server:1.1.3 /bin/true
# 启动pmm-server容器
3.Create and Run the PMM Server Container //创建PMM Server
$ docker run -d \
-p 80:80 \
--volumes-from pmm-data \
--name pmm-server \
-e SERVER_USER=admin \
-e SERVER_PASSWORD=password \
--restart always \
--init \
percona/pmm-server:1.1.3
### 第三步:安装PMM客户端安装
参考:https://www.percona.com/doc/percona-monitoring-and-management/deploy/client/yum.html#install-client-yum
1.yum install http://www.percona.com/downloads/percona-release/redhat/0.1-4/percona-release-0.1-4.noarch.rpm
yum install pmm-client
[root@pgxl-71 ~]# pmm-admin --help
Usage:
pmm-admin [flags]
pmm-admin [command]
Available Commands:
config Configure PMM Client.
add Add service to monitoring.
remove Remove service from monitoring.
list List monitoring services for this system.
info Display PMM Client information (works offline).
check-network Check network connectivity between client and server.
ping Check if PMM server is alive.
start Start monitoring service.
stop Stop monitoring service.
restart Restart monitoring service.
show-passwords Show PMM Client password information (works offline).
purge Purge metrics data on PMM server.
repair Repair installation.
uninstall Removes all monitoring services with the best effort.
Flags:
-c, --config-file string PMM config file (default "/usr/local/percona/pmm-client/pmm.yml")
-v, --version show version
Use "pmm-admin [command] --help" for more information about a command.
2.添加MongoDB监控服务,自动会添加Linux相关监控
##### 客户端配置
pmm-admin config --server 10.0.0.148 --server-user admin --server-password password --client-name hostname //
##### mongo服务器配置
pmm-admin add mongodb --cluster cluster1 --uri mongodb://root:123456@localhost:27017/admin
//cluster1 为自定义集群名
//--uri mongodb://root:123456@localhost:27017/admin 为monogo链地址
3.添加MySQL监控服务,自动会添加Linux相关监控
pmm-admin config --server 101.0.0.10 --server-user admin --server-password password --client-name hostname
以上3,4操作都会写入配置文件 /usr/local/percona/pmm-client/pmm.yml
pmm-admin 已经封装对prometheus修改
pmm-admin add mysql --user root --socket /apps/dbdat/mysql-5.7.17/mysql.sock --password 123456 mysql143
4.添加redis监控服务(生产线已不使用该方式)
wget https://github.com/oliver006/redis_exporter/releases/download/v0.11/redis_exporter-v0.11.linux-amd64.tar.gz
tar -zxvf redis_exporter-v0.11.linux-amd64.tar.gz
[root@pgxl-76 tmp]# ./redis_exporter --help
Usage of ./redis_exporter:
-check-keys string
Comma separated list of keys to export value and length/size
-debug
Output verbose debug information
-log-format string
Log format, valid options are txt and json (default "txt")
-namespace string
Namespace for metrics (default "redis")
-redis.addr string
Address of one or more redis nodes, separated by separator (default "redis://localhost:6379")
-redis.alias string
Redis instance alias for one or more redis nodes, separated by separator
-redis.password string
Password for one or more redis nodes, separated by separator
-separator string
separator used to split redis.addr, redis.password and redis.alias into several elements. (default ",")
-version
Show version information and exit
-web.listen-address string
Address to listen on for web interface and telemetry. (default ":9121")
-web.telemetry-path string
Path under which to expose metrics. (default "/metrics")
启动客户端 ./redis_exporter -redis.addr redis://localhost:6379
redis_exporter 由于没有集成到PMM服务,所以需要修改prometheus,登入PMM服务端
[root@pgxl-76 tmp]# docker exec -it pmm-server /bin/bash
[root@a5914a0f9617 opt]# vim /etc/prometheus.yml //添加以下
- job_name: redis_exporter
static_configs:
- targets: ['10.0.2.76:9121']
5添加linux监控
pmm-admin config --server 10.0.5.179 --server-user pmm --server-password XXXXXXX --client-name PGXL182
pmm-admin add linux:metrics
###邮箱报警添加
进入docker
docker exec -it pmm-server /bin/bash
编缉grafana.ini
vim /etc/grafana/grafana.ini
[smtp]
enabled = true
host = smtp.healthmall.cn:25
user = liuqian@healthmall.cn
password = 123456
from_address = liuqian@healthmall.cn
from_name = Grafana
### 钉钉报警配置
http://docs.grafana.org/alerting/notifications/
在钉钉上创作一个内部群,并添加webhook机器人。
DingDing/DingTalk
Instructions in Chinese.
In DingTalk PC Client:
Click “more” icon on left bottom of the panel.
Click “Robot Manage” item in the pop menu, there will be a new panel call “Robot Manage”.
In the “Robot Manage” panel, select “customised: customised robot with Webhook”.
In the next new panel named “robot detail”, click “Add” button.
In “Add Robot” panel, input a nickname for the robot and select a “message group” which the robot will join in. click “next”.
There will be a Webhook URL in the panel, looks like this: https://oapi.dingtalk.com/robot/send?access_token=xxxxxxxxx. Copy this URL to the grafana Dingtalk setting page and then click “finish”.
Dingtalk supports the following “message type”: text, link and markdown. Only the text message type is supported.
升级
docker pull percona/pmm-server:latest
docker stop pmm-server && docker rm pmm-server
docker run -d -p 80:80 -p 9090:9090 --volumes-from pmm-data --name pmm-server -e SERVER_USER=pmm -e SERVER_PASSWORD=ngiISI0Q4g9gfqWz89folKJSi --restart always --init percona/pmm-server:latest
### 生产环境
IP 101.192.3.179
### 开发环境
IP 101.192.7.76
###### PMM构构图
PMM监控工具自带监控LINUX,MySQL,MongoDB
pmm重要组件 grafana,prometheus
https://grafana.com/ //grafana作为数据展示
https://prometheus.io/ //数据采集数据库
###### mysql数据库服务配置
https://www.percona.com/doc/percona-monitoring-and-management/conf-mysql.html
innodb_monitor_enable = all
docker run -d -p 80:80 --volumes-from pmm-data --name pmm-server -e SERVER_USER=pmm -e SERVER_PASSWORD=123456 -e METRICS_MEMORY=786432 --restart always --init percona/pmm-server:1.2.0
PMM 1.2.0需要加 METRICS_MEMORY=786432
https://www.percona.com/forums/questions-discussions/percona-monitoring-and-management/49047-pmm-1-2-0-a-lot-of-data-is-not-shown
###### PMM监控工具安装
参考:https://www.percona.com/doc/percona-monitoring-and-management/deploy/index.html
https://docs.docker.com/engine/installation/linux/centos
### 第一步:安装docker
1.yum remove docker docker-common container-selinux docker-selinux docker-engine
yum install -y yum-utils
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
yum makecache fast
yum list docker-ce.x86_64 --showduplicates |sort -r
yum install docker-ce.x86_64
### 修改默认存储路径
vim /usr/lib/systemd/system/docker.service
ExecStart=/usr/bin/dockerd -g /apps/docker/pmm (线上环境179的配置)
1. mkdir /home/docker(你想要docker存放image的目录)
2. systemctl stop docker
3. vi /usr/lib/systemd/system/docker.service
4. 添加 -g /home/docker (本地开发环境10.0.2.76的配置)
[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com
After=network.target docker.socket
Requires=docker.socket
[Service]
Type=notify
ExecStart=/usr/bin/docker daemon -g /home/docker -H fd://
MountFlags=slave
LimitNOFILE=1048576
LimitNPROC=1048576
LimitCORE=infinity
[Install]
WantedBy=multi-user.target
### 启动
systemctl start docker
### 第二步:安装PMM服务端安装
# 配置加速镜像
1.curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://396e823a.m.daocloud.io //开启镜像加速,由于docker镜像被墙
[root@pgxl-71 ~]# curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://396e823a.m.daocloud.io
docker version >= 1.12
{"registry-mirrors": ["http://396e823a.m.daocloud.io"]}
Success.
You need to restart docker to take effect: sudo systemctl restart docker
systemctl restart docker // docker重启
# 添加pmm-server镜像
docker pull percona/pmm-server:latest
# 添加数据容器
2.Create a PMM Data Container //数据目录
$ docker create \
-v /opt/prometheus/data \
-v /opt/consul-data \
-v /var/lib/mysql \
-v /var/lib/grafana \
--name pmm-data \
percona/pmm-server:1.1.3 /bin/true
# 启动pmm-server容器
3.Create and Run the PMM Server Container //创建PMM Server
$ docker run -d \
-p 80:80 \
--volumes-from pmm-data \
--name pmm-server \
-e SERVER_USER=admin \
-e SERVER_PASSWORD=password \
--restart always \
--init \
percona/pmm-server:1.1.3
### 第三步:安装PMM客户端安装
参考:https://www.percona.com/doc/percona-monitoring-and-management/deploy/client/yum.html#install-client-yum
1.yum install http://www.percona.com/downloads/percona-release/redhat/0.1-4/percona-release-0.1-4.noarch.rpm
yum install pmm-client
[root@pgxl-71 ~]# pmm-admin --help
Usage:
pmm-admin [flags]
pmm-admin [command]
Available Commands:
config Configure PMM Client.
add Add service to monitoring.
remove Remove service from monitoring.
list List monitoring services for this system.
info Display PMM Client information (works offline).
check-network Check network connectivity between client and server.
ping Check if PMM server is alive.
start Start monitoring service.
stop Stop monitoring service.
restart Restart monitoring service.
show-passwords Show PMM Client password information (works offline).
purge Purge metrics data on PMM server.
repair Repair installation.
uninstall Removes all monitoring services with the best effort.
Flags:
-c, --config-file string PMM config file (default "/usr/local/percona/pmm-client/pmm.yml")
-v, --version show version
Use "pmm-admin [command] --help" for more information about a command.
2.添加MongoDB监控服务,自动会添加Linux相关监控
##### 客户端配置
pmm-admin config --server 10.0.0.148 --server-user admin --server-password password --client-name hostname //
##### mongo服务器配置
pmm-admin add mongodb --cluster cluster1 --uri mongodb://root:123456@localhost:27017/admin
//cluster1 为自定义集群名
//--uri mongodb://root:123456@localhost:27017/admin 为monogo链地址
3.添加MySQL监控服务,自动会添加Linux相关监控
pmm-admin config --server 101.0.0.10 --server-user admin --server-password password --client-name hostname
以上3,4操作都会写入配置文件 /usr/local/percona/pmm-client/pmm.yml
pmm-admin 已经封装对prometheus修改
pmm-admin add mysql --user root --socket /apps/dbdat/mysql-5.7.17/mysql.sock --password 123456 mysql143
4.添加redis监控服务(生产线已不使用该方式)
wget https://github.com/oliver006/redis_exporter/releases/download/v0.11/redis_exporter-v0.11.linux-amd64.tar.gz
tar -zxvf redis_exporter-v0.11.linux-amd64.tar.gz
[root@pgxl-76 tmp]# ./redis_exporter --help
Usage of ./redis_exporter:
-check-keys string
Comma separated list of keys to export value and length/size
-debug
Output verbose debug information
-log-format string
Log format, valid options are txt and json (default "txt")
-namespace string
Namespace for metrics (default "redis")
-redis.addr string
Address of one or more redis nodes, separated by separator (default "redis://localhost:6379")
-redis.alias string
Redis instance alias for one or more redis nodes, separated by separator
-redis.password string
Password for one or more redis nodes, separated by separator
-separator string
separator used to split redis.addr, redis.password and redis.alias into several elements. (default ",")
-version
Show version information and exit
-web.listen-address string
Address to listen on for web interface and telemetry. (default ":9121")
-web.telemetry-path string
Path under which to expose metrics. (default "/metrics")
启动客户端 ./redis_exporter -redis.addr redis://localhost:6379
redis_exporter 由于没有集成到PMM服务,所以需要修改prometheus,登入PMM服务端
[root@pgxl-76 tmp]# docker exec -it pmm-server /bin/bash
[root@a5914a0f9617 opt]# vim /etc/prometheus.yml //添加以下
- job_name: redis_exporter
static_configs:
- targets: ['10.0.2.76:9121']
5添加linux监控
pmm-admin config --server 10.0.5.179 --server-user pmm --server-password XXXXXXX --client-name PGXL182
pmm-admin add linux:metrics
###邮箱报警添加
进入docker
docker exec -it pmm-server /bin/bash
编缉grafana.ini
vim /etc/grafana/grafana.ini
[smtp]
enabled = true
host = smtp.healthmall.cn:25
user = liuqian@healthmall.cn
password = 123456
from_address = liuqian@healthmall.cn
from_name = Grafana
### 钉钉报警配置
http://docs.grafana.org/alerting/notifications/
在钉钉上创作一个内部群,并添加webhook机器人。
DingDing/DingTalk
Instructions in Chinese.
In DingTalk PC Client:
Click “more” icon on left bottom of the panel.
Click “Robot Manage” item in the pop menu, there will be a new panel call “Robot Manage”.
In the “Robot Manage” panel, select “customised: customised robot with Webhook”.
In the next new panel named “robot detail”, click “Add” button.
In “Add Robot” panel, input a nickname for the robot and select a “message group” which the robot will join in. click “next”.
There will be a Webhook URL in the panel, looks like this: https://oapi.dingtalk.com/robot/send?access_token=xxxxxxxxx. Copy this URL to the grafana Dingtalk setting page and then click “finish”.
Dingtalk supports the following “message type”: text, link and markdown. Only the text message type is supported.
升级
docker pull percona/pmm-server:latest
docker stop pmm-server && docker rm pmm-server
docker run -d -p 80:80 -p 9090:9090 --volumes-from pmm-data --name pmm-server -e SERVER_USER=pmm -e SERVER_PASSWORD=ngiISI0Q4g9gfqWz89folKJSi --restart always --init percona/pmm-server:latest
相关推荐
Percona Monitoring and Management (PMM)是一款开源的用于管理和监控MySQL和MongoDB性能的开源平台,通过PMM客户端收集到的DB监控数据用第三方软件Grafana画图展示出来。 PMM提供了对MyISAM、InnoDB、TokuDB和PXC/...
联想SR650服务器,DCPMM AEP UEFI设置,memory Mode,APP Mode....
PMM-HEX-V1.2 三菱转hex可以将单片机做plc使用是工控必不可少的转换软件
我是一个做MMD得新人 我上传一个数据 能帮助做MMD得新人有好处
基于PMM8714的5相步进电机控制系统设计
参考资料-基于单片机与pmm8713的高速主轴电磁式在线动平衡机构的驱动器设计.zip
文档包括连接PMM和V4S的Flow Builder流程的图表和屏幕截图。 项目垂直 该项目适用于当前正在使用或正在寻找连接PMM和V4S的非营利组织的管理员。 集线器组链接 现任项目组 帮助我们给您应得的感谢,并确保将来的参与...
2、后期修改主机名 3、關於报警 4、關於擴展 5、關於 PMM 提供的慢查询分析
ansible-role-pmm-server 该角色使用安装。 它是Ansible角色系列的一部分,允许设置和配置PMM: 要求Ansible 2.7或更高版本。支持平台 角色变量多变的必需的默认选择项注释pmm_server_docker_image_name 真的percona...
Percona监视和管理(PMM)文档 是一个免费的开源数据库监视解决方案。 此存储库包含在发布的PMM技术文档的源文件。 要撰写文档,您可以: 报告一个一般性问题- 打开一个或使用 。 在页面上报告问题-我们文档的每个...
PMM将在您的CMake项目中自动下载,安装和控制程序包管理器。 (在阅读本文时,仅支持柯南和VCPKG。) 但这只是我必须管理的另一个工具! 从不畏惧! PMM是您将使用的维护成本最低的软件。 如何使用PMM? 使用PMM...
msp430文档
MySQL PMM监控,percona开源的数据库监控工具,支持mongodb/mysql
PMM支持针对MySQL(以及派生产品-适用于MySQL,MariaDB,Amazon RDS MySQL和Aurora MySQL的Percona Server)和PostgreSQL(包括Amazon RDS PostgreSQL和Aurora PostreSQL)执行SELECT查询。 您还可以运行输出度量...
1、注意客户端hostname的命名 2、报警这块没有Zabbix方便 3、Grafana接入其他数据源,会出现绘图时取不到数据的问题 4、purge删除服务端
PMM Android Studio 存储库
PMM Cho等人在“友谊与移动性:基于位置的社交网络中的用户移动”中提出的PMM算法的实现。
网页 该项目是使用版本1.3.2生成的。 开发服务器 为开发服务器运行ng serve 。... 如果您更改任何源文件,该应用程序将自动重新加载。 代码脚手架 运行ng generate component component-name生成一个新的组件。...
Tamago Finance是基于PMM的永久掉期协议,适用于所有资产类别,从普通股,财务指标到建立在Acala / Polkadot(兼容EVM)上的链上状态,并着重于可用性和用户体验。 PMM代表“主动做市算法”,由DODO( )引入。 ...
松下PLC例程源码20080908 PMM-AHPH-VB本资源系百度网盘分享地址