Telegraf

Using `shirou/gopsutil` Go package as a vendored package fails on macOS (10.14.6)

£可爱£侵袭症+ 提交于 2020-08-09 09:12:11
问题 I was trying to build influx/telegraf locally and vendor all the packages using go mod vendor command. However, interestingly, the build fails after that with the following error: # github.com/shirou/gopsutil/host vendor/github.com/shirou/gopsutil/host/host_darwin_cgo.go:9:11: fatal error: 'include/smc.c' file not found #include "include/smc.c" ^~~~~~~~~~~~~~~ Steps to reproduce (after setting GOPATH variable): # Fetch the project, e.g. influx/telegraf go get -d github.com/influxdata/telegraf

Using `shirou/gopsutil` Go package as a vendored package fails on macOS (10.14.6)

假装没事ソ 提交于 2020-08-09 09:11:50
问题 I was trying to build influx/telegraf locally and vendor all the packages using go mod vendor command. However, interestingly, the build fails after that with the following error: # github.com/shirou/gopsutil/host vendor/github.com/shirou/gopsutil/host/host_darwin_cgo.go:9:11: fatal error: 'include/smc.c' file not found #include "include/smc.c" ^~~~~~~~~~~~~~~ Steps to reproduce (after setting GOPATH variable): # Fetch the project, e.g. influx/telegraf go get -d github.com/influxdata/telegraf

h5棋牌源码分享《全面提升,阿里云Docker/Kubernetes(K8S) 日志解决方案与选型对比》

[亡魂溺海] 提交于 2020-04-26 08:02:11
背景 众所周知,Docker很火,Docker中Kubernetes(简称k8s)最火。h5棋牌源码(h5.hxforum.com)联系方式 17061863533 企鹅 2952777280相对物理机、VM,Docker提供了更加简单、轻量、高性价比的部署与运维方法;而k8s在Docker之上,更进一步提供了对管理基础设施的抽象,形成了真正意义上的一站式部署与运维方案。 k8s提供了强有力工作调度、水平扩展、健康监测、维护高可用性等能力,同时提供了网络、文件系统的抽象与管理,所以对于已有应用上k8s或者基于k8s部署应用十分便捷。但这里有一部分令开发和运维人员比较头疼–日志采集。 难点分析 基于VM或者物理机部署的应用,日志采集相关技术都比较完善,有比较健全的Logstash、Fluentd、FileBeats等。但在Docker中,尤其在k8s中,日志采集并没有很好的解决方案,主要原因如下: 1.采集目标多:需要采集宿主机日志、容器内日志、容器stdout。针对每种数据源都有对应的采集软件,但缺乏一站式解决方案。 2.弹性伸缩难:k8s是一个分布式的集群,服务、环境的弹性伸缩对于日志采集带来了很大的困难,采集的动态性以及数据完整性是非常大的挑战。 3.运维成本大:现有的方案只能使用多种软件组合采集,各个软件组装起来的系统稳定性难以保障,且缺乏中心化的管理、配置、监控手段

Sending metrics from telegraf to prometheus

◇◆丶佛笑我妖孽 提交于 2020-02-24 11:57:21
问题 I'm running prometheus and telegraf on the same host. I'm using a few inputs plugins: inputs.cpu inputs.ntpq I've configured to the prometheus_client output plugin to send data to prometheus Here's my config: [[outputs.prometheus_client]] ## Address to listen on. listen = ":9126" ## Use HTTP Basic Authentication. # basic_username = "Foo" # basic_password = "Bar" ## If set, the IP Ranges which are allowed to access metrics. ## ex: ip_range = ["192.168.0.0/24", "192.168.1.0/30"] # ip_range = []

Telegraf部署

99封情书 提交于 2020-01-10 22:14:13
一 简介 Telegraf是一款Go语言编写的metrics收集、处理、聚合的代理 其设计目标是较小的内存使用,通过插件来构建各种服务和第三方组件的metrics收集 Telegraf由4个独立的插件驱动 Input Plugins 输入插件,收集系统、服务、第三方组件的数据 Processor Plugins 处理插件,转换、处理、过滤数据 Aggregator Plugins 聚合插件,数据特征聚合 Output Plugins 输出插件,写metrics数据 二 安装 链接: https://portal.influxdata.com/downloads 这里采用二进制安装 wget https://dl.influxdata.com/telegraf/releases/telegraf-1.2.1_linux_amd64.tar.gz tar xvfz telegraf-1.2.1_linux_amd64.tar.gz 三 配置 可执行文件在 usr/bin/telegraf,配置文件在安装后的etc目录下,也可直接配置生成 查看帮助 telegraf --help 生成配置文件 telegraf config > telegraf.conf 生成带cpu、memroy、http_listener和influxdb插件的配置文件 telegraf --input

Install Telegraf in Ubuntu 16.04 LTS

▼魔方 西西 提交于 2020-01-08 19:18:48
add key curl -sL https://repos.influxdata.com/influxdb.key | sudo apt-key add - add sources echo "deb https://repos.influxdata.com/ubuntu trusty stable" | sudo tee /etc/apt/sources.list.d/influxdb.list update apt update install lwk@qwfys ~ $ apt install telegraf start sudo service telegraf start 来源: 51CTO 作者: qwfys200 链接: https://blog.51cto.com/qwfys200/2074396

Telegraf tail with grok pattern error

旧时模样 提交于 2019-12-23 05:43:09
问题 I am using Telegraf to get logs information from Apache NiFi, for this task I am using this config: [[inputs.tail]] ## files to tail. files = ["/var/log/nifi/nifi-app.log"] ## Read file from beginning. from_beginning = true #name_override = "nifi_app" ## https://github.com/influxdata/telegraf/blob/master/docs/DATA_FORMATS_INPUT.md data_format = "grok" grok_patterns = [ "%{DATE:date} %{TIME:time} %{WORD:EventType} \[%{GREEDYDATA:NifiTask} %{NOTSPACE:Thread}\] %{NOTSPACE:NifiEventType} %

Telegraf daemon not receiving metrics from app deployed with Dokku

北战南征 提交于 2019-12-12 18:17:37
问题 I've already monitored NodeJS apps in the past with Telegraf+InfluxDB+Grafana, but it's the first time I try to monitor a Dokku app, without success so far. I have the following setup app server monitoring serveur - telegraf daemon (listening on udp 8125) ------> InfluxDB + Grafana - dokku - myapp : sending metrics on localhost:udp:8125 I have the issue that metrics sent from myapp on udp://localhost:8125 are not received by telegraf . The connectivity from telegraf to influxdb and grafana is

telegraf 安装

萝らか妹 提交于 2019-12-11 20:39:38
安装配置 cd /tmp wget https://dl.influxdata.com/telegraf/releases/telegraf-1.10.3-1.x86_64.rpm yum install telegraf-1.10.3-1.x86_64.rpm -y #influxdb配置 vim /etc/telegraf/telegraf.conf urls = ["http://127.0.0.1:8086"] database = "telegraf" username = "telegraf" password = "telegraf" urls:表示influxdb的地址及端口号 database:influxdb数据库名 username:数据库用户名 password:数据库密码 客户端 #使用客户端查看数据 https://github.com/CymaticLabs/InfluxDBStudio/releases/download/v0.2.0-beta.1/InfluxDBStudio-0.2.0.zip #安装需要安装环境.NET Framework 4.6.1 以上 #https://dotnet.microsoft.com/download/thank-you/net48 来源: CSDN 作者: 取壳羊 链接: https://blog.csdn

Kapacitor .post() HTTP Post to url not sending data

隐身守侯 提交于 2019-12-10 15:29:45
问题 I am using kapacitor to send alert to URL using HTTP POST. Written script is hitting on given url but it is not sending related data to any of given url. Following is my TICK script. stream |from() .measurement('cpu') |alert() .id('kapacitor/{{ index .Tags "host"}}') .message('{{ .ID }} is {{ .Level }} value:{{ index .Fields "value" }}') .info(lambda: TRUE) .post('http://localhost:1440/alert') .post('http://localhost/test.php') Following is a first post script: var express = require("express"