# Grafana

**Grafana** 是一个开源的数据可视化与可观测性（从系统外部输出推断其内部状态）平台，它查询外部数据源——如 [Prometheus](https://www.edgepedia.org/zh/prometheus) 服务器、Loki 实例、SQL 数据库和云监控服务——并将获取的指标、日志、追踪和性能剖析数据渲染为交互式仪表板。该平台由 [Grafana Labs](https://www.edgepedia.org/zh/grafana-labs) 开发，以三个共享同一核心的版本发行：Grafana OSS，即免费的自管理开源版本，采用 AGPLv3 许可证；Grafana Enterprise，同样为自管理，但增加了企业数据源插件、报表、增强的访问控制和官方支持等商业功能；以及 Grafana Cloud，即托管服务。<sup>[1](https://grafana.com/docs/grafana/latest/introduction/)</sup><sup> • </sup><sup>[2](https://grafana.com/grafana/download?edition=oss&src=rt)</sup>

| 关键事实 | 详情 |
|---|---|
| 版本 | Grafana OSS（免费、自管理、AGPLv3）、Grafana Enterprise（自管理，含商业功能）、Grafana Cloud（托管）<sup>[1](https://grafana.com/docs/grafana/latest/introduction/)</sup><sup> • </sup><sup>[2](https://grafana.com/grafana/download?edition=oss&src=rt)</sup> |
| 核心模型 | 每个数据源都由插件驱动；Prometheus、Loki 和 MySQL 等核心插件随附捆绑，插件目录中还有数百个更多插件<sup>[3](https://grafana.com/docs/grafana/latest/datasources/concepts/)</sup> |
| 告警 | 告警规则可通过 PagerDuty、短信、电子邮件、VictorOps、OpsGenie、Slack 以及用告警钩子编写的自定义通知器发送通知<sup>[1](https://grafana.com/docs/grafana/latest/introduction/)</sup> |
| 插件后端 | 于 Grafana v7.0 引入；基于 HashiCorp 的 Go Plugin System over RPC，Grafana 服务器将每个后端作为子进程启动，通过 gRPC 通信<sup>[4](https://grafana.com/developers/plugin-tools/key-concepts/backend-plugins)</sup> |
| 规模 | Grafana Labs 报告全球用户超过 2500 万<sup>[5](https://grafana.com/success/)</sup> |
| 云免费层 | 永久免费使用 10k 指标、50GB 日志、50GB 追踪和 500VUh 的 k6 测试<sup>[6](https://grafana.com/docs/grafana/latest/whatsnew/)</sup> |
| 数据源广度 | 半数 Grafana 用户配置并活跃使用至少六个数据源；整体 10%、金融服务领域 30% 的用户拥有 50 个或更多数据源<sup>[7](https://grafana.com/media/observability-survey/Obs-Survey-24-final.pdf)</sup> |

## 数据源与插件

Grafana 中的数据源是对持有数据的存储后端的已配置连接，由连接详情、凭据和端点定义。Grafana 查询数据源以获取存储的数据，然后将其在仪表板和 Explore 中可视化——Explore 是其用于即席查询和动态下钻的界面，支持分屏视图并排比较时间范围、查询和数据源。<sup>[8](https://grafana.com/docs/grafana/latest/datasources/)</sup>

每个数据源都由数据源插件驱动。Grafana 捆绑了 Prometheus、Loki 和 MySQL 等核心数据源插件，插件目录还提供数百个更多插件，覆盖从数据库和云服务商到 Jira、GitHub 和 Datadog 等工具的系统。插件分为三种类型：数据源插件，将 Grafana 连接到特定数据库或服务；面板插件，控制数据的呈现方式，如饼图、K 线图和红绿灯面板；以及应用插件，将数据源、面板和自定义页面打包在一个安装包中。<sup>[3](https://grafana.com/docs/grafana/latest/datasources/concepts/)</sup>

**后端插件。** 自 Grafana v7.0 起，插件可以包含用 Go 编写的后端组件。Grafana 服务器将每个插件后端作为子进程启动，并通过 gRPC 与之通信，使用的是 HashiCorp 的 Go Plugin System over RPC。这种隔离意味着插件中的运行时恐慌不会导致 Grafana 服务器崩溃，且插件只能访问提供给它们的接口和参数。对于支持 Grafana 告警、记录查询或查询与资源缓存的数据源，以及连接 SQL 数据库服务器和浏览器无法直接访问的其他非 HTTP 服务，后端组件是必需的。<sup>[4](https://grafana.com/developers/plugin-tools/key-concepts/backend-plugins)</sup>

**集成。** 与数据源不同，集成是 Grafana Cloud 专属的预打包监控解决方案。它们捆绑了数据采集设置、预定义指标和查询、告警规则以及预构建的仪表板。数据源在数据原本所在之处查询数据，让操作者掌控存储、模式和保留策略；集成则将遥测数据摄入 Grafana Cloud 的托管后端，Grafana 在那里查询自己的存储。<sup>[3](https://grafana.com/docs/grafana/latest/datasources/concepts/)</sup>

## 仪表板与告警

仪表板由面板组成，每个面板对一个或多个数据源运行查询。模板变量让单个仪表板无需硬编码值即可服务多种场景，例如同一仪表板用于生产服务器和测试服务器，并支持从全部数据下钻到某个区域乃至更细粒度。注释用来自任何数据源的事件叠加图形标记，可手动创建或自动获取，以便在出问题时关联数据。<sup>[1](https://grafana.com/docs/grafana/latest/introduction/)</sup>

Grafana 告警对数据源评估告警规则，并通过 [PagerDuty](https://www.edgepedia.org/zh/pagerduty)、短信、电子邮件、VictorOps、OpsGenie 和 Slack 等通知器发送通知；告警钩子允许用代码编写自定义通知器。对于带有后端插件的数据源，告警规则评估在 Grafana 服务器上运行，这就是 Amazon Managed Grafana 要求用于告警的数据源插件必须是后端插件的原因。<sup>[1](https://grafana.com/docs/grafana/latest/introduction/)</sup><sup> • </sup><sup>[9](https://docs.aws.amazon.com/pdfs/grafana/latest/userguide/service-guide.pdf.pdf)</sup>

**预配置与管理。** 高级用户可以脚本化整个设置：预配置让管理员启动一个预设并锁定数据源的 Grafana 实例，使用户无法更改它们，这在伴随新 [Kubernetes](https://www.edgepedia.org/zh/kubernetes) 集群部署时很有用。Grafana 支持 LDAP 和 OAuth 等认证方式，将用户映射到组织，在 Grafana Enterprise 中还可将用户映射到团队并将权限设置细化到数据源级别。<sup>[1](https://grafana.com/docs/grafana/latest/introduction/)</sup>

一个安全考量是，拥有查看者角色的用户可以对组织中可用的数据源输入任何查询，而不仅限于他们可查看的仪表板上定义的查询。管理员可以通过创建受限数据源并结合企业数据源权限功能来限制这一点，或将受限数据源放入单独的组织中。<sup>[10](https://grafana.com/docs/grafana/latest/setup-grafana/configure-security/)</sup>

## 历史

Grafana 最初是瑞典开发者 Torkel Ödegaard 的项目，他离开咨询工作全职投入其中。2014 年，Raj Dutt 和 [Anthony Woods](https://www.edgepedia.org/zh/anthony-woods) 联系 Ödegaard，邀请他在纽约市进行为期一周的咨询合作，三人决定围绕 Grafana 创办一家公司。Grafana Labs 最初名为 raintank，由 Dutt 担任 CEO、Woods 担任 CTO、Ödegaard 担任首席 Grafana 官，致力于加速该开源软件的采用并围绕其建立可持续的业务。<sup>[11](https://grafana.com/blog/grafana-labs-at-5-how-we-got-here-and-where-were-going/?pg=blog&plcmt=body-txt)</sup>

## 采用与使用

Grafana 的典型用途是监控与可观测性：DevOps 和 SRE 团队将来自分布式基础设施和应用的数据可视化，通常将 Grafana 与 Prometheus 搭配用于指标。Grafana-Prometheus 技术栈也用于 IT 运维之外；一个 2026 年基于它构建的开源框架，在 RACOON 放射学研究联盟中监控全部 38 家德国大学附属医院的数据采集和研究进展。<sup>[12](https://grafana.com/success/agregio/)</sup><sup> • </sup><sup>[13](https://arxiv.org/abs/2606.16861)</sup>

不同部署的数据源广度各异。在 Grafana Labs 的 2024 年可观测性调查中，半数 Grafana 用户报告配置并活跃使用至少六个数据源，10% 报告 50 个或更多；多数据源的采用集中在金融服务（30% 拥有 50 个或更多）和技术行业（21%），而电信公司倾向于使用较少（16% 拥有六个或更多）。<sup>[7](https://grafana.com/media/observability-survey/Obs-Survey-24-final.pdf)</sup>

案例研究展示了规模与用途的多样性。Agregio 是法国公用事业公司 [Électricité de France](https://www.edgepedia.org/zh/electricite-de-france) 于 2017 年成立的子公司，使用 Grafana Enterprise 追踪来自法国 22000 多个站点的聚合可再生能源，其合计发电量相当于六座核反应堆；其业务运营团队用 Grafana 仪表板展示电网平衡和价格，取代了笨重的自定义图表。<sup>[12](https://grafana.com/success/agregio/)</sup> Stack Overflow 使用 Grafana 仪表板对其告警数据进行自助式可视化。<sup>[14](https://grafana.com/files/case_study_stack_overflow.pdf)</sup>

## 与 Kibana 的比较

Grafana 常被与 Kibana——Elastic Stack 的可视化工具——相比较。结构性差异在于数据源范围：Grafana 不限定数据源，可同时从多个后端读取数据，包括 Prometheus、InfluxDB、SQL 数据库、CSV 文件和 [Elasticsearch](https://www.edgepedia.org/zh/elasticsearch) 本身，而 Kibana 从 Elasticsearch 拉取数据。这使得当仪表板必须组合来自多个系统的指标时，Grafana 是通常的选择；而当数据已存在于 Elasticsearch 且深度日志搜索是日常工作内容时，Kibana 是通常的选择。两者也可以一起使用，因为 Grafana 可以从 Elasticsearch 读取数据并在自己的仪表板中显示。<sup>[15](https://betterstack.com/community/comparisons/grafana-vs-kibana/)</sup><sup> • </sup><sup>[16](https://performance.qa/blog/grafana-vs-kibana/)</sup>

## 近期版本

当前发行线为 Grafana 13，最新小版本为 13.2。Grafana 13.2 使保存的查询在 Grafana Enterprise 和 Grafana Cloud 中正式可用，为查看面板模式增加了控件侧边栏（公开预览），重新设计了查询变量编辑器，并允许 BigQuery 和 Google Cloud Monitoring 在 Grafana Cloud 中使用 Google Workload Identity Federation 进行认证，而无需服务账号密钥文件。<sup>[17](https://grafana.com/docs/grafana/latest/whatsnew/whats-new-in-v13-2/)</sup>

## References

1. [About Grafana, Grafana documentation](https://grafana.com/docs/grafana/latest/introduction/)
2. [Download Grafana, Grafana Labs](https://grafana.com/grafana/download?edition=oss&src=rt)
3. [Data sources, plugins, and integrations, Grafana documentation](https://grafana.com/docs/grafana/latest/datasources/concepts/)
4. [Plugin backend system, Grafana Plugin Tools](https://grafana.com/developers/plugin-tools/key-concepts/backend-plugins)
5. [Success stories and case studies, Grafana Labs](https://grafana.com/success/)
6. [What's new in Grafana, Grafana documentation](https://grafana.com/docs/grafana/latest/whatsnew/)
7. [Grafana Labs Observability Survey 2024 (PDF)](https://grafana.com/media/observability-survey/Obs-Survey-24-final.pdf)
8. [Data sources, Grafana documentation](https://grafana.com/docs/grafana/latest/datasources/)
9. [Amazon Managed Grafana User Guide, AWS](https://docs.aws.amazon.com/pdfs/grafana/latest/userguide/service-guide.pdf.pdf)
10. [Configure security, Grafana documentation](https://grafana.com/docs/grafana/latest/setup-grafana/configure-security/)
11. [Grafana Labs at 5: How We Got Here and Where We're Going, Grafana Labs blog](https://grafana.com/blog/grafana-labs-at-5-how-we-got-here-and-where-were-going/?pg=blog&plcmt=body-txt)
12. [Tracking renewable energy across 22,000 sites with Grafana Enterprise, Grafana Labs](https://grafana.com/success/agregio/)
13. [An Open-Source Monitoring Framework for Data Exploration and Progress Tracking in Multi-Center Radiology Studies, arXiv](https://arxiv.org/abs/2606.16861)
14. [Milliseconds Matter: How Stack Overflow uses Grafana (PDF)](https://grafana.com/files/case_study_stack_overflow.pdf)
15. [Grafana vs Kibana: How to Choose, Better Stack Community](https://betterstack.com/community/comparisons/grafana-vs-kibana/)
16. [Kibana vs Grafana (2026), performance.qa](https://performance.qa/blog/grafana-vs-kibana/)
17. [What's new in Grafana v13.2, Grafana documentation](https://grafana.com/docs/grafana/latest/whatsnew/whats-new-in-v13-2/)

---
*Initially written Sep 17, 2026 · Reviewed: Oct 15, 2026 · Edited: Oct 15, 2026 · Last review: Oct 15, 2026*

Topic: 技术与人造世界 › 计算技术与数字系统 › 软件与编程 › Named software products and platforms › Office and business software › Titles symbols to M › Titles 1 to G

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/grafana

English original: https://www.edgepedia.org/grafana
