【问题标题】:Grafana dashboard doesn't display data in Rancher UIGrafana 仪表板不在 Rancher UI 中显示数据
【发布时间】:2019-09-22 06:29:57
【问题描述】:

我在 Rancher UI 中为我的项目启用了监控,并且安装成功。但是当我在我的工作负载(例如nginx)上单击“转到grafana”时,它会移动到Grafana仪表板,但Grafana什么也不显示:0 CPU, 0 memory, 0 networking,...

  • 为什么没有数据?
  • 我如何知道我的资源(工作负载、服务、pod)的消耗配额?

请看我的截图:

非常感谢

【问题讨论】:

    标签: kubernetes grafana prometheus rancher rke


    【解决方案1】:

    Prometheus 是使用 Grafana 的必备组件。

    你可以查看这篇博文:

    Kubernetes Monitoring with Prometheus, Grafana and Rancher

    Prometheus 是一个用于监控系统和生成警报的开源应用程序。 ... Prometheus 将以指定的时间间隔抓取目标并将信息存储在时间序列数据库中。

    Grafana 也是开源的,并作为 Web 应用程序运行。 ... Grafana 可以轻松创建图表并将这些图表组合到仪表板中。

    检查,是否检查Prometheus是否开启,是否配置正确:

    Configuring Project Monitoring

    从全局视图中,导航到要配置项目监控的项目。

    • 在导航栏中选择工具 > 监控。

    • 选择启用以显示 Prometheus 配置选项。输入您想要的配置选项。

    • 点击保存。

    还要检查这些设置:

    Prometheus Configuration

    • Enable Persistent Storage for Prometheus 是否为 Prometheus 配置存储,这样即使 Prometheus pod 失败也可以保留指标。

    • Enable Persistent Storage for Grafana 是否为 Grafana 配置存储,以便 Grafana 仪表板和配置即使在 Grafana pod 发生故障时也可以保留。

    【讨论】:

    • 谢谢。我忘记安装 Prometheus 目录了。因此,我安装了它,但出现以下错误:无法安装应用程序 myprometheus-p-lggjt。错误:发布 myprometheus-p-lggjt 失败:podsecuritypolicies.extensions 被禁止:用户“u-noxcbyk7pz”无法在集群范围内的 API 组“extensions”中创建资源“podsecuritypolicies”
    猜你喜欢
    • 2019-08-28
    • 2022-08-10
    • 2022-11-01
    • 2021-07-11
    • 1970-01-01
    • 1970-01-01
    • 2022-01-17
    • 2017-06-04
    • 2017-12-19
    相关资源
    最近更新 更多