环境配置

1. install epel

https://www.cyberciti.biz/faq/installing-rhel-epel-repo-on-centos-redhat-7-x/

2. Graphing your system performance in Linux with collectd

https://www.theurbanpenguin.com/graphing-your-system-performance-in-linux-with-collectd/

3. 选择前端(参考后面的列表)

CGP https://github.com/pommi/CGP  CGP提供支持nginx配置。

nginx配置在16.04上启用了php7.0-fpm

    location ~ \.php$ {
try_files $uri =;
# fastcgi_pass unix:/run/php5-fpm.sock;
fastcgi_pass unix:/run/php/php7.-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
} # Disallow access to hidden files and directories (such as .git/)
location ~ /\. {
deny all;
}

Collectd-Web https://www.tecmint.com/install-collectd-and-collectd-web-to-monitor-server-resources-in-linux/

4. 这里有一个综合的安装介绍: 使用的前端是 Collection3, 推荐使用CGP

https://fishilico.github.io/generic-config/etc-server/web/collectd.html

进阶

1. 为collectd 增加一个python的plugin来监控cpu 使用率

https://blog.csdn.net/ffeiffei/article/details/50670411

2. How to Write a Collectd Plugin with Python

https://www.tuicool.com/articles/niiIFra

3. shell plugin

http://blog.kankanan.com/article/4f7f7528-collectd-8fdb884c670d52a176d163a7.html

List of front-ends

From collectd Wiki
 
Jump to: navigationsearch

The following is a list of front-ends to the data collected by collectd.

Name Type Framework Engine Flush
Collectd Graph Panel Web-based PHP RRDtool Yes
Collectd Graph Z Web-based PHP (based on CGP) RRDtool Yes
Collectd-web Web-based CGI RRDtool No
CollectGraph Web-based MoinMoin wiki unknown unknown
Collection 3 Web-based CGI RRDtool Yes
Collection 4 Web-based FastCGI gRaphaël, RRDtool No
Collectd-carbon Web-based Django Graphite/Carbon No
collectw Web-based FastCGI gRaphaël No
EcoStats Web-based CGI RRDtool No
Facette Web-based Go http package HighCharts Yes
Heymon Web-based Ruby on Rails RRDtool No
Jarmon Web-based jQuery, Javascript RRD, Flowplayer Tools, (Twisted) Flot No
kcollectd Stand-alone KDE Qt No
Observium Web-based PHP RRDtool Yes
PerfWatcher Web-based PHP RRDtool Yes
Visage Web-based Ruby + Sinatra, MooTools HighCharts (SVG) No
Vizir Web-based Ruby on Rails Rickshaw/D3js Yes
Sick Muse Web-based Python, jQuery, Backbone.js Flot unknown
RRDscout Web-based Python, Flask RRDtool unknown

collectd 检测cpu使用率的更多相关文章

  1. 服务降级 托底预案 Nginx中使用Lua脚本检测CPU使用率,当达到阀值时开启限流,让用户排队

    https://mp.weixin.qq.com/s/FZAcQQAKomGEe95kln1HCQ 在京东我们是如何做服务降级的 https://mp.weixin.qq.com/s/FZAcQQAK ...

  2. linux服务器检测CPU使用率、负载以及java占用CPU使用率的shell脚本

    #!/bin/bash CPU=`top -b -n 1|grep Cpu|awk '{print $2}'|cut -f 1 -d "."`LOAD=`top -b -n 1|g ...

  3. 《Troubleshooting SQL Server》读书笔记-CPU使用率过高(下)

    <Troubleshooting SQL Server>读书笔记-CPU使用率过高(下) 第三章 High CPU Utilization. CPU使用率过高的常见原因 查询优化器会尽量从 ...

  4. 记java应用linux服务单个CPU使用率100%分析

    之前在做项目的过程中,项目完成后在linux服务器上做性能测试,当服务跑起来的时候发现cpu使用率很奇怪,java应用把单个cpu跑满了,其他cpu利用率0%. 刚开始遇到这问题的时候我第一时间反应使 ...

  5. 查看CPU使用率

    rem 如果wmi服务(服务名为Winmgmt)坏掉了,需要到system32\webm目录下执行如下注释的命令 rem for %i in (*.dll) do RegSvr32 -s %i rem ...

  6. Linux VPS通过安装CPULimit来限制CPU使用率

    说明:我们手上经常有很多廉价的VPS,有时候使用某些软件应用的时候,会出现CPU跑满的情况,而长时间跑满会被VPS商家停掉,所以这里我们需要想办法来限制进程CPU使用率,这里就说个教程. 简介 cpu ...

  7. (笔记)Linux下查看CPU使用率的命令

    1.top 使用权限:所有使用者 使用方式:top [-] [d delay] [q] [c] [S] [s] [i] [n] [b] 说明:即时显示process的动态 d :改变显示的更新速度,或 ...

  8. 分析CPU使用率不断增加的原因

    工程中发现引起的问题: 结合别的朋友的意见,我的优化思路是: 1.排查是否内存泄漏 经过反复查询代码,未发现有内存泄漏(可以自己百度搜索C#内存泄漏的原因).可以通过任务管理器分析是否有内存泄漏,打开 ...

  9. jmeter+influxdb+granfana+collectd监控cpu+mem+TPS

    1.安装grafana #####gafana过期安装包安装报错 Error unpacking rpm package grafana-5.1.4-1.x86_64error: unpacking ...

随机推荐

  1. Dotfuscator 使用图解教程

    Dotfuscator:是.NET混淆器和压缩器,它可以帮助您防止您的应用程序被反编译.同时,它还可以使得您的应用程序更加小巧以及高效.我用的是4.9版本的Dotfuscator,Dotfuscato ...

  2. BindIPEndPointDelegate

    开发人员经常会碰到老板或上头安排的项目或需求,是自己完全陌生的领域,这个时候就会非常头痛,搜索引擎能解决大部分这些方面的问题,而有时因为自身问题或干脆找不到解决方案而非常抓狂......虽然干开发有1 ...

  3. 9.用js制作静态分页

    效果如图: css 代码: #page { text-align: center; } .page { display: inline-block; } .page a { padding: 3px ...

  4. jQuery-表格属性

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/ ...

  5. .NET 黑魔法 - asp.net core 配置文件的"对象存储"

    来,全都是干货. 我们都知道在Framework版本的mvc项目中,配置数据是通过web.config里的appSettings节点配置,我们不得不写一些读取配置文件字符串的类,比如保存在静态的变量中 ...

  6. Git SSH密钥对生成以及多个SSH存在情况配置

    一.使用Git Bash 生成一个新的SSH密钥 1. 打开 Git Bash. 2. 邮箱设置粘贴下面的文字,替换成为你自己的邮箱. Github SSH 1 $ ssh-keygen -t rsa ...

  7. web前端名词

    HTML: HyperText Markup Language      超文本标记语言 XHTML:Extensible HyperText Markup Language   可扩展性超文本标记语 ...

  8. hdu5293 lca+dp+树状数组+时间戳

    题意是给了 n 个点的树,会有m条链条 链接两个点,计算出他们没有公共点的最大价值,  公共点时这样计算的只要在他们 lca 这条链上有公共点的就说明他们相交 dp[i]为这个点包含的子树所能得到的最 ...

  9. jQuery筛选--find(expr|obj|ele)和siblings([expr])

    find(expr|obj|ele) 概述 搜索所有与指定表达式匹配的元素.这个函数是找出正在处理的元素的后代元素的好方法 参数 expr  用于查找的表达式 jQuery object   一个用于 ...

  10. selenium-java web自动化测试工具抓取百度搜索结果实例

    selenium-java web自动化测试工具抓取百度搜索结果实例 这种方式抓百度的搜索关键字结果非常容易抓长尾关键词,根据热门关键词去抓更多内容可以用抓google,百度的这种内容容易给屏蔽,用这 ...