python - 如何从 Scollector 运行外部收集器?

标签 python opentsdb scollector

我正在尝试从 scollector 运行 /path-to-scollector/collectors/0 文件夹中的外部 example.py 脚本。

scollector.toml:

Host = "localhost:0"
ColDir="//path-to-scollector//collectors//"
BatchSize=500
DisableSelf=true

运行 scollector 的命令:

scollector-windows-amd64.exe -conf scollector.toml -p

但我没有在输出中获取sample.py 指标。它预计将连续运行并将输出打印到 cnosole。当我运行时:

 scollector-windows-amd64.exe -conf scollector.toml -l

我的外部收集器未列出。

最佳答案

在你的 scollector.toml 中,你应该有一行如下,
Filter=["sample.py"]

在你的sample.py中,你需要这一行
#!/usr/bin/python

关于python - 如何从 Scollector 运行外部收集器?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48073918/

相关文章:

python - 如何根据 Pandas 中一系列列的特定条件选择行

hadoop - 配置多个 OpenTSDB 以使用单个 HBase 后端

go - Bosun - 使用 .GetMeta 获取主机的 IP 地址

hbase - 关于 OpenTSDB 数据模型的澄清

linux - 从源问题安装 scollector

python - 在Python中从列表中找到最佳组合后如何从数据集中删除一行

python - 具有 sigmoid 激活的多层感知器在 sin(2x) 回归上生成直线

python - 合并文件路径列表

数据库和大型时间序列 - 下采样 - OpenTSDB InfluxDB Google DataFlow