From 219f89089ebc5647047dde9af3f8a6fe2ad70b51 Mon Sep 17 00:00:00 2001 From: vitficl Date: Thu, 9 Jun 2022 13:49:25 +0200 Subject: [PATCH] Fix of Grafana dashboards --- LICENSE.md | 147 + .../drill-down_active-pool-instance.json | 319 ++ .../drill-down_dead-pool-instance.json | 316 ++ .../drill-down_less-than-3-hb.json | 325 ++ .../farm-monitor/drill-down_not-mining.json | 177 ++ .../farm-monitor/drill-down_os-version.json | 293 ++ .../farm-monitor/drill-down_power-limit.json | 314 ++ .../farm-monitor/drill-down_stage.json | 275 ++ .../example_farm-by-building.json | 712 +++++ .../farm-monitor/farm-dashboard.json | 2729 +++++++++++++++++ .../farm-monitor/list-of-miners.json | 433 +++ .../farm-proxy/client_dashboard.json | 1368 +++++++++ .../farm-proxy/debug_dashboard.json | 2431 +++++++++++++++ monitoring/grafana/provisioning/grafana.ini | 3 + monitoring/prometheus/prometheus_scan.yml | 59 + monitoring/prometheus/prometheus_static.yml | 57 + scan_crontab | 10 + 17 files changed, 9968 insertions(+) create mode 100644 LICENSE.md create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_active-pool-instance.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_dead-pool-instance.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_less-than-3-hb.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_not-mining.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_os-version.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_power-limit.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_stage.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/example_farm-by-building.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/farm-dashboard.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-monitor/list-of-miners.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-proxy/client_dashboard.json create mode 100644 monitoring/grafana/provisioning/default_dashboards/farm-proxy/debug_dashboard.json create mode 100644 monitoring/grafana/provisioning/grafana.ini create mode 100644 monitoring/prometheus/prometheus_scan.yml create mode 100644 monitoring/prometheus/prometheus_static.yml create mode 100644 scan_crontab diff --git a/LICENSE.md b/LICENSE.md new file mode 100644 index 0000000..d25f834 --- /dev/null +++ b/LICENSE.md @@ -0,0 +1,147 @@ +# SOFTWARE LICENCE AGREEMENT +Braiins Farm Proxy +Version 1.0 +Last updated on April 26, 2022 + +## 1. SCOPE +1.1 This Agreement governs Your use of the Software (as defined below in the Definitions section). + +1.2 This Agreement is legally binding. By downloading, copying, installing, or otherwise using all or any portion of the Software, You accept all the terms and conditions set out in this Agreement, so please, read this Agreement carefully. + +‍1.3 If You do not agree with any of the terms and conditions of this Agreement, do not use the Software and delete or destroy all copies of the Software in Your possession or control. + +1.4 Braiins reserves the right to change or amend the terms and conditions set out in this Agreement at any time. In such a case, Braiins will always notify You of any such changes and amendments on its Website and publish a new version of this Agreement at least thirty (30) days in advance, so please, visit the Website regularly. + +1.5 Braiins will always include a date when this Agreement was last updated and published on the Website on the front page hereof. + +## 2. DEFINITIONS +2.1 Any capitalized terms used in this Agreement shall have the meaning given to them in the Definitions section hereof unless explicitly stated otherwise: +‍ +“Braiins” refers to the commercial company Braiins Systems s.r.o., with its registered office at Křižíkova 148/34, Karlín, Prague 8, Czech Republic, Id. No. 241 47 931, registered in the commercial register kept by the Municipal Court in Prague under file No. C 183056. +‍ +“You” refers to any individual or legal entity copying, installing or otherwise using all or any portion of the Software. +‍ +“Software” refers to a software application for hash rate aggregation called “Braiins Farm Proxy” downloaded from Website or otherwise provided to You by Braiins and any copies and Updates thereof. +‍ +“Updates” refer to any upgrades, updates, patches, hotfixes and additions and modified or additional versions that replace or supplement the original version of the Software, unless Braiins states that they are not included under the licenses granted hereunder and are instead licensed separately under different terms. Updates may include both additions to, and removal of, any particular features or functionality offered by the Software or may replace it entirely. The content, features and functionality of the Updates as well as their frequency are in sole discretion of Braiins. However, Braiins has no obligation to make any Updates available to You. +‍ +“Agreement” refers to the license agreement concluded between Braiins and You when You download, copy, install or otherwise use all or any portion of the Software. The terms and conditions of the Agreement are set out herein. +‍ +“Website” refers to a website https://braiins.com/farm-proxy and any subdomains thereof. +‍ +2.2 The section headings in this document are for Your convenience only and shall not govern the meaning or interpretation of any terms and clauses herein. + +## 3.SOFTWARE LICENSE +3.1 Braiins represents that it has all the rights to the Software necessary to grant to You the following license to the limited use of the Software and to perform any other obligations hereunder. + +‍3.2 Subject to Your continuous compliance with the terms and conditions of this Agreement, Braiins grants You a non-exclusive worldwide license to limited use of the Software (the “License”). + +‍3.3 The Software is licensed to You, not sold, and the License is granted as non-exclusive. Therefore, Braiins retains the title and any intellectual property rights to use the Software as well as to grant any other licenses to its use to any third parties under any conditions it desires. + +‍3.4 Under the granted License You are solely entitled to download and install the Software on Your cryptocurrency mining device and to further use it (in object form only) for the purpose described on the Website or as expressly permitted by Braiins. + +‍3.5 You may use the Software only with the compatible cryptocurrency mining devices and operating systems listed on the Website. + +‍3.6 The License is granted for the term specified below and may be terminated only as stated in this Agreement or by the applicable law. + +‍3.7 You have no right to transfer, assign, rent, sell, sublicense or otherwise directly or indirectly transfer or encumber the License and the Software to any third parties, in whole or in part. + +### 4. LIMITATIONS +4.1 You acknowledge that You are solely entitled to use the Software on and/or with Your own cryptocurrency mining device. Therefore, if the Software is used on any third-party devices on behalf of any third party You must be authorized to accept the terms and conditions of this Agreement on behalf of such third party, so that the third party becomes a party to this Agreement. + +‍4.2 Any use of the Software and any related rights other than as expressly set forth herein is strictly prohibited. Therefore, under the granted License You are not entitled to and shall not allow a third party to: + +‍4.2.1 provide, make available to, or permit use of the Software, in whole or in part, by any third party without prior written consent of Braiins, unless such use by the third party is solely on Your behalf, is strictly in compliance with this Agreement, and You are liable for any breach of this Agreement by such third party; + +4.2.2 copy, reproduce, republish, upload, post or transmit the Software in any way; + +4.2.3 modify or remove any titles, trademarks or trade names, copyright notices, legends, or other proprietary notices or markings on or in the Software. + +4.2.4 decompile, disassemble, reverse engineer, or otherwise attempt to derive source code (or underlying ideas, algorithms, structure or organization) from the Software, in whole or in part; + +4.2.5 attack or attempt to undermine the security, integrity, authentication or intended operation of the Software; + +4.2.6 modify or create derivative works based upon the Software; or + +4.2.7 use the Software to create a competitive offering or to create other software, products or technologies. + +‍4.3 Braiins is not obliged to provide any maintenance or support services relating to the Software or otherwise under this Agreement. + +‍4.4 Braiins does not provide to You any source codes to the Software under this Agreement. + +‍4.5 The Software may cause Your device to connect to the Internet, may require activation or registration, may require download of Updates. You undertake not to interfere with or circumvent any such embedded functions of the Software. + +‍4.6 Certain functions of the Software may require an active and stable connection to the Internet in order to function. It is therefore Your responsibility to ensure that You have at all times an active and stable Internet connection. + +‍4.7 You acknowledge, that the Software may transmit certain information from Your device to Braiins. Braiins will use the information for statistical analysis and improvements of the Software and other products. + +### 5. TERM AND TERMINATION +5.1 The License hereunder is granted, and the Agreement is concluded for a period of one (1) month (hereinafter referred to as the “Term”). + +‍5.2 If You continue using the Software in any way after the day, when the Term expired, You agree that a new version of this Agreement (including new license) is automatically concluded between You and Braiins on the first day on which You use the Software after the expiration of the Term. + +‍5.3 The new version of this Agreement will be governed by the terms and conditions of then effective version of this document published on the Website, unless agreed otherwise between You and Braiins. + +‍5.4 Braiins may terminate the Agreement and the License granted hereunder for any reason or without a reason by a notice with a notice period of three (3) days. + +‍5.5 Braiins may terminate this Agreement and the granted License immediately and without prior notice if You fail to comply with any term or condition of this Agreement. + +‍5.6 Upon expiration or termination of this Agreement and the granted License, You must not use the Software and some or all of the Software may cease to operate without prior notice. + +### 6. LIABILITY AND WARRANTIES +6.1 The Software may be subject to the export laws of the Czech Republic as well as the laws of the country where it is delivered or used. You agree to abide by these laws. + +‍6.2 You understand that certain functionalities of the Software, such as encryption, may be subject to import or export restrictions in the event that You transfer the Software from the country of delivery, and You are responsible for complying with applicable restrictions. + +‍6.3 Braiins provides the Software “as is” and makes (and You receive) no other warranties related to the Software, whether express, implied or statutory, and Braiins specifically disclaims any implied warranties of merchantability, fitness for a particular purpose, and non-infringement. + +‍6.4 Braiins does not warrant that the functions of the Software will meet Your requirements or that operation of the Software will be uninterrupted, timely, secure, or error free, or that the results obtained from the use of the Software will be effective, accurate, or reliable, or that any errors or defects in the Software will be corrected. + +‍6.5 Braiins shall not under any circumstances be held liable to You for any direct, indirect, special, consequential, punitive or any other damages and costs including, but not limited to, loss of profit, loss of revenue, loss of business opportunity arising out of or in connection with this Agreement and the granted License under any theory of liability, even if advised or aware of the possibility of such damages. + +‍6.6 Under certain laws it may not be possible to disclaim liability and warranties completely. For such cases Braiins hereby disclaims its liability and warranties to the fullest extent permissible by the applicable law. + +### 7. SERVICES +7.1 If some activities and/or services are necessary for the Software to function and Braiins does perform such activities and/or services or other Software related activities and/or services for You, You acknowledge that Braiins is under no legal obligation to do so and if it does it is under no legal obligation to continue with the performance thereof in the future. + +‍7.2 Any warranty and liability limitations and exclusions listed under the Section 6 hereof shall to the largest extent permitted by law apply to any activities and/or services performed by Braiins hereunder as well. + +### 8. BETA VERSION +8.1 Any version of the Software designated as “Beta” (or other designation with similar meaning such as “pilot”, “test release”, “developer preview” etc.) allows you to try a new version of the Software before it is fully finished and tested in other than test environments. + +‍8.2 If you decide to use the beta version of the Software, you do so at your own risk and you acknowledge that some features are more likely to contain errors or bugs, or to be unavailable from time to time or not to work as intended in comparison with a regular version of the Software. + +### 9. NOTICES +9.1 Any notifications addressed to Braiins hereunder shall be sent to the following email address: info@braiins.com and are considered as delivered when the delivery has been confirmed by Braiins. + +‍9.2 You undertake to notify Braiins, if You learn that right to grant the License hereunder is or may be compromised such as in the event that You have received a pre-action letter regarding the contents of such License or litigation was initiated regarding such License. In the event that any of the rights granted to You hereunder are or may be compromised, You undertake to provide Braiins with any information and cooperation necessary to retain such rights. + +‍9.3 Any mass communication addressed to You as well as to other user of the Software may be delivered to You by publishing it on the easily accessible designated part of the Website. In that event it shall be considered as delivered thirty (30) days after it has been published. + +### 10. GOVERNING LAW +10.1 The laws of the Czech Republic, without regard to conflict of laws principles, shall govern this Agreement, the granted License and any dispute of any sort that might arise between You and Braiins in connection herewith (including any claims under any liability theory). The United Nations Convention on Contracts for the International Sale of Goods does not apply. + +‍10.2 This choice of law clause does not deprive the consumers of their rights under mandatory provisions of the law of their country of habitual residence in the event that such law would otherwise be applicable pursuant to the Article 6 (1) Regulation (EC) No 593/2008 of the European Parliament and of the Council of 17 June 2008 on the law applicable to contractual obligations (Rome I). + +### 11. DISPUTE RESOLUTION +11.1 Braiins always operate in a customer-friendly manner. Braiins tries to solve any issues peacefully and ask You to do the same. Therefore, You agree to notify Braiins of any disputes arising out of or in connection with this Agreement and granted License and You agree that You will always attempt an out-of-court dispute resolution before You bring the dispute before the courts. + +‍11.2 Any dispute relating in any way to this Agreement and granted License shall be decided with final effect before the courts of the Czech Republic, in particular before the District Court for Prague 8 and (in the event that the regional court decides as a first instance court) before the Municipal Court in Prague. + +‍11.3 Should You violate or threaten to violate intellectual property rights of Braiins in any manner, Braiins may seek an injunction or other relief as may be appropriate to preserve all of Braiins rights in any court of its choice. You consent to exclusive jurisdiction and venue of such courts. + +‍11.4 If You are a consumer and live in the European Union, Norway, Iceland or Lichtenstein, You may be entitled to address Your Dispute through an internet platform for online dispute resolution established by the European Commission (hereinafter referred to as the “ODR Platform”). The ODR Platform is intended to facilitate out-of-court resolutions relating to online purchases of goods and services between consumers and traders based in the European Union, Norway, Iceland and Lichtenstein. You will find the ODR Platform by following this link: http://ec.europa.eu/consumers/odr/. + +### 12. MISCELLANEOUS +12.1 Assignment: You may not assign or transfer any of Your rights or obligations assumed under this Agreement or in any other way related hereto without prior written consent of Braiins. + +‍12.2 Waiver: If You do not comply with this Agreement, and Braiins does not take action right away, or if Braiins does not enforce any other provision hereof, this doesn’t mean that Braiins is waiving any rights that it may have (such as taking action in the future). + +‍12.3 Survival: All the provisions of this Agreement that by their nature extend beyond the termination of mutual legal relationship, including but not limited to dispute resolution and applicable law clauses, shall survive the termination of the mutual legal relationship. + +‍12.4 Severability: If any clause of this Agreement is determined to be illegal, invalid or unenforceable, in whole or in part, under any law, the legality, validity and enforceability of the other clauses hereof shall not be affected. In the event that any clause or part thereof is determined to be illegal, invalid or unenforceable, that clause shall be replaced by the parties of this Agreement with a legal, valid and enforceable clause that has, to the greatest extent possible, a similar effect as the illegal, invalid or unenforceable clause, given the content and purpose of this Agreement. + +‍12.5 Language: This document is issued in an English-language version. The meanings of the terms, conditions and representations herein are subject to definitions and interpretation in the English language. Braiins may also issue this document in other language versions for Your convenience; however, in case of any discrepancies the English-language version shall always prevail. + + +Braiins Systems s.r.o. diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_active-pool-instance.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_active-pool-instance.json new file mode 100644 index 0000000..1391345 --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_active-pool-instance.json @@ -0,0 +1,319 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 15, + "iteration": 1648623461848, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Miner" + }, + "properties": [ + { + "id": "custom.width", + "value": 108 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "", + "url": "http://${__series.name}" + } + ] + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Building" + }, + "properties": [ + { + "id": "custom.width", + "value": 97 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Site" + }, + "properties": [ + { + "id": "custom.width", + "value": 60 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Subnet" + }, + "properties": [ + { + "id": "custom.width", + "value": 73 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Protocol" + }, + "properties": [ + { + "id": "custom.width", + "value": 128 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "User" + }, + "properties": [ + { + "id": "custom.width", + "value": 114 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "custom.width", + "value": 185 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Worker" + }, + "properties": [ + { + "id": "custom.width", + "value": 200 + } + ] + }, + { + "matcher": { + "id": "byName" + }, + "properties": [] + } + ] + }, + "gridPos": { + "h": 12, + "w": 13, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true, + "sortBy": [] + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PBFA97CFB590B2093" + }, + "exemplar": false, + "expr": "client_status{host=\"$host\", connection_type=\"user\"} > 0", + "format": "table", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Miners with Active Pool", + "transformations": [ + { + "id": "organize", + "options": { + "excludeByName": { + "Value": true, + "__name__": true, + "client_id": true, + "connection_type": true, + "host": true, + "host_id": true, + "job": true + }, + "indexByName": { + "Time": 13, + "Value": 14, + "__name__": 4, + "building": 0, + "client_id": 5, + "connection_type": 6, + "host": 7, + "host_id": 8, + "instance": 3, + "job": 9, + "protocol": 10, + "site_id": 1, + "subnet_id": 2, + "user": 11, + "worker": 12 + }, + "renameByName": { + "Time": "Time", + "Value": "", + "building": "Building", + "instance": "Miner", + "protocol": "Protocol", + "site_id": "Site", + "subnet_id": "Subnet", + "user": "User", + "worker": "Worker" + } + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + }, + { + "current": { + "selected": false, + "text": "stratum.slushpool.com", + "value": "stratum.slushpool.com" + }, + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "definition": "label_values(host)", + "hide": 0, + "includeAll": false, + "label": "Host", + "multi": false, + "name": "host", + "options": [], + "query": { + "query": "label_values(host)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "New Drill-Down (Active Pool --> Instance]", + "uid": "bflmpsvz", + "version": 3, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_dead-pool-instance.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_dead-pool-instance.json new file mode 100644 index 0000000..59bf7f6 --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_dead-pool-instance.json @@ -0,0 +1,316 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 10, + "iteration": 1648627484363, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto", + "filterable": true + }, + "links": [], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Site" + }, + "properties": [ + { + "id": "custom.width", + "value": 43 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Subnet" + }, + "properties": [ + { + "id": "custom.width", + "value": 71 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Miner" + }, + "properties": [ + { + "id": "custom.width", + "value": 107 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Protocol" + }, + "properties": [ + { + "id": "custom.width", + "value": 108 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "User" + }, + "properties": [ + { + "id": "custom.width", + "value": 85 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Building" + }, + "properties": [ + { + "id": "custom.width", + "value": 115 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Host" + }, + "properties": [ + { + "id": "custom.width", + "value": 190 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Miner" + }, + "properties": [ + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Go to miner", + "url": "http://${__value.text}" + } + ] + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Worker" + }, + "properties": [ + { + "id": "custom.width", + "value": 209 + } + ] + } + ] + }, + "gridPos": { + "h": 16, + "w": 23, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true, + "sortBy": [] + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "client_status{host=\"$host\", connection_type=\"user\"} < 0", + "format": "table", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Instances with Dead Pool", + "transformations": [ + { + "id": "organize", + "options": { + "excludeByName": { + "Field": true, + "Last": true, + "Value": true, + "__name__": true, + "client_id": true, + "connection_type": true, + "host": true, + "host_id": true, + "job": true + }, + "indexByName": { + "Field": 0, + "Last": 14, + "__name__": 1, + "building": 2, + "client_id": 3, + "connection_type": 4, + "host": 9, + "host_id": 5, + "instance": 8, + "job": 10, + "protocol": 11, + "site_id": 6, + "subnet_id": 7, + "user": 12, + "worker": 13 + }, + "renameByName": { + "Last": "", + "building": "Building", + "host": "Host", + "instance": "Miner", + "protocol": "Protocol", + "site_id": "Site", + "subnet_id": "Subnet", + "user": "User", + "worker": "Worker" + } + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "malina-karel.mr0.ii.zone", + "value": "malina-karel.mr0.ii.zone" + }, + "definition": "label_values(host)", + "hide": 0, + "includeAll": false, + "label": "Host", + "multi": false, + "name": "host", + "options": [], + "query": { + "query": "label_values(host)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" + }, + { + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Drill-Down (Dead Pool --> Instance)", + "uid": "HL10OOs7z", + "version": 4, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_less-than-3-hb.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_less-than-3-hb.json new file mode 100644 index 0000000..6ee6ec1 --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_less-than-3-hb.json @@ -0,0 +1,325 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 12, + "iteration": 1648627425367, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto", + "filterable": true + }, + "links": [], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Miner" + }, + "properties": [ + { + "id": "custom.width", + "value": 146 + }, + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Go to miner", + "url": "http://${__value.text}" + } + ] + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "custom.width", + "value": 247 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "os_version" + }, + "properties": [ + { + "id": "custom.width", + "value": 102 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Subnet" + }, + "properties": [ + { + "id": "custom.width", + "value": 83 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Building" + }, + "properties": [ + { + "id": "custom.width", + "value": 112 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Site" + }, + "properties": [ + { + "id": "custom.width", + "value": 74 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Device ID" + }, + "properties": [ + { + "id": "custom.width", + "value": 183 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Model" + }, + "properties": [ + { + "id": "custom.width", + "value": 179 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "OS Version" + }, + "properties": [ + { + "id": "custom.width", + "value": 319 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Hashboards" + }, + "properties": [ + { + "id": "custom.width", + "value": 117 + } + ] + } + ] + }, + "gridPos": { + "h": 21, + "w": 20, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true, + "sortBy": [] + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "miner_metadata * on (instance) group_left() (count by (instance) (rate(hashboard_shares{type=\"valid\"}[20s]) > 0) < 3) ", + "format": "table", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count by (instance) (rate(hashboard_shares{type=\"valid\"}[20s]) > 0) < 3", + "format": "table", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "B" + } + ], + "title": "Less than 3 hbs", + "transformations": [ + { + "id": "seriesToColumns", + "options": { + "byField": "instance" + } + }, + { + "id": "organize", + "options": { + "excludeByName": { + "Field": true, + "Last *": true, + "Time 1": true, + "Time 2": true, + "Value #A": true, + "host_id": true, + "job": true + }, + "indexByName": { + "Time 1": 4, + "Time 2": 11, + "Value #A": 10, + "Value #B": 12, + "building": 0, + "device_id": 5, + "host_id": 6, + "instance": 3, + "job": 7, + "model": 8, + "os_version": 9, + "site_id": 1, + "subnet_id": 2 + }, + "renameByName": { + "Value #B": "Hashboards", + "building": "Building", + "device_id": "Device ID", + "instance": "Miner", + "model": "Model", + "os_version": "OS Version", + "site_id": "Site", + "subnet_id": "Subnet" + } + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-15m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Drill-Down (Less Than 3 HBs --> Instance)", + "uid": "rkP23dy7z", + "version": 1, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_not-mining.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_not-mining.json new file mode 100644 index 0000000..4acf5bd --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_not-mining.json @@ -0,0 +1,177 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "iteration": 1649057106621, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "http://${__value.text}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Field" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Last *" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + } + ] + }, + "gridPos": { + "h": 20, + "w": 14, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true, + "sortBy": [ + { + "desc": false, + "displayName": "__name__" + } + ] + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "max by (instance, job) (hashboard_shares or up{job!=\"prometheus\"} * 0) == 0", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Miners Not Mining", + "transformations": [ + { + "id": "reduce", + "options": { + "labelsToFields": true, + "reducers": [ + "lastNotNull" + ] + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Drill-Down (Not Mining --> Instance)", + "uid": "zLpA9dsnk", + "version": 1, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_os-version.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_os-version.json new file mode 100644 index 0000000..06f0d9e --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_os-version.json @@ -0,0 +1,293 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 3, + "iteration": 1648580566815, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "http://${__value.text}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "client_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "__name__" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "connection_type" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "host" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "host_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Last" + }, + "properties": [ + { + "id": "custom.hidden" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "site_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "subnet_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Last" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Field" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + } + ] + }, + "gridPos": { + "h": 16, + "w": 23, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "miner_metadata{os_version=\"$os_version\"}", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "OS Version", + "transformations": [ + { + "id": "reduce", + "options": { + "labelsToFields": true, + "reducers": [ + "last" + ] + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "2022-03-23-0-803bb9af-22.03-plus-nightly", + "value": "2022-03-23-0-803bb9af-22.03-plus-nightly" + }, + "definition": "label_values(os_version)", + "hide": 0, + "includeAll": false, + "label": "OS Version", + "multi": false, + "name": "os_version", + "options": [], + "query": { + "query": "label_values(os_version)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" + }, + { + "current": { + "selected": false, + "text": "Prometheus", + "value": "Prometheus" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Drill-Down (OS Version --> Instance)", + "uid": "uZT-Tds7z", + "version": 1, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_power-limit.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_power-limit.json new file mode 100644 index 0000000..e8c54e3 --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_power-limit.json @@ -0,0 +1,314 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 6, + "iteration": 1648580622883, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "http://${__value.text}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "client_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "__name__" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "connection_type" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "host" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "host_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Last" + }, + "properties": [ + { + "id": "custom.hidden" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "site_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "subnet_id" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Last" + }, + "properties": [ + { + "id": "custom.hidden", + "value": false + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Field" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "socket" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "type" + }, + "properties": [ + { + "id": "custom.hidden", + "value": true + } + ] + } + ] + }, + "gridPos": { + "h": 16, + "w": 23, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "miner_power{type=\"limit\"} == $power_limit", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Power Limit", + "transformations": [ + { + "id": "reduce", + "options": { + "labelsToFields": true, + "reducers": [ + "last" + ] + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "1531", + "value": "1531" + }, + "hide": 0, + "label": "Power Limit", + "name": "power_limit", + "options": [ + { + "selected": false, + "text": "3250", + "value": "3250" + } + ], + "query": "1531", + "skipUrlSync": false, + "type": "textbox" + }, + { + "current": { + "selected": false, + "text": "Prometheus", + "value": "Prometheus" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Drill-Down (Power Limit --> Instance)", + "uid": "9kaMAdynz", + "version": 1, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_stage.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_stage.json new file mode 100644 index 0000000..eee21cd --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/drill-down_stage.json @@ -0,0 +1,275 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 7, + "iteration": 1648618709854, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto", + "filterable": true + }, + "links": [], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Building" + }, + "properties": [ + { + "id": "custom.width", + "value": 139 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Site" + }, + "properties": [ + { + "id": "custom.width", + "value": 113 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Subnet" + }, + "properties": [ + { + "id": "custom.width", + "value": 85 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Miner" + }, + "properties": [ + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Go to miner", + "url": "http://${__value.text}" + } + ] + } + ] + } + ] + }, + "gridPos": { + "h": 20, + "w": 14, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true, + "sortBy": [] + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "tuner_stage == $tuner_stage", + "format": "table", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Instances With Given Tuner Stage", + "transformations": [ + { + "id": "organize", + "options": { + "excludeByName": { + "Field": true, + "Last *": true, + "Value": true, + "__name__": true, + "hashboard": true, + "host_id": true, + "job": true + }, + "indexByName": { + "Field": 0, + "Last *": 9, + "__name__": 1, + "building": 2, + "hashboard": 5, + "host_id": 6, + "instance": 7, + "job": 8, + "site_id": 3, + "subnet_id": 4 + }, + "renameByName": { + "building": "Building", + "instance": "Miner", + "site_id": "Site", + "subnet_id": "Subnet" + } + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "5", + "value": "5" + }, + "hide": 0, + "includeAll": false, + "label": "Tuner Stage", + "multi": false, + "name": "tuner_stage", + "options": [ + { + "selected": false, + "text": "1", + "value": "1" + }, + { + "selected": false, + "text": "2", + "value": "2" + }, + { + "selected": false, + "text": "3", + "value": "3" + }, + { + "selected": false, + "text": "4", + "value": "4" + }, + { + "selected": true, + "text": "5", + "value": "5" + }, + { + "selected": false, + "text": "6", + "value": "6" + } + ], + "query": "1,2,3,4,5,6", + "queryValue": "", + "skipUrlSync": false, + "type": "custom" + }, + { + "current": { + "selected": true, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "queryValue": "", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Drill-Down (Stage --> Instance)", + "uid": "9ppW5Oy7z", + "version": 2, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/example_farm-by-building.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/example_farm-by-building.json new file mode 100644 index 0000000..c8d9131 --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/example_farm-by-building.json @@ -0,0 +1,712 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 1, + "id": 7, + "iteration": 1648572734064, + "links": [], + "liveNow": false, + "panels": [ + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 77, + "panels": [], + "repeat": "building", + "title": "$building", + "type": "row" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "GHs" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Miners" + }, + "properties": [ + { + "id": "unit" + } + ] + } + ] + }, + "gridPos": { + "h": 4, + "w": 4, + "x": 0, + "y": 1 + }, + "id": 84, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count(count by (instance) (miner_metadata{building='$building'}))", + "hide": false, + "interval": "", + "legendFormat": "Miners", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(hashboard_nominal_hashrate_gigahashes_per_second{building='$building'})", + "hide": false, + "interval": "", + "legendFormat": " Nominal HR", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum (rate(hashboard_shares{building='$building'}[20s])) * 2^32 / 1e9", + "hide": false, + "interval": "", + "legendFormat": "Real HR (10s)", + "refId": "C" + } + ], + "title": "Summary", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Current real hashrate based on shares from last 10 seconds.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "Hs" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 4, + "x": 4, + "y": 1 + }, + "id": 40, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(rate(hashboard_shares{building='$building'}[10s])) * 2^32", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Total HR", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Number of miners sending data.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "none" + }, + "overrides": [] + }, + "gridPos": { + "h": 2, + "w": 4, + "x": 8, + "y": 1 + }, + "id": 74, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count(count by (instance) (miner_metadata{building='$building'}))", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Running Miners", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Average temperature from max temperatures on miner (chip sensor measure or estimate)", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 2, + "w": 5, + "x": 12, + "y": 1 + }, + "id": 53, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "avg by (location) (max by(location, instance) (temperature{location=\"chip\",building='$building'}))", + "interval": "", + "legendFormat": "Temperature", + "refId": "A" + } + ], + "title": "Temperature", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "watt" + }, + "overrides": [] + }, + "gridPos": { + "h": 2, + "w": 5, + "x": 17, + "y": 1 + }, + "id": 75, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(miner_power{type=\"limit\",building='$building'})", + "interval": "", + "legendFormat": "Estimated Power", + "refId": "A" + } + ], + "title": "Power Limit", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "decimals": 0, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "none" + }, + "overrides": [] + }, + "gridPos": { + "h": 2, + "w": 4, + "x": 8, + "y": 3 + }, + "id": 43, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "avg(fan_speed_control{building='$building'})", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "B" + } + ], + "title": "Average Fan %", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "watt" + }, + "overrides": [] + }, + "gridPos": { + "h": 2, + "w": 5, + "x": 12, + "y": 3 + }, + "id": 52, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(miner_power{type=\"estimated\", building=\"$building\"})", + "interval": "", + "legendFormat": "Estimated Power", + "refId": "A" + } + ], + "title": "Estimated Power", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 2, + "w": 5, + "x": 17, + "y": 3 + }, + "id": 81, + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "auto" + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count_values (\"Stage\", max by (instance) (tuner_stage{building=\"$building\"}))", + "interval": "", + "legendFormat": "{{Stage}}", + "refId": "A" + } + ], + "title": "Tuner Stage", + "transformations": [ + { + "id": "renameByRegex", + "options": { + "regex": "2", + "renamePattern": "Test. PP" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "3", + "renamePattern": "Chip Tun." + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "4", + "renamePattern": "Stable" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "5", + "renamePattern": "Fail" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "6", + "renamePattern": "Man" + } + } + ], + "type": "stat" + } + ], + "refresh": "", + "schemaVersion": 34, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "Prometheus", + "value": "Prometheus" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "queryValue": "", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + }, + { + "current": { + "selected": true, + "text": [ + "All" + ], + "value": [ + "$__all" + ] + }, + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "definition": "label_values(building)", + "hide": 0, + "includeAll": true, + "label": "Building", + "multi": true, + "name": "building", + "options": [], + "query": { + "query": "label_values(building)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" + } + ] + }, + "time": { + "from": "now-12h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Example - Farm Dashboard By Building", + "uid": "mHaISnsnk", + "version": 6, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/farm-dashboard.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/farm-dashboard.json new file mode 100644 index 0000000..48589af --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/farm-dashboard.json @@ -0,0 +1,2729 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 1, + "iteration": 1649095731441, + "links": [], + "liveNow": false, + "panels": [ + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 0 + }, + "id": 77, + "panels": [], + "title": "Summary", + "type": "row" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#6b50ff", + "value": null + } + ] + }, + "unit": "GHs" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Miners" + }, + "properties": [ + { + "id": "unit" + } + ] + } + ] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 0, + "y": 1 + }, + "id": 84, + "links": [ + { + "targetBlank": true, + "title": "List of Miners", + "url": "d/R1-4NFs7k/list-of-miners?${data_source:queryparam}" + } + ], + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count(up{job!=\"prometheus\"})", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "Miners", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "sum(hashboard_nominal_hashrate_gigahashes_per_second)", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": " Nominal HR", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "sum (rate(hashboard_shares[20s])) * 2^32 / 1e9", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "Real HR (10s)", + "refId": "C" + } + ], + "title": "Summary", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Summary of high-level status of individual miners.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "d/zLpA9dsnk/drill-down-not-mining-instance?${data_source:queryparam}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#6b50ff", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 12, + "x": 6, + "y": 1 + }, + "id": 123, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count(up{job!=\"prometheus\"})", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "Defined Miners", + "refId": "Defined" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count(up{job!=\"prometheus\"} == 1)", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "Responsive Miners", + "refId": "Up" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count(sum by (instance) (rate(hashboard_shares[60s])) > 0)", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "Mining", + "refId": "Mining" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count(max by (instance) (rate(hashboard_shares[60s]) or up{job!=\"prometheus\"} * 0) == 0)", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "Not Mining", + "refId": "A" + } + ], + "title": "Miner Status", + "type": "stat" + }, + { + "description": "", + "gridPos": { + "h": 5, + "w": 6, + "x": 18, + "y": 1 + }, + "id": 126, + "options": { + "content": "
\n
\n
\n
\n
", + "mode": "html" + }, + "pluginVersion": "8.4.0", + "title": "Braiins Product Stack", + "type": "text" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Current real hashrate based on shares from last 10 seconds.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#6b50ff", + "value": null + } + ] + }, + "unit": "Hs" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 0, + "y": 5 + }, + "id": 40, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(rate(hashboard_shares[10s])) * 2^32", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Total HR", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "fixedColor": "#6b50ff", + "mode": "fixed" + }, + "decimals": 0, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "none" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 6, + "y": 5 + }, + "id": 43, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "avg(fan_speed_control)", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "B" + } + ], + "title": "Average Fan %", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Average temperature from max temperatures on miner (chip sensor measure or estimate)", + "fieldConfig": { + "defaults": { + "color": { + "fixedColor": "#6b50ff", + "mode": "fixed" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 12, + "y": 5 + }, + "id": 53, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "avg by (location) (max by(location, instance) (temperature{location=\"chip\"}))", + "interval": "", + "legendFormat": "Temperature", + "refId": "A" + } + ], + "title": "Temperature", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#6b50ff", + "value": null + } + ] + }, + "unit": "watt" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 18, + "y": 6 + }, + "id": 75, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(miner_power{type=\"limit\"})", + "interval": "", + "legendFormat": "Estimated Power", + "refId": "A" + } + ], + "title": "Power Limit", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Status of individual defined pool connections", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "links": [ + { + "targetBlank": true, + "title": "Show Instances", + "url": "d/HL10OOs7z/drill-down-dead-pool-instance?${data_source:queryparam}&var-host=${__series.name}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 9, + "x": 0, + "y": 9 + }, + "id": 117, + "options": { + "displayMode": "gradient", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showUnfilled": true + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "sort_desc((count_values('x',client_status{connection_type=\"user\"} < 0) by (host))) # ", + "instant": true, + "interval": "", + "legendFormat": "{{host}}", + "refId": "A" + } + ], + "title": "Client Status - Dead Pools", + "transformations": [ + { + "id": "renameByRegex", + "options": { + "regex": "S1", + "renamePattern": "Act" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "S-1", + "renamePattern": "Dead" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "S0", + "renamePattern": "Alive" + } + } + ], + "type": "bargauge" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Status of individual defined pool connections", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "d/bflmpsvz/drill-down-active-pool-instance?${data_source:queryparam}&var-host=${__series.name}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 9, + "x": 9, + "y": 9 + }, + "id": 120, + "options": { + "displayMode": "gradient", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showUnfilled": true + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "sort_desc((count_values('x',client_status{connection_type=\"user\"} > 0) by (host)))", + "instant": true, + "interval": "", + "legendFormat": "{{host}} ", + "refId": "A" + } + ], + "title": "Client Status - Active (Mining) Pools", + "transformations": [ + { + "id": "renameByRegex", + "options": { + "regex": "S1", + "renamePattern": "Act" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "S-1", + "renamePattern": "Dead" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "S0", + "renamePattern": "Alive" + } + } + ], + "type": "bargauge" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "#6b50ff", + "value": null + } + ] + }, + "unit": "watt" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 18, + "y": 10 + }, + "id": 52, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(miner_power{type=\"estimated\"})", + "interval": "", + "legendFormat": "Estimated Power", + "refId": "A" + } + ], + "title": "Estimated Power", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "d/9ppW5Oy7z/drill-down-stage-instance?var-tuner_stage=${__field.labels.Stage}&${data_source:queryparam}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 18, + "y": 14 + }, + "id": 81, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count_values (\"Stage\", max by (instance) (tuner_stage))\n\n#max by (instance) (tuner_stage)\n", + "instant": true, + "interval": "", + "legendFormat": "{{Stage}}", + "refId": "A" + } + ], + "title": "Tuner Stage", + "transformations": [ + { + "id": "renameByRegex", + "options": { + "regex": "2", + "renamePattern": "Test. PP" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "3", + "renamePattern": "Chip Tun." + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "4", + "renamePattern": "Stable" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "5", + "renamePattern": "Fail" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "6", + "renamePattern": "Man" + } + } + ], + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "decimals": 0, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "http://${__field.labels.instance}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "celsius" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 9, + "x": 0, + "y": 17 + }, + "id": 119, + "links": [], + "options": { + "displayMode": "gradient", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "showUnfilled": true, + "text": { + "valueSize": 14 + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "topk(10,sort_desc(max by(building, instance) (temperature)))", + "instant": true, + "interval": "", + "legendFormat": "{{building}}, {{instance}}", + "refId": "A" + } + ], + "title": "Temperature Top 10 Instances", + "type": "bargauge" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "20 seconds MCR is calculated and miners with lowest result are shown. Links are on IP address.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "decimals": 0, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "http://${__field.labels.instance}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "red", + "value": null + }, + { + "color": "#EAB839", + "value": 0.8 + }, + { + "color": "dark-green", + "value": 0.9 + } + ] + }, + "unit": "percentunit" + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 9, + "x": 9, + "y": 17 + }, + "id": 121, + "options": { + "displayMode": "gradient", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "showUnfilled": true, + "text": { + "valueSize": 14 + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "bottomk(10, \n sort(\n sum by (building, instance) (rate(hashboard_shares[20s])) * 2^32\n /\n sum by(building, instance) (hashboard_nominal_hashrate_gigahashes_per_second * 1e9)\n )\n)", + "instant": true, + "interval": "", + "legendFormat": "{{building}} {{instance}}", + "refId": "A" + } + ], + "title": "10 Miners with lowest MCR", + "type": "bargauge" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "d/rkP23dy7z/drill-down-less-than-3-hbs-instance?from=now-15m&to=now&${data_source:queryparam}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 6, + "x": 18, + "y": 18 + }, + "id": 124, + "links": [], + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "count(count by(instance) (rate(hashboard_shares{type=\"valid\"}[20s]) > 0) <3)", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Less Than 3 HBs", + "transformations": [], + "type": "stat" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Time" + }, + "properties": [ + { + "id": "custom.width", + "value": 245 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Site" + }, + "properties": [ + { + "id": "custom.width", + "value": 86 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Subnet" + }, + "properties": [ + { + "id": "custom.width", + "value": 74 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Miners" + }, + "properties": [ + { + "id": "custom.width", + "value": 89 + } + ] + } + ] + }, + "gridPos": { + "h": 6, + "w": 6, + "x": 18, + "y": 22 + }, + "id": 129, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": true + }, + "showHeader": true, + "sortBy": [] + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PBFA97CFB590B2093" + }, + "exemplar": false, + "expr": "count(miner_metadata) by(site_id, subnet_id)", + "format": "table", + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Miners by Site/Subnet", + "transformations": [ + { + "id": "organize", + "options": { + "excludeByName": { + "Time": true + }, + "indexByName": { + "Time": 3, + "Value": 2, + "site_id": 0, + "subnet_id": 1 + }, + "renameByName": { + "Time": "", + "Value": "Miners", + "site_id": "Site", + "subnet_id": "Subnet" + } + } + } + ], + "type": "table" + }, + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 28 + }, + "id": 107, + "panels": [], + "title": "Over Time", + "type": "row" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Real and Nominal Hashrate", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "left", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "Hs" + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 8, + "x": 0, + "y": 29 + }, + "id": 108, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum by(type) (rate(hashboard_shares[10s])) * 2^32", + "hide": false, + "interval": "", + "legendFormat": "{{type}}", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(hashboard_nominal_hashrate_gigahashes_per_second) * 1e9", + "hide": false, + "interval": "", + "legendFormat": "Nominal Hashrate", + "refId": "B" + } + ], + "title": "Real HR, Nominal HR", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Number of miners sending data.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "none" + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 8, + "x": 8, + "y": 29 + }, + "id": 113, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count(count by (instance) (miner_metadata))", + "hide": false, + "interval": "", + "legendFormat": "Running Miners", + "refId": "A" + } + ], + "title": "Running Miners", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Maximum temperature is taken from each instance (miner). Minimum, Average, and Maximum is then calculated.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "celsius" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Max Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "red", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Min Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-green", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Avg Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-blue", + "mode": "fixed" + } + } + ] + } + ] + }, + "gridPos": { + "h": 7, + "w": 8, + "x": 16, + "y": 29 + }, + "id": 109, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "avg(max by (instance) (temperature))", + "hide": false, + "interval": "", + "legendFormat": "Avg Temperature", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "max(max by (instance) (temperature))", + "hide": false, + "interval": "", + "legendFormat": "Max Temperature", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "min(max by (instance) (temperature))", + "hide": false, + "interval": "", + "legendFormat": "Min Temperature", + "refId": "C" + } + ], + "title": "Min, Avg, Max Temperature", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Estimated power consumption in Watts and power limit.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "watt" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "sum(miner_power{type=\"limit\"})" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-red", + "mode": "fixed" + } + } + ] + } + ] + }, + "gridPos": { + "h": 7, + "w": 8, + "x": 0, + "y": 36 + }, + "id": 112, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(miner_power{type=\"estimated\"})", + "hide": false, + "interval": "", + "legendFormat": "Estimated Power (W)", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "sum(miner_power{type=\"limit\"})", + "hide": false, + "interval": "", + "legendFormat": "Power Limit (W)", + "refId": "B" + } + ], + "title": "Power Limit & Est. Consumption (W)", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Maximum temperature is taken from each instance (miner). Minimum, Average, and Maximum is then calculated.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Max Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "red", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Min Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-green", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Avg Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-blue", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Avg Fan Speed" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-blue", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Max Fan Speed" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-red", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Min Fan Speed" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-green", + "mode": "fixed" + } + } + ] + } + ] + }, + "gridPos": { + "h": 7, + "w": 8, + "x": 8, + "y": 36 + }, + "id": 111, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "avg(max by (instance) (fan_speed_control))", + "hide": false, + "interval": "", + "legendFormat": "Avg Fan Speed", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "max(max by (instance) (fan_speed_control))", + "hide": false, + "interval": "", + "legendFormat": "Max Fan Speed", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "min(max by (instance) (fan_speed_control))", + "hide": false, + "interval": "", + "legendFormat": "Min Fan Speed", + "refId": "C" + } + ], + "title": "Min, Avg, Max Fan Speed", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Power limit is taken from each instance (miner). Minimum, Average, and Maximum is then calculated.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "watt" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Max Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-red", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Min Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-green", + "mode": "fixed" + } + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Avg Temperature" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "dark-blue", + "mode": "fixed" + } + } + ] + } + ] + }, + "gridPos": { + "h": 7, + "w": 8, + "x": 16, + "y": 36 + }, + "id": 110, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.3.4", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "avg(max by (instance) (miner_power{type=\"limit\"}))", + "hide": false, + "interval": "", + "legendFormat": "Avg Temperature", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "max(max by (instance) (miner_power{type=\"limit\"}))", + "hide": false, + "interval": "", + "legendFormat": "Max Temperature", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "min(max by (instance) (miner_power{type=\"limit\"}))", + "hide": false, + "interval": "", + "legendFormat": "Min Temperature", + "refId": "C" + } + ], + "title": "Min, Avg, Max Power Limit", + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Number of instances that are scraped successfully (Up) or not (Down).", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 8, + "x": 0, + "y": 43 + }, + "id": 115, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count_values(\"Status\",up{job!=\"prometheus\"})", + "interval": "", + "legendFormat": "{{Status}}", + "refId": "A" + } + ], + "title": "Prometheus Status", + "transformations": [ + { + "id": "renameByRegex", + "options": { + "regex": "1", + "renamePattern": "Up" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "0", + "renamePattern": "Down" + } + } + ], + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Tuner Status - in case of per-hashboard tuning, maximum status is used.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "links": [], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 8, + "x": 8, + "y": 43 + }, + "id": 116, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count_values(\"TunerStatus\", max by(instance) (tuner_stage))", + "interval": "", + "legendFormat": "{{TunerStatus}}", + "refId": "A" + } + ], + "title": "Tuner Status", + "transformations": [ + { + "id": "renameByRegex", + "options": { + "regex": "2", + "renamePattern": "Testing Profile" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "3", + "renamePattern": "Tuning Chips" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "4", + "renamePattern": "Stable" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "5", + "renamePattern": "Failed Tuner" + } + }, + { + "id": "renameByRegex", + "options": { + "regex": "6", + "renamePattern": "Manual Config" + } + } + ], + "type": "timeseries" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Dead Pools", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "links": [], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 8, + "x": 16, + "y": 43 + }, + "id": 127, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count_values(\"Status\", client_status < 0) by(host)", + "interval": "", + "legendFormat": "{{host}}", + "refId": "A" + } + ], + "title": "Dead Pools", + "transformations": [], + "type": "timeseries" + }, + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 51 + }, + "id": 79, + "panels": [], + "title": "Details", + "type": "row" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "#EAB839", + "value": 80 + }, + { + "color": "red", + "value": 90 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Last *" + }, + "properties": [ + { + "id": "color", + "value": { + "fixedColor": "#F2495C", + "mode": "fixed" + } + } + ] + } + ] + }, + "gridPos": { + "h": 14, + "w": 5, + "x": 0, + "y": 52 + }, + "id": 101, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count by (model)(miner_metadata)", + "instant": false, + "interval": "", + "legendFormat": "{{ model }}", + "refId": "A" + } + ], + "title": "Miners count by model", + "transformations": [], + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "Power Limit of Miners", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "d/9kaMAdynz/drill-down-power-limit-instance?var-power_limit=${__series.name}&${data_source:queryparam}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 14, + "w": 3, + "x": 5, + "y": 52 + }, + "id": 90, + "options": { + "colorMode": "none", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "value_and_name" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count_values (\"PowerLimit\", max by (instance) (miner_power{type=\"limit\"}))", + "interval": "", + "legendFormat": "{{PowerLimit}}", + "refId": "A" + } + ], + "title": "Power Limit", + "type": "stat" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "links": [ + { + "targetBlank": true, + "title": "", + "url": "d/uZT-Tds7z/drill-down-os-version-instance?var-os_version=${__series.name}&${data_source:queryparam}" + } + ], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 7, + "w": 6, + "x": 8, + "y": 52 + }, + "id": 105, + "options": { + "colorMode": "none", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": true, + "expr": "count by (os_version) (miner_metadata)", + "interval": "", + "legendFormat": "{{os_version}}", + "refId": "A" + } + ], + "title": "OS Version", + "type": "stat" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "queryValue": "", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Farm Dashboard", + "uid": "heklhjxnz", + "version": 3, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-monitor/list-of-miners.json b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/list-of-miners.json new file mode 100644 index 0000000..9247dfb --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-monitor/list-of-miners.json @@ -0,0 +1,433 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": "-- Grafana --", + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": 2, + "iteration": 1648627737779, + "links": [], + "liveNow": false, + "panels": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "custom": { + "align": "auto", + "displayMode": "auto", + "filterable": true + }, + "links": [], + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "super-light-yellow", + "value": 60 + }, + { + "color": "dark-orange", + "value": 70 + }, + { + "color": "dark-red", + "value": 80 + } + ] + } + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Subnet" + }, + "properties": [ + { + "id": "custom.width", + "value": 85 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Site" + }, + "properties": [ + { + "id": "custom.width", + "value": 71 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Temperature" + }, + "properties": [ + { + "id": "custom.width", + "value": 95 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Fan Speed" + }, + "properties": [ + { + "id": "custom.width", + "value": 127 + }, + { + "id": "thresholds", + "value": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "super-light-yellow", + "value": 70 + }, + { + "color": "#EAB839", + "value": 85 + }, + { + "color": "red", + "value": 100 + } + ] + } + }, + { + "id": "custom.displayMode", + "value": "color-text" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Hashrate" + }, + "properties": [ + { + "id": "custom.width", + "value": 110 + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Temperature" + }, + "properties": [ + { + "id": "custom.displayMode", + "value": "color-text" + }, + { + "id": "unit", + "value": "celsius" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Hashrate" + }, + "properties": [ + { + "id": "unit", + "value": "THs" + } + ] + }, + { + "matcher": { + "id": "byName", + "options": "Miner" + }, + "properties": [ + { + "id": "links", + "value": [ + { + "targetBlank": true, + "title": "Go to miner", + "url": "http://${__data.fields.Instance}" + } + ] + } + ] + } + ] + }, + "gridPos": { + "h": 23, + "w": 21, + "x": 0, + "y": 0 + }, + "id": 2, + "options": { + "footer": { + "fields": "", + "reducer": [ + "sum" + ], + "show": false + }, + "showHeader": true, + "sortBy": [ + { + "desc": true, + "displayName": "Temperature" + } + ] + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "max by(instance) (temperature)", + "format": "table", + "instant": true, + "interval": "", + "legendFormat": "{{instance}}", + "refId": "Temp" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "fan_speed_control #* on (instance) group_left(model) (miner_metadata)", + "format": "table", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "{{instance}}", + "refId": "FanSpeed" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "sum by (instance) (rate(hashboard_shares[30s])) * 2^32 / 1e12", + "format": "table", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "miner_metadata", + "format": "table", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "${data_source}" + }, + "exemplar": false, + "expr": "miner_power{type=\"limit\"}", + "format": "table", + "hide": false, + "instant": true, + "interval": "", + "legendFormat": "", + "refId": "C" + } + ], + "title": "List of Miners", + "transformations": [ + { + "id": "seriesToColumns", + "options": { + "byField": "instance" + } + }, + { + "id": "organize", + "options": { + "excludeByName": { + "Time 1": true, + "Time 2": true, + "Time 3": true, + "Time 5": true, + "Value #B": true, + "__name__ 1": true, + "__name__ 2": true, + "__name__ 3": true, + "building 1": false, + "building 2": true, + "building 3": true, + "device_id": true, + "host_id 1": true, + "host_id 2": true, + "host_id 3": true, + "job 1": true, + "job 2": true, + "job 3": true, + "site_id 2": true, + "site_id 3": true, + "socket": true, + "subnet_id 2": true, + "subnet_id 3": true, + "type": true + }, + "indexByName": { + "Time 1": 11, + "Time 2": 12, + "Time 3": 16, + "Time 4": 10, + "Time 5": 25, + "Value #A": 5, + "Value #B": 24, + "Value #C": 6, + "Value #FanSpeed": 7, + "Value #Temp": 4, + "__name__ 1": 14, + "__name__ 2": 17, + "__name__ 3": 26, + "building 1": 0, + "building 2": 18, + "building 3": 27, + "device_id": 19, + "host_id 1": 13, + "host_id 2": 20, + "host_id 3": 28, + "instance": 3, + "job 1": 15, + "job 2": 21, + "job 3": 29, + "model": 8, + "os_version": 9, + "site_id 1": 1, + "site_id 2": 22, + "site_id 3": 30, + "socket": 31, + "subnet_id 1": 2, + "subnet_id 2": 23, + "subnet_id 3": 32, + "type": 33 + }, + "renameByName": { + "Time 4": "Time", + "Value #A": "Hashrate", + "Value #C": "Power Limit", + "Value #FanSpeed": "Fan Speed", + "Value #Temp": "Temperature", + "building 1": "Building", + "host_id 1": "", + "instance": "Miner", + "job 1": "", + "model": "Model", + "os_version": "OS Version", + "site_id 1": "Site", + "subnet_id 1": "Subnet", + "subnet_id 2": "", + "type": "" + } + } + } + ], + "type": "table" + } + ], + "refresh": "", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "Data Source", + "multi": false, + "name": "data_source", + "options": [], + "query": "prometheus", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + } + ] + }, + "time": { + "from": "now-6h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "List of Miners", + "uid": "R1-4NFs7k", + "version": 2, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-proxy/client_dashboard.json b/monitoring/grafana/provisioning/default_dashboards/farm-proxy/client_dashboard.json new file mode 100644 index 0000000..fe5500c --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-proxy/client_dashboard.json @@ -0,0 +1,1368 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 1, + "id": 3, + "iteration": 1648651132862, + "links": [], + "liveNow": false, + "panels": [ + { + "description": "Version of Farm Proxy", + "fieldConfig": { + "defaults": { + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "text", + "value": null + } + ] + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 12, + "x": 0, + "y": 0 + }, + "id": 51, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "center", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 1, + "valueSize": 14 + }, + "textMode": "name" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "FP_application_version_details", + "hide": false, + "interval": "", + "legendFormat": "Version: {{version_full}}", + "refId": "B" + } + ], + "type": "stat" + }, + { + "gridPos": { + "h": 6, + "w": 12, + "x": 12, + "y": 0 + }, + "id": 62, + "options": { + "content": "
\n
\n
\n
\n
", + "mode": "markdown" + }, + "pluginVersion": "8.4.0", + "title": "Braiins Product Stack", + "type": "text" + }, + { + "description": "Most recent Farm Proxy start date", + "fieldConfig": { + "defaults": { + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "text", + "value": null + } + ] + }, + "unit": "dateTimeAsLocal" + }, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 12, + "x": 0, + "y": 1 + }, + "id": 55, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "center", + "orientation": "vertical", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "/^started at:$/", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "FP_start_time_ms", + "hide": false, + "interval": "", + "legendFormat": "started at:", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "", + "hide": false, + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "type": "stat" + }, + { + "description": "Validity of certificate for devfee hashrate aggregation", + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "decimals": 0, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 0 + }, + { + "color": "#EAB839", + "value": 3 + }, + { + "color": "green", + "value": 7 + } + ] + }, + "unit": "day" + }, + "overrides": [] + }, + "gridPos": { + "h": 1, + "w": 12, + "x": 0, + "y": 2 + }, + "id": 52, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "center", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 14 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "FP_remaining_certificate_validity_days", + "hide": false, + "interval": "", + "legendFormat": "Certificate valid for:", + "refId": "B" + } + ], + "type": "stat" + }, + { + "description": "Hashrate received from miners.", + "fieldConfig": { + "defaults": { + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "blue", + "value": null + } + ] + }, + "unit": "GHs" + }, + "overrides": [] + }, + "gridPos": { + "h": 3, + "w": 6, + "x": 0, + "y": 3 + }, + "id": 2, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 16 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"downstream\", status=\"accepted\", type=~\"$type\"}[5m]) * 4.294967296)", + "interval": "", + "legendFormat": "5min HR", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"downstream\", status=\"accepted\", type=~\"$type\"}[1h]) * 4.294967296)", + "hide": false, + "interval": "", + "legendFormat": "1hr HR", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"downstream\", status=\"accepted\", type=~\"$type\"}[24h]) * 4.294967296)", + "hide": false, + "interval": "", + "legendFormat": "24hr HR", + "refId": "C" + } + ], + "title": "Downstream hashrate", + "type": "stat" + }, + { + "description": "Hashrate sent to target pool(s).", + "fieldConfig": { + "defaults": { + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "purple", + "value": null + } + ] + }, + "unit": "GHs" + }, + "overrides": [] + }, + "gridPos": { + "h": 3, + "w": 6, + "x": 6, + "y": 3 + }, + "id": 45, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 16 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"upstream\", status=\"validated\", type=~\"$type\"}[5m]) * 4.294967296)", + "interval": "", + "legendFormat": "5min HR", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"upstream\", status=\"validated\", type=~\"$type\"}[1h]) * 4.294967296)", + "hide": false, + "interval": "", + "legendFormat": "1hr HR", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"upstream\", status=\"validated\", type=~\"$type\"}[24h]) * 4.294967296)", + "hide": false, + "interval": "", + "legendFormat": "24hr HR", + "refId": "C" + } + ], + "title": "Upstream hashrate", + "type": "stat" + }, + { + "description": "Shares received from miners", + "fieldConfig": { + "defaults": { + "decimals": 3, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "blue", + "value": null + } + ] + }, + "unit": "locale" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Invalid ratio" + }, + "properties": [ + { + "id": "unit", + "value": "percent" + }, + { + "id": "thresholds", + "value": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "#EAB839", + "value": 0.25 + }, + { + "color": "red", + "value": 0.5 + } + ] + } + } + ] + } + ] + }, + "gridPos": { + "h": 3, + "w": 6, + "x": 0, + "y": 6 + }, + "id": 46, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 16 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_shares_total{direction=\"downstream\", status=\"accepted\", type=\"$type\"})", + "hide": false, + "interval": "", + "legendFormat": "Accepted", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_shares_total{direction=\"downstream\", status!=\"accepted\", type=\"$type\"})", + "hide": false, + "interval": "", + "legendFormat": "Invalid", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_shares_total{direction=\"downstream\", status!=\"accepted\", type=\"$type\"}) / sum(FP_shares_total{direction=\"downstream\", type=\"$type\"}) * 100", + "hide": false, + "interval": "", + "legendFormat": "Invalid ratio", + "refId": "C" + } + ], + "title": "Downstream shares", + "type": "stat" + }, + { + "description": "Shares sent to target pool(s).", + "fieldConfig": { + "defaults": { + "decimals": 3, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "purple", + "value": null + } + ] + }, + "unit": "locale" + }, + "overrides": [ + { + "matcher": { + "id": "byName", + "options": "Invalid ratio" + }, + "properties": [ + { + "id": "unit", + "value": "percent" + }, + { + "id": "thresholds", + "value": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "#EAB839", + "value": 0.25 + }, + { + "color": "red", + "value": 0.5 + } + ] + } + } + ] + } + ] + }, + "gridPos": { + "h": 3, + "w": 6, + "x": 6, + "y": 6 + }, + "id": 48, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 16 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_shares_total{direction=\"upstream\", status=\"validated\",type=\"$type\"})", + "hide": false, + "interval": "", + "legendFormat": "Accepted", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_shares_total{direction=\"upstream\", status!=\"validated\",type=\"$type\"})", + "hide": false, + "interval": "", + "legendFormat": "Invalid", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_shares_total{direction=\"upstream\", status!=\"validated\",type=\"$type\"}) / sum(FP_shares_total{direction=\"upstream\", type=\"$type\"}) * 100", + "hide": false, + "interval": "", + "legendFormat": "Invalid ratio", + "refId": "C" + } + ], + "title": "Upstream shares", + "type": "stat" + }, + { + "description": "Count of currently connected miners by hashrate type", + "fieldConfig": { + "defaults": { + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "blue", + "value": null + } + ] + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 3, + "w": 6, + "x": 12, + "y": 6 + }, + "id": 8, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 18 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_subscription_size_to_target_total{goal!=\"#!!ii-DevFee\"})", + "hide": false, + "interval": "", + "legendFormat": "standard", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_subscription_size_to_target_total{goal=\"#!!ii-DevFee\"})", + "hide": false, + "interval": "", + "legendFormat": "devfee", + "refId": "C" + } + ], + "title": "Downstream connections", + "type": "stat" + }, + { + "description": "Count of connections to target pool(s) by hashrate type", + "fieldConfig": { + "defaults": { + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "purple", + "value": null + } + ] + }, + "unit": "short" + }, + "overrides": [] + }, + "gridPos": { + "h": 3, + "w": 6, + "x": 18, + "y": 6 + }, + "id": 44, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 18 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_connections_by_target{goal!=\"#!!ii-DevFee\"})", + "hide": false, + "interval": "", + "legendFormat": "standard", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_connections_by_target{goal=\"#!!ii-DevFee\"})", + "interval": "", + "legendFormat": "devfee", + "refId": "A" + } + ], + "title": "Upstream connections", + "type": "stat" + }, + { + "description": "Hashrate received from miners", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": true, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "GHs" + }, + "overrides": [] + }, + "gridPos": { + "h": 5, + "w": 12, + "x": 0, + "y": 9 + }, + "id": 9, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "multi", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"downstream\", status=\"accepted\", type=~\"$type\"}[5m]) * 4.294967296) by (type)", + "interval": "", + "legendFormat": "{{type}} hashrate (accepted)", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"downstream\", status!=\"accepted\", type=~\"$type\"}[1m]) * 4.294967296) by (type)", + "hide": false, + "interval": "", + "legendFormat": "{{type}} hashrate (invalid)", + "refId": "B" + } + ], + "title": "Downstream hashrate", + "type": "timeseries" + }, + { + "description": "Theoretical aggregation based on ratio of upstream and downstream connections. Theoretical means the real aggregation can be lower due to network events (e.g. reconnections or job resets).", + "fieldConfig": { + "defaults": { + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "yellow", + "value": null + } + ] + }, + "unit": "percent" + }, + "overrides": [] + }, + "gridPos": { + "h": 2, + "w": 12, + "x": 12, + "y": 9 + }, + "id": 53, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "auto", + "orientation": "vertical", + "reduceOptions": { + "calcs": [ + "last" + ], + "fields": "", + "values": false + }, + "text": { + "titleSize": 14, + "valueSize": 18 + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100 - (sum(FP_connections_by_target{goal!=\"#!!ii-DevFee\"}) / sum(FP_subscription_size_to_target_total{goal!=\"#!!ii-DevFee\"})) * 100", + "interval": "", + "legendFormat": "Standard HR", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100 - (sum(FP_connections_by_target{goal=\"#!!ii-DevFee\"}) / sum(FP_subscription_size_to_target_total{goal=\"#!!ii-DevFee\"})) * 100", + "hide": false, + "interval": "", + "legendFormat": "Devfee HR", + "refId": "B" + } + ], + "title": "Aggregation", + "type": "stat" + }, + { + "description": "History of theoretical aggregation", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "yellow", + "value": null + } + ] + }, + "unit": "percent" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 11 + }, + "id": 54, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100 - (sum(FP_connections_by_target{goal!=\"#!!ii-DevFee\"}) / sum(FP_subscription_size_to_target_total{goal!=\"#!!ii-DevFee\"})) * 100", + "interval": "", + "legendFormat": "Standard HR", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100 - (sum(FP_connections_by_target{goal=\"#!!ii-DevFee\"}) / sum(FP_subscription_size_to_target_total{goal=\"#!!ii-DevFee\"})) * 100", + "hide": false, + "interval": "", + "legendFormat": "Devfee HR", + "refId": "B" + } + ], + "title": "Aggregation history", + "type": "timeseries" + }, + { + "description": "Hashrate sent to target pool(s)", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": true, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "purple", + "value": null + } + ] + }, + "unit": "GHs" + }, + "overrides": [] + }, + "gridPos": { + "h": 5, + "w": 12, + "x": 0, + "y": 14 + }, + "id": 50, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "multi", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"upstream\", status=\"validated\", type=~\"$type\"}[5m]) * 4.294967296) by (type)", + "interval": "", + "legendFormat": "{{type}} hashrate (accepted)", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"upstream\", status!=\"validated\", type=~\"$type\"}[1m]) * 4.294967296) by (type)", + "hide": false, + "interval": "", + "legendFormat": "{{type}} hashrate (invalid)", + "refId": "D" + } + ], + "title": "Upstream hashrate", + "type": "timeseries" + }, + { + "collapsed": true, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 19 + }, + "id": 57, + "panels": [ + { + "description": "Split of standard hashrate among defined goals.", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [] + }, + "overrides": [] + }, + "gridPos": { + "h": 9, + "w": 12, + "x": 0, + "y": 17 + }, + "id": 59, + "options": { + "displayLabels": [ + "name", + "percent" + ], + "legend": { + "displayMode": "list", + "placement": "bottom" + }, + "pieType": "pie", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100* sum(FP_hash_rate_by_providers{goal!=\"#!!ii-DevFee\"}) by (goal) / ignoring(goal) group_left sum(FP_hash_rate_by_providers{goal!=\"#!!ii-DevFee\"})", + "interval": "", + "legendFormat": "{{goal}}", + "refId": "A" + } + ], + "title": "Split among goals", + "type": "piechart" + }, + { + "description": "Split of standard hashrate among targets (IP addresses behind pool URL).", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [], + "unit": "none" + }, + "overrides": [] + }, + "gridPos": { + "h": 9, + "w": 12, + "x": 12, + "y": 17 + }, + "id": 60, + "options": { + "displayLabels": [ + "percent" + ], + "legend": { + "displayMode": "list", + "placement": "right", + "values": [ + "percent" + ] + }, + "pieType": "pie", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=\"upstream\", status=\"validated\", type=\"standard\"}[5m])) by (server)", + "interval": "", + "legendFormat": "{{server}}", + "refId": "A" + } + ], + "title": "Split among targets", + "type": "piechart" + } + ], + "title": "Hashrate split", + "type": "row" + } + ], + "refresh": "5s", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": true, + "text": "standard", + "value": "standard" + }, + "hide": 0, + "includeAll": true, + "label": "Hashrate type", + "multi": false, + "name": "type", + "options": [ + { + "selected": false, + "text": "All", + "value": "$__all" + }, + { + "selected": true, + "text": "standard", + "value": "standard" + }, + { + "selected": false, + "text": "devfee", + "value": "devfee" + } + ], + "query": "standard,devfee", + "queryValue": "", + "skipUrlSync": false, + "type": "custom" + } + ] + }, + "time": { + "from": "now-3h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Client Dashboard", + "uid": "9R0uBpynk", + "version": 1, + "weekStart": "" +} \ No newline at end of file diff --git a/monitoring/grafana/provisioning/default_dashboards/farm-proxy/debug_dashboard.json b/monitoring/grafana/provisioning/default_dashboards/farm-proxy/debug_dashboard.json new file mode 100644 index 0000000..5ad9fc1 --- /dev/null +++ b/monitoring/grafana/provisioning/default_dashboards/farm-proxy/debug_dashboard.json @@ -0,0 +1,2431 @@ +{ + "annotations": { + "list": [ + { + "builtIn": 1, + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "enable": true, + "hide": true, + "iconColor": "rgba(0, 211, 255, 1)", + "name": "Annotations & Alerts", + "target": { + "limit": 100, + "matchAny": false, + "tags": [], + "type": "dashboard" + }, + "type": "dashboard" + } + ] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 1, + "id": 4, + "iteration": 1648104027799, + "links": [], + "liveNow": false, + "panels": [ + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + }, + "unit": "dateTimeAsIso" + }, + "overrides": [] + }, + "gridPos": { + "h": 4, + "w": 12, + "x": 0, + "y": 0 + }, + "id": 53, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "center", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "value_and_name" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "FP_start_time_ms", + "interval": "", + "legendFormat": "Router start time - {{instance}}:", + "refId": "A" + } + ], + "title": "Router start time", + "type": "stat" + }, + { + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": true, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "GHs" + }, + "overrides": [] + }, + "gridPos": { + "h": 9, + "w": 12, + "x": 12, + "y": 0 + }, + "id": 2, + "options": { + "legend": { + "calcs": [ + "lastNotNull", + "min", + "max" + ], + "displayMode": "table", + "placement": "bottom", + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_shares_total{direction=~\"$direction\",status=~\"$status\", type=~\"$type\"}[5m]) * 4.294967296) by (server, direction, status, type)", + "interval": "", + "legendFormat": "{{server}} {{status}} {{direction}} {{type}} hashrate", + "refId": "A" + } + ], + "title": "Hashrate", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "decimals": 0, + "mappings": [], + "noValue": "0", + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "dark-red", + "value": null + }, + { + "color": "red", + "value": 0 + }, + { + "color": "green", + "value": 1 + } + ] + }, + "unit": "d" + }, + "overrides": [] + }, + "gridPos": { + "h": 3, + "w": 12, + "x": 0, + "y": 4 + }, + "id": 43, + "options": { + "colorMode": "value", + "graphMode": "none", + "justifyMode": "center", + "orientation": "horizontal", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "text": {}, + "textMode": "value_and_name" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "FP_remaining_certificate_validity_days", + "format": "time_series", + "instant": false, + "interval": "", + "legendFormat": "instance: {{instance}} ", + "refId": "A" + } + ], + "title": "Certificate validity", + "type": "stat" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 9, + "w": 12, + "x": 0, + "y": 7 + }, + "id": 8, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true, + "text": { + "titleSize": 13, + "valueSize": 30 + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_connections_by_target{target=~\"$target\"}) + sum(FP_subscription_size_to_target_total{target=~\"$target\"})", + "interval": "", + "legendFormat": "#active connections", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_connections_by_target{goal!=\"#!!ii-DevFee\",target=~\"$target\"})", + "hide": false, + "interval": "", + "legendFormat": "upstream standard open connection", + "refId": "B" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_subscription_size_to_target_total{goal!=\"#!!ii-DevFee\",target=~\"$target\"})", + "hide": false, + "interval": "", + "legendFormat": "downstream standard open connection", + "refId": "C" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_connections_by_target{goal=\"#!!ii-DevFee\",target=~\"$target\"})", + "hide": false, + "interval": "", + "legendFormat": "upstream devfee open connection", + "refId": "D" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_subscription_size_to_target_total{goal=\"#!!ii-DevFee\",target=~\"$target\"})", + "hide": false, + "interval": "", + "legendFormat": "downstream devfee open connection", + "refId": "E" + } + ], + "title": "Connection", + "type": "gauge" + }, + { + "description": "", + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "submit/s", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 10, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "never", + "spanNulls": true, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "none" + }, + "overrides": [] + }, + "gridPos": { + "h": 9, + "w": 12, + "x": 12, + "y": 9 + }, + "id": 9, + "options": { + "legend": { + "calcs": [ + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom", + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_submits_total{direction=~\"$direction\",status=~\"$status\", type=~\"$type\"}[1m])) by (server, direction, status, type)", + "interval": "", + "legendFormat": "{{server}} {{status}} {{direction}} {{type}} submits", + "refId": "A" + } + ], + "title": "Submission Rate", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 9, + "w": 12, + "x": 0, + "y": 16 + }, + "id": 23, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom", + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100* sum(FP_shares_total{direction=\"upstream\",server=~\"$target\", type=\"standard\"}) by (server) / ignoring(server) group_left sum(FP_shares_total{direction=\"upstream\", type=\"standard\"})", + "interval": "", + "legendFormat": "standard {{server}}", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100* sum(FP_shares_total{direction=\"upstream\",server=~\"$target\", type=\"devfee\"}) by (server) / ignoring(server) group_left sum(FP_shares_total{direction=\"upstream\", type=\"devfee\"})", + "hide": false, + "interval": "", + "legendFormat": "devfee {{server}}", + "refId": "B" + } + ], + "title": "Hashrate Split", + "type": "timeseries" + }, + { + "collapsed": true, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 25 + }, + "id": 41, + "panels": [ + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + } + ] + }, + "unit": "THs" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 27 + }, + "id": 15, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_allocated_hash_rate_by_providers[1m]) * 4.294967296) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Allocated HR", + "type": "gauge" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [], + "unit": "percent" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 27 + }, + "id": 22, + "options": { + "displayLabels": [ + "name", + "value" + ], + "legend": { + "displayMode": "list", + "placement": "right", + "values": [ + "percent" + ] + }, + "pieType": "pie", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100* sum(FP_hash_rate_by_providers{goal!=\"#!!ii-DevFee\"}) by (goal) / ignoring(goal) group_left sum(FP_hash_rate_by_providers{goal!=\"#!!ii-DevFee\"})", + "interval": "", + "legendFormat": "{{goal}}", + "refId": "A" + } + ], + "title": "Hashrate Split", + "type": "piechart" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + } + ] + }, + "unit": "THs" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 35 + }, + "id": 17, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true, + "text": { + "titleSize": 2 + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_hash_rate_by_receivers[1m])* 4.294967296)", + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "HashRate from Receivers", + "type": "gauge" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green" + } + ] + }, + "unit": "THs" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 35 + }, + "id": 13, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_hash_rate_by_providers[1m])* 4.294967296) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Measured HR on targets", + "type": "gauge" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + } + }, + "mappings": [], + "unit": "percent" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 43 + }, + "id": 33, + "options": { + "displayLabels": [ + "name", + "value" + ], + "legend": { + "displayMode": "list", + "placement": "right", + "values": [ + "percent" + ] + }, + "pieType": "pie", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "100* sum(FP_hash_rate_by_providers{goal=\"#!!ii-DevFee\"}) by (goal) / ignoring(goal) group_left sum(FP_hash_rate_by_providers{goal=\"#!!ii-DevFee\"})", + "interval": "", + "legendFormat": "{{goal}}", + "refId": "A" + } + ], + "title": "Hashrate Split - devfee", + "type": "piechart" + } + ], + "title": "HR split - detail", + "type": "row" + }, + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 26 + }, + "id": 39, + "panels": [], + "title": "Connection metrics", + "type": "row" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 11, + "w": 24, + "x": 0, + "y": 27 + }, + "id": 31, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom", + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_connections_by_target{target=~\"$target\"}) by (target, goal)", + "interval": "", + "legendFormat": "{{goal}} {{target}}", + "refId": "A" + } + ], + "title": "Connection to upstream", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 38 + }, + "id": 32, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom", + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_subscription_size_to_target_total{goal=\"#!!ii-DevFee\",target=~\"$target\"}) by (goal, target)", + "interval": "", + "legendFormat": "{{goal}} - {{target}}", + "refId": "A" + } + ], + "title": "Subscription by target - devfee", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 38 + }, + "id": 25, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom", + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_subscription_size_to_target_total{goal!=\"#!!ii-DevFee\",target=~\"$target\"}) by (goal, target)", + "interval": "", + "legendFormat": "{{goal}} - {{target}}", + "refId": "A" + } + ], + "title": "Subscription by target", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "s" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 46 + }, + "id": 19, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom", + "sortBy": "Last *", + "sortDesc": true + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_mean_latency_s{target=~\"$target\"}) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Mean latency", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "s" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 46 + }, + "id": 20, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_std_dev_latency_s{target=~\"$target\"}) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Std dev latency", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 54 + }, + "id": 47, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_rejection_rate{target=~\"$target\"}) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Rejection rate", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + }, + "unit": "percent" + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 54 + }, + "id": 49, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_error_rate{target=~\"$target\"}) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Error rate", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [ + { + "options": { + "0": { + "color": "red", + "index": 1, + "text": "Down" + }, + "1": { + "color": "green", + "index": 2, + "text": "Up" + }, + "-1": { + "color": "light-blue", + "index": 0, + "text": "Unknown" + } + }, + "type": "value" + } + ], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 62 + }, + "id": 51, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_target_status) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Target Status", + "type": "stat" + }, + { + "collapsed": false, + "gridPos": { + "h": 1, + "w": 24, + "x": 0, + "y": 70 + }, + "id": 11, + "panels": [], + "title": "Router metrics", + "type": "row" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 10, + "w": 24, + "x": 0, + "y": 71 + }, + "id": 45, + "options": { + "legend": { + "calcs": [ + "min", + "max", + "lastNotNull" + ], + "displayMode": "table", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_score_by_target{target=~\"$target\"}) by (target)", + "interval": "", + "legendFormat": "{{target}}", + "refId": "A" + } + ], + "title": "Score by target", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 81 + }, + "id": 37, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_upstream_request_timeout_queue[10m])) by (type)", + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Timeout counter v1 upstream", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 81 + }, + "id": 35, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_upstream_request_queue[10m]))", + "interval": "", + "legendFormat": "#request in Upstream queue", + "refId": "A" + }, + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(rate(FP_upstream_request_timeout_queue[10m]))", + "hide": false, + "interval": "", + "legendFormat": "#timeout request in Upstream queue", + "refId": "B" + } + ], + "title": "V1 upstream queue size", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 89 + }, + "id": 29, + "options": { + "colorMode": "value", + "graphMode": "area", + "justifyMode": "auto", + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "textMode": "auto" + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_buffers_sizes) by (name)", + "interval": "", + "legendFormat": "{{name}}", + "refId": "A" + } + ], + "title": "Waiting queue monitoring", + "type": "stat" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "thresholds" + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 89 + }, + "id": 27, + "options": { + "orientation": "auto", + "reduceOptions": { + "calcs": [ + "lastNotNull" + ], + "fields": "", + "values": false + }, + "showThresholdLabels": false, + "showThresholdMarkers": true + }, + "pluginVersion": "8.4.0", + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(FP_provider_to_remove_size) by (type)", + "interval": "", + "legendFormat": "{{type}}", + "refId": "A" + } + ], + "title": "Providerds to remove", + "type": "gauge" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 97 + }, + "id": 55, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(increase(FP_job_submits_size[10m]))", + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Job submits map size", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 12, + "y": 97 + }, + "id": 57, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(increase(FP_job_queue_size[10m]))", + "interval": "", + "legendFormat": "", + "refId": "A" + } + ], + "title": "Job queue size", + "type": "timeseries" + }, + { + "fieldConfig": { + "defaults": { + "color": { + "mode": "palette-classic" + }, + "custom": { + "axisLabel": "", + "axisPlacement": "auto", + "barAlignment": 0, + "drawStyle": "line", + "fillOpacity": 0, + "gradientMode": "none", + "hideFrom": { + "legend": false, + "tooltip": false, + "viz": false + }, + "lineInterpolation": "linear", + "lineWidth": 1, + "pointSize": 5, + "scaleDistribution": { + "type": "linear" + }, + "showPoints": "auto", + "spanNulls": false, + "stacking": { + "group": "A", + "mode": "none" + }, + "thresholdsStyle": { + "mode": "off" + } + }, + "mappings": [], + "thresholds": { + "mode": "absolute", + "steps": [ + { + "color": "green", + "value": null + }, + { + "color": "red", + "value": 80 + } + ] + } + }, + "overrides": [] + }, + "gridPos": { + "h": 8, + "w": 12, + "x": 0, + "y": 105 + }, + "id": 59, + "options": { + "legend": { + "calcs": [], + "displayMode": "list", + "placement": "bottom" + }, + "tooltip": { + "mode": "single", + "sort": "none" + } + }, + "targets": [ + { + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "exemplar": true, + "expr": "sum(increase(FP_old_jobs[1m])) by (controller)", + "interval": "", + "legendFormat": "{{controller}}", + "refId": "A" + } + ], + "title": "Old jobs detection", + "type": "timeseries" + } + ], + "refresh": "1m", + "schemaVersion": 35, + "style": "dark", + "tags": [], + "templating": { + "list": [ + { + "current": { + "selected": false, + "text": "All", + "value": "$__all" + }, + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "definition": "label_values(FP_shares_total, status)", + "hide": 0, + "includeAll": true, + "multi": false, + "name": "status", + "options": [], + "query": { + "query": "label_values(FP_shares_total, status)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" + }, + { + "current": { + "selected": true, + "text": [ + "All" + ], + "value": [ + "$__all" + ] + }, + "hide": 0, + "includeAll": true, + "multi": true, + "name": "direction", + "options": [ + { + "selected": true, + "text": "All", + "value": "$__all" + }, + { + "selected": false, + "text": "upstream", + "value": "upstream" + }, + { + "selected": false, + "text": "downstream", + "value": "downstream" + } + ], + "query": "upstream,downstream", + "queryValue": "", + "skipUrlSync": false, + "type": "custom" + }, + { + "current": { + "selected": false, + "text": "All", + "value": "$__all" + }, + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "definition": "label_values(FP_shares_total{direction=\"downstream\"}, server)", + "hide": 0, + "includeAll": true, + "multi": true, + "name": "server", + "options": [], + "query": { + "query": "label_values(FP_shares_total{direction=\"downstream\"}, server)", + "refId": "StandardVariableQuery" + }, + "refresh": 2, + "regex": "(\\w+).*", + "skipUrlSync": false, + "sort": 0, + "type": "query" + }, + { + "current": { + "selected": true, + "text": [ + "All" + ], + "value": [ + "$__all" + ] + }, + "hide": 0, + "includeAll": true, + "multi": true, + "name": "type", + "options": [ + { + "selected": true, + "text": "All", + "value": "$__all" + }, + { + "selected": false, + "text": "standard", + "value": "standard" + }, + { + "selected": false, + "text": "devfee", + "value": "devfee" + } + ], + "query": "standard,devfee", + "queryValue": "", + "skipUrlSync": false, + "type": "custom" + }, + { + "current": { + "selected": true, + "text": "All", + "value": "$__all" + }, + "datasource": { + "type": "prometheus", + "uid": "PABF2E7BD7AE7B0F4" + }, + "definition": "label_values(FP_connections_by_target, target)", + "hide": 0, + "includeAll": true, + "multi": false, + "name": "target", + "options": [], + "query": { + "query": "label_values(FP_connections_by_target, target)", + "refId": "StandardVariableQuery" + }, + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "sort": 0, + "type": "query" + } + ] + }, + "time": { + "from": "now-30m", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Debug Dashboard FP", + "uid": "6JZhw2H7z9", + "version": 1, + "weekStart": "" +} diff --git a/monitoring/grafana/provisioning/grafana.ini b/monitoring/grafana/provisioning/grafana.ini new file mode 100644 index 0000000..256888f --- /dev/null +++ b/monitoring/grafana/provisioning/grafana.ini @@ -0,0 +1,3 @@ +[auth.anonymous] +# enable anonymous access +enabled = true diff --git a/monitoring/prometheus/prometheus_scan.yml b/monitoring/prometheus/prometheus_scan.yml new file mode 100644 index 0000000..15fab4b --- /dev/null +++ b/monitoring/prometheus/prometheus_scan.yml @@ -0,0 +1,59 @@ +# path: /etc/prometheus/prometheus.yml +# Global configuration. +global: + scrape_interval: 15s # Set the scrape interval to every 15 seconds. Default is every 1 minute. + evaluation_interval: 15s # Evaluate rules every 15 seconds. The default is every 1 minute. + # scrape_timeout is set to the global default (10s). + +# Scraping configuration. +scrape_configs: + ## Prometheus can scrape itself to provide system statistics. Not needed, but recommended. + - job_name: 'prometheus' + static_configs: + - targets: ['127.0.0.1:9090', 'nodeexporter:9100'] + + # Automatic discovery job - this is suitable for automatically keeping a list of large + # numbers of miners. See the file supercronic/scan_crontab on how to specify the IP + # ranges to be scanned. Each scanned IP range produces a file. Its name is currently assigned + # to label building dynamically. + - job_name: 'braiinsos-data' + metrics_path: '/metrics' + scrape_interval: 5s + file_sd_configs: + - files: + # read all files written by ssh_scan.sh + - /mnt/miners_*.json + refresh_interval: 15s + relabel_configs: + # Add file name as a label + - source_labels: ["__meta_filepath"] + regex: "\\/mnt\\/miners_(.+?)\\.json.*" + target_label: "building" + # Get rid of port in address + - source_labels: ["__address__"] + regex: "^(.+?):.*" + target_label: "instance" + ################################################################################### + # The following is optional. Useful if you manage your farm by using + # subnets. + # Extract the site ID (second octet of IPv4 address) + - source_labels: ["__address__"] + regex: "\\d+\\.(\\d+)\\.\\d+\\.\\d+.*" + target_label: "site_id" + # Extract the subnet ID (third octet of IPv4 address) + - source_labels: ["__address__"] + regex: "\\d+\\.\\d+\\.(\\d+)\\.\\d+.*" + target_label: "subnet_id" + # Extract the host ID (last octet of IPv4 address) + - source_labels: ["__address__"] + regex: "\\d+\\.\\d+\\.\\d+\\.(\\d+).*" + target_label: "host_id" + metric_relabel_configs: + ################################################################################### + # Some of the detailed metrics are better removed. You can comment out / remove + # the following section, however doing so will greatly increase the size needed to store + # all the data. Make sure you really need these metrics and your storage size is + # appropriate. + - source_labels: [ __name__ ] + regex: 'client_generated_work|client_order|client_start_total|client_stop_total|dangerous_temperature|fan_rpm_feedback|hashboard_power|hashboard_temperature|hot_temperature|chips_discovered|chips_expected|process_cpu_seconds_total|process_max_fds|process_open_fds|process_resident_memory_bytes|process_start_time_seconds|process_threads|process_virtual_memory_bytes|stratum_job_counter|stratum_last_difficulty|stratum_request_duration_bucket|stratum_request_duration_count|stratum_request_duration_sum|tuner_iteration' + action: drop \ No newline at end of file diff --git a/monitoring/prometheus/prometheus_static.yml b/monitoring/prometheus/prometheus_static.yml new file mode 100644 index 0000000..82723ae --- /dev/null +++ b/monitoring/prometheus/prometheus_static.yml @@ -0,0 +1,57 @@ +# path: /etc/prometheus/prometheus.yml +# Global configuration. +global: + scrape_interval: 15s # Set the scrape interval to every 15 seconds. Default is every 1 minute. + evaluation_interval: 15s # Evaluate rules every 15 seconds. The default is every 1 minute. + # scrape_timeout is set to the global default (10s). + +# Scraping configuration. +scrape_configs: + ## Prometheus can scrape itself to provide system statistics. Not needed, but recommended. + - job_name: 'prometheus' + static_configs: + - targets: ['127.0.0.1:9090', 'nodeexporter:9100'] + + ## You can add multiple jobs to further stratify your farm. Job will appear as label in prometheus + ## Just copy/paste the entire section below at the end of the file and change the name of the job + ## and list of targets. + - job_name: 'braiinsos-data' + metrics_path: '/metrics' + scrape_interval: 5s + static_configs: + ## Use the section below in case when targets are defined statically + # For Braiins OS, list of targets has to include 8081 port + - targets: ['1.2.3.4:8081','5.6.7.8:8081'] + relabel_configs: + ################################################################################### + # The following is an optional static label. Useful if you need to stratify your farm further. + - target_label: "building" + replacement: "Building A" + # Get rid of port in address - this will allow easy click-through from the drill-down dashboards to miner + - source_labels: ["__address__"] + regex: "^(.+?):.*" + target_label: "instance" + ################################################################################### + # The following is optional. Useful if you manage your farm by using + # subnets. + # Extract the site ID (second octet of IPv4 address) + - source_labels: ["__address__"] + regex: "\\d+\\.(\\d+)\\.\\d+\\.\\d+.*" + target_label: "site_id" + # Extract the subnet ID (third octet of IPv4 address) + - source_labels: ["__address__"] + regex: "\\d+\\.\\d+\\.(\\d+)\\.\\d+.*" + target_label: "subnet_id" + # Extract the host ID (last octet of IPv4 address) + - source_labels: ["__address__"] + regex: "\\d+\\.\\d+\\.\\d+\\.(\\d+).*" + target_label: "host_id" + metric_relabel_configs: + ################################################################################### + # Some of the detailed metrics are better removed. You can comment out / remove + # the following section, however doing so will greatly increase the size needed to store + # all the data. Make sure you really need these metrics and your storage size is + # appropriate. + - source_labels: [ __name__ ] + regex: 'client_generated_work|client_order|client_start_total|client_stop_total|dangerous_temperature|fan_rpm_feedback|hashboard_power|hashboard_temperature|hot_temperature|chips_discovered|chips_expected|process_cpu_seconds_total|process_max_fds|process_open_fds|process_resident_memory_bytes|process_start_time_seconds|process_threads|process_virtual_memory_bytes|stratum_job_counter|stratum_last_difficulty|stratum_request_duration_bucket|stratum_request_duration_count|stratum_request_duration_sum|tuner_iteration' + action: drop \ No newline at end of file diff --git a/scan_crontab b/scan_crontab new file mode 100644 index 0000000..b35c739 --- /dev/null +++ b/scan_crontab @@ -0,0 +1,10 @@ +# List of entities to scan +# Each entity must have a unique IP range and name +# In our example, each IP range represents a building. +# At least one row is required when dynamic scan of miners is required + +# ssh_scan.sh "" "entity name" +# see https://crontab.guru/ on how to specify the cron schedule expression + +* */3 * * * * * ssh_scan.sh "1.2.3.0-255" "Building A" +* */3 * * * * * ssh_scan.sh "1.2.0-255.3" "Building B"