【问题标题】:InfluxDB - Drop series is not workingInfluxDB - Drop 系列不工作
【发布时间】:2018-08-03 11:12:30
【问题描述】:

我想删除一些我不再使用的主机,因为它们在带有模板的 grafana 上显示,我不希望这样。

我执行drop series from measurement where host = 'hostName' 然后我执行show series from measurement

主人还在。有什么想法吗?

drop series from cpu where host = 'hostName'
show series from cpu where host = 'hostName'
cpu,cpu=cpu-total,host=hostName
cpu,cpu=cpu0,host=hostName
cpu,cpu=cpu1,host=hostName

【问题讨论】:

  • 你使用的是什么版本的 InfluxDB?新版本(1.4+)似乎有一个错误没有删除数据:github.com/influxdata/influxdb/issues/9246
  • 是的,可能是这样。我有 1.4.2。发布作为答案给你你的观点。这很奇怪,apt update 不检索新版本,一个月前就发布了

标签: influxdb grafana-templating


【解决方案1】:

在一些更高版本的 influx 中存在另一个错误(行为) - 在按标签删除所有系列后,您应该重新启动 influxdb 服务器以重置/清理/重建一些内存中的数据。在我的情况下,主机仅在重新启动后才消失。 更多详情见本期讨论:https://github.com/influxdata/influxdb/issues/5092

【讨论】:

  • 我可以确认这发生在 macOS 的 v1.7.4 上。不得不重新启动 InfluxDB 以反映下降情况。
【解决方案2】:

较新版本 (1.4+) 存在不删除数据的错误:github.com/influxdata/influxdb/issues/9246

该错误已修复,因此您应该升级您的安装。

安装并启动 InfluxDB 服务(旧版 linux dist): sudo apt-get update && sudo apt-get install influxdb sudo service influxdb start

如果您的操作系统使用 systemd(Ubuntu 15.04+、Debian 8+): sudo apt-get update && sudo apt-get install influxdb sudo systemctl start influxdb

完整文档: https://docs.influxdata.com/influxdb/v1.4/introduction/installation/

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-05-11
    • 2017-02-24
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多