<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                # Prometheus [Prometheus](https://prometheus.io) 是由 SoundCloud 開源監控告警解決方案,從 2012 年開始編寫代碼,再到 2015 年 GitHub 上開源以來,已經吸引了 9k+ 關注,以及很多大公司的使用;2016 年 Prometheus 成為繼 Kubernetes 之后,成為 CNCF ([Cloud Native Computing Foundation](https://cncf.io/))中的第二個項目成員。 作為新一代開源解決方案,很多理念與 Google SRE 運維之道不謀而合。 ## 主要功能 - 多維 [數據模型](https://prometheus.io/docs/concepts/data_model/)(時序由 metric 名字和 k/v 的 labels 構成)。 - 靈活的查詢語句([PromQL](https://prometheus.io/docs/querying/basics/))。 - 無依賴存儲,支持 local 和 remote 不同模型。 - 采用 http 協議,使用 pull 模式,拉取數據,簡單易懂。 - 監控目標,可以采用服務發現或靜態配置的方式。 - 支持多種統計數據模型,圖形化友好。 ## 核心組件 - [Prometheus Server](https://github.com/prometheus/prometheus), 主要用于抓取數據和存儲時序數據,另外還提供查詢和 Alert Rule 配置管理。 - [client libraries](https://prometheus.io/docs/instrumenting/clientlibs/),用于對接 Prometheus Server, 可以查詢和上報數據。 - [push gateway](https://github.com/prometheus/pushgateway) ,用于批量,短期的監控數據的匯總節點,主要用于業務數據匯報等。 - 各種匯報數據的 [exporters](https://prometheus.io/docs/instrumenting/exporters/) ,例如匯報機器數據的 node\_exporter, 匯報 MongoDB 信息的 [MongoDB exporter](https://github.com/dcu/mongodb_exporter) 等等。 - 用于告警通知管理的 [alertmanager](https://github.com/prometheus/alertmanager) 。 ## 基礎架構 一圖勝千言,先來張官方的架構圖: ![Prometheus 架構圖](https://ws3.sinaimg.cn/large/006tNbRwly1fwcgsn11fej311j0mjadw.jpg) 從這個架構圖,也可以看出 Prometheus 的主要模塊包含:Server、Exporters、Pushgateway、PromQL、Alertmanager、WebUI 等。 它大致使用邏輯是這樣: 1. Prometheus server 定期從靜態配置的 target 或者服務發現的 target 拉取數據。 2. 當新拉取的數據大于配置內存緩存區的時候,Prometheus 會將數據持久化到磁盤(如果使用 remote storage 將持久化到云端)。 3. Prometheus 可以配置 rule,然后定時查詢數據,當條件觸發的時候,會將 alert 推送到配置的 Alertmanager。 4. Alertmanager 收到警告的時候,可以根據配置,聚合、去重、降噪,最后發送警告。 5. 可以使用 API、Prometheus Console 或者 Grafana 查詢和聚合數據。 ## 注意 - Prometheus 的數據是基于時序的 float64 的值,如果你的數據值還有其他類型,Prometheus 則無法滿足。 - Prometheus 不適合做審計計費,因為它的數據是按一定時間采集的,關注的更多是系統的運行瞬時狀態以及趨勢,即使有少量數據沒有采集也能容忍,但是審計計費需要記錄每個請求,并且數據長期存儲,這個和 Prometheus 無法滿足,可能需要采用專門的審計系統。 ## 參考 - [Prometheus practice - github.com](https://github.com/songjiayang/prometheus_practice/) - [Prometheus overview - prometheus.io](https://prometheus.io/docs/introduction/overview/)
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看