Added Hashrate chain element

This commit is contained in:
2022-02-27 14:18:50 +08:00
parent f0ba2c2fd1
commit 989c26de60
15 changed files with 5815 additions and 5649 deletions
+21 -21
View File
@@ -1,21 +1,21 @@
#!/bin/bash
up=`/usr/bin/fping -c1 -t300 $1 &> /dev/null ; echo $?`
if [ $up = 0 ]; then
set -o errexit
set -o nounset
ADDRESS=$1
PORT=$2
stats_raw=`echo '{"id":0,"jsonrpc":"2.0","method":"miner_getstat1"}' | nc $ADDRESS $PORT | tr -d '\0\n'`
stats_raw=$(sed 's/}{/\},{/' <<< "$stats_raw")
#STATS=$(jq '.STATS' <<< "$stats_raw")
#echo $STATS
echo $stats_raw
fi
#!/bin/bash
up=`/usr/bin/fping -c1 -t300 $1 &> /dev/null ; echo $?`
if [ $up = 0 ]; then
set -o errexit
set -o nounset
ADDRESS=$1
PORT=$2
stats_raw=`echo '{"id":0,"jsonrpc":"2.0","method":"miner_getstat1"}' | nc $ADDRESS $PORT | tr -d '\0\n'`
stats_raw=$(sed 's/}{/\},{/' <<< "$stats_raw")
#STATS=$(jq '.STATS' <<< "$stats_raw")
#echo $STATS
echo $stats_raw
fi
+37 -37
View File
@@ -1,38 +1,38 @@
#!/usr/bin/env python2.7
import socket
import json
import requests
import sys, os
command = sys.argv[1]
ip = sys.argv[2]
port = 4028
def stats(ip):
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.settimeout(1)
try:
sock.connect((ip, int(port)))
sock.send(json.dumps({'command': command}))
resp = ''
while 1:
buf = sock.recv(4096).decode("utf-8")
if buf:
resp += buf
else:
break
res = command.upper()
result = json.loads(resp[:-1].replace('}{', '},{'))
result = json.dumps(result[res])
print result
except Exception as e:
print("Error " + str(e))
finally:
sock.shutdown(socket.SHUT_RDWR)
sock.close()
#!/usr/bin/env python2.7
import socket
import json
import requests
import sys, os
command = sys.argv[1]
ip = sys.argv[2]
port = 4028
def stats(ip):
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.settimeout(1)
try:
sock.connect((ip, int(port)))
sock.send(json.dumps({'command': command}))
resp = ''
while 1:
buf = sock.recv(4096).decode("utf-8")
if buf:
resp += buf
else:
break
res = command.upper()
result = json.loads(resp[:-1].replace('}{', '},{'))
result = json.dumps(result[res])
print result
except Exception as e:
print("Error " + str(e))
finally:
sock.shutdown(socket.SHUT_RDWR)
sock.close()
stats(ip)
+6 -6
View File
@@ -1,6 +1,6 @@
# External script and tepmlates for Getting Antminer and GPU Claymore Farm metrics into Zabbix
**#Antminer scripts (Antminer S9, L3 ...)**
* Miner - Feech asic JSON information
* rebootasic - Reboot asic wihtout ssh
* FarmGetstats - Get Claymor GPU Farm json information
# External script and tepmlates for Getting Antminer and GPU Claymore Farm metrics into Zabbix
**#Antminer scripts (Antminer S9, L3 ...)**
* Miner - Feech asic JSON information
* rebootasic - Reboot asic wihtout ssh
* FarmGetstats - Get Claymor GPU Farm json information
+33 -33
View File
@@ -1,34 +1,34 @@
#!/usr/bin/env python
import socket, httplib, httplib2
import sys
URL = "http://"+sys.argv[1]+"/cgi-bin/reboot.cgi"
USER = sys.argv[2]
USER_DEFAULT = "root"
PASS = sys.argv[3]
PASS_DEFAULT = "root"
h = httplib2.Http(cache=None, timeout=0.5)
h.add_credentials(USER, PASS)
try:
response, content = h.request(URL, "GET", headers={'cache-control':'no-cache'})
if response.status==401:
retry = httplib2.Http(cache=None, timeout=0.5)
retry.add_credentials(USER_DEFAULT, PASS_DEFAULT)
res, con = retry.request(URL, "GET", headers={'cache-control':'no-cache'})
if res.status==500:
print "Change pass, Installed default password"
print "OK"
elif res.status==401:
print "Unauthorized, Wrong PASSWORD"
if response.status==500:
print "OK"
elif response.status==404:
URL = "http://"+sys.argv[1]+"/api/reboot"
response, content = h.request(URL, "GET", headers={'cache-control':'no-cache'})
except httplib2.ServerNotFoundError:
print "HOST is Down"
except (socket.timeout, socket.error, httplib2.HttpLib2Error, httplib.ResponseNotReady):
#!/usr/bin/env python
import socket, httplib, httplib2
import sys
URL = "http://"+sys.argv[1]+"/cgi-bin/reboot.cgi"
USER = sys.argv[2]
USER_DEFAULT = "root"
PASS = sys.argv[3]
PASS_DEFAULT = "root"
h = httplib2.Http(cache=None, timeout=0.5)
h.add_credentials(USER, PASS)
try:
response, content = h.request(URL, "GET", headers={'cache-control':'no-cache'})
if response.status==401:
retry = httplib2.Http(cache=None, timeout=0.5)
retry.add_credentials(USER_DEFAULT, PASS_DEFAULT)
res, con = retry.request(URL, "GET", headers={'cache-control':'no-cache'})
if res.status==500:
print "Change pass, Installed default password"
print "OK"
elif res.status==401:
print "Unauthorized, Wrong PASSWORD"
if response.status==500:
print "OK"
elif response.status==404:
URL = "http://"+sys.argv[1]+"/api/reboot"
response, content = h.request(URL, "GET", headers={'cache-control':'no-cache'})
except httplib2.ServerNotFoundError:
print "HOST is Down"
except (socket.timeout, socket.error, httplib2.HttpLib2Error, httplib.ResponseNotReady):
print "ERROR"
+289 -289
View File
@@ -1,289 +1,289 @@
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>5.0</version>
<date>2020-06-10T13:56:16Z</date>
<groups>
<group>
<name>Aixin A1</name>
</group>
</groups>
<templates>
<template>
<template>Aixin A1</template>
<name>Aixin A1</name>
<groups>
<group>
<name>Aixin A1</name>
</group>
</groups>
<items>
<item>
<name>Elapsed</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Elapsed</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Elapsed']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan1</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Fan1</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan0 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan2</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Fan2</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan1 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Hashrate</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Hashrate</key>
<delay>0</delay>
<history>60d</history>
<trends>60d</trends>
<units>TH/s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['MHS 5s']</params>
</step>
<step>
<type>MULTIPLIER</type>
<params>0.001</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp1</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Temp1</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp2</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Temp2</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp3</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Temp3</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[2]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>UP_DOwn</name>
<type>SIMPLE</type>
<key>icmpping</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
<item>
<name>AntMinerGetAlldevs</name>
<type>EXTERNAL</type>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllpool</name>
<type>EXTERNAL</type>
<key>Miner[&quot;pools&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllstats</name>
<type>EXTERNAL</type>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllsummary</name>
<type>EXTERNAL</type>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>Asic</name>
<type>SIMPLE</type>
<key>net.tcp.service[tcp,,4028]</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
</items>
<macros>
<macro>
<macro>{$FAN_LOW}</macro>
<value>500</value>
</macro>
<macro>
<macro>{$HASH_LOW}</macro>
<value>18000</value>
</macro>
<macro>
<macro>{$HOST.PORT}</macro>
<value>4028</value>
</macro>
<macro>
<macro>{$TEMP_LOW}</macro>
<value>90</value>
</macro>
<macro>
<macro>{$UNAME}</macro>
<value>manager</value>
</macro>
<macro>
<macro>{$UPASS}</macro>
<type>SECRET_TEXT</type>
</macro>
</macros>
</template>
</templates>
<triggers>
<trigger>
<expression>{Aixin A1:AntMinerA1.Hashrate.nodata(15m)}=1 and {Aixin A1:icmpping.last()}=1</expression>
<name>AntMiner A1 Hashrate information not available on {HOST.NAME}</name>
<priority>HIGH</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Aixin A1:AntMinerA1.Temp1.min(15m)}&gt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp2.min(15m)}&gt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp3.min(15m)}&gt;{$TEMP_LOW}) and {Aixin A1:icmpping.last()}=1</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>({Aixin A1:AntMinerA1.Temp1.last()}&lt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp2.last()}&lt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp3.last()}&lt;{$TEMP_LOW}) and {Aixin A1:icmpping.last()}=1</recovery_expression>
<name>AntMiner A1 High temp on {HOST.NAME}</name>
<priority>AVERAGE</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>{Aixin A1:icmpping.last(5m)}=0 and {Aixin A1:net.tcp.service[tcp,,4028].last(5m)}=0</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Aixin A1:icmpping.last()}=1 or {Aixin A1:net.tcp.service[tcp,,4028].last()}=1</recovery_expression>
<name>AntMiner A1 Host DOWN {HOST.NAME}</name>
<priority>DISASTER</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Aixin A1:AntMinerA1.Fan1.last(10m)}&lt;{$FAN_LOW} or {Aixin A1:AntMinerA1.Fan2.last(10m)}&lt;{$FAN_LOW}) and {Aixin A1:icmpping.last()}=1</expression>
<name>AntMiner A1 low fan speed {HOST.NAME}</name>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Aixin A1:AntMinerA1.Hashrate.last()}&lt;{$HASH_LOW} and {Aixin A1:AntMinerA1.Elapsed.last()}&gt;600) and ({Aixin A1:icmpping.last()}=1 and {Aixin A1:net.tcp.service[tcp,,4028].last()}=1)</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Aixin A1:AntMinerA1.Hashrate.last(#3)}&gt;{$HASH_LOW}</recovery_expression>
<name>AntMiner A1 Low hashrate on {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
<value_maps>
<value_map>
<name>Service state</name>
<mappings>
<mapping>
<value>0</value>
<newvalue>Down</newvalue>
</mapping>
<mapping>
<value>1</value>
<newvalue>Up</newvalue>
</mapping>
</mappings>
</value_map>
</value_maps>
</zabbix_export>
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>5.0</version>
<date>2020-06-10T13:56:16Z</date>
<groups>
<group>
<name>Aixin A1</name>
</group>
</groups>
<templates>
<template>
<template>Aixin A1</template>
<name>Aixin A1</name>
<groups>
<group>
<name>Aixin A1</name>
</group>
</groups>
<items>
<item>
<name>Elapsed</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Elapsed</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Elapsed']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan1</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Fan1</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan0 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan2</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Fan2</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan1 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Hashrate</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Hashrate</key>
<delay>0</delay>
<history>60d</history>
<trends>60d</trends>
<units>TH/s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['MHS 5s']</params>
</step>
<step>
<type>MULTIPLIER</type>
<params>0.001</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp1</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Temp1</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp2</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Temp2</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp3</name>
<type>DEPENDENT</type>
<key>AntMinerA1.Temp3</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[2]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>UP_DOwn</name>
<type>SIMPLE</type>
<key>icmpping</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
<item>
<name>AntMinerGetAlldevs</name>
<type>EXTERNAL</type>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllpool</name>
<type>EXTERNAL</type>
<key>Miner[&quot;pools&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllstats</name>
<type>EXTERNAL</type>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllsummary</name>
<type>EXTERNAL</type>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>Asic</name>
<type>SIMPLE</type>
<key>net.tcp.service[tcp,,4028]</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
</items>
<macros>
<macro>
<macro>{$FAN_LOW}</macro>
<value>500</value>
</macro>
<macro>
<macro>{$HASH_LOW}</macro>
<value>18000</value>
</macro>
<macro>
<macro>{$HOST.PORT}</macro>
<value>4028</value>
</macro>
<macro>
<macro>{$TEMP_LOW}</macro>
<value>90</value>
</macro>
<macro>
<macro>{$UNAME}</macro>
<value>manager</value>
</macro>
<macro>
<macro>{$UPASS}</macro>
<type>SECRET_TEXT</type>
</macro>
</macros>
</template>
</templates>
<triggers>
<trigger>
<expression>{Aixin A1:AntMinerA1.Hashrate.nodata(15m)}=1 and {Aixin A1:icmpping.last()}=1</expression>
<name>AntMiner A1 Hashrate information not available on {HOST.NAME}</name>
<priority>HIGH</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Aixin A1:AntMinerA1.Temp1.min(15m)}&gt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp2.min(15m)}&gt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp3.min(15m)}&gt;{$TEMP_LOW}) and {Aixin A1:icmpping.last()}=1</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>({Aixin A1:AntMinerA1.Temp1.last()}&lt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp2.last()}&lt;{$TEMP_LOW} or {Aixin A1:AntMinerA1.Temp3.last()}&lt;{$TEMP_LOW}) and {Aixin A1:icmpping.last()}=1</recovery_expression>
<name>AntMiner A1 High temp on {HOST.NAME}</name>
<priority>AVERAGE</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>{Aixin A1:icmpping.last(5m)}=0 and {Aixin A1:net.tcp.service[tcp,,4028].last(5m)}=0</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Aixin A1:icmpping.last()}=1 or {Aixin A1:net.tcp.service[tcp,,4028].last()}=1</recovery_expression>
<name>AntMiner A1 Host DOWN {HOST.NAME}</name>
<priority>DISASTER</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Aixin A1:AntMinerA1.Fan1.last(10m)}&lt;{$FAN_LOW} or {Aixin A1:AntMinerA1.Fan2.last(10m)}&lt;{$FAN_LOW}) and {Aixin A1:icmpping.last()}=1</expression>
<name>AntMiner A1 low fan speed {HOST.NAME}</name>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Aixin A1:AntMinerA1.Hashrate.last()}&lt;{$HASH_LOW} and {Aixin A1:AntMinerA1.Elapsed.last()}&gt;600) and ({Aixin A1:icmpping.last()}=1 and {Aixin A1:net.tcp.service[tcp,,4028].last()}=1)</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Aixin A1:AntMinerA1.Hashrate.last(#3)}&gt;{$HASH_LOW}</recovery_expression>
<name>AntMiner A1 Low hashrate on {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
<value_maps>
<value_map>
<name>Service state</name>
<mappings>
<mapping>
<value>0</value>
<newvalue>Down</newvalue>
</mapping>
<mapping>
<value>1</value>
<newvalue>Up</newvalue>
</mapping>
</mappings>
</value_map>
</value_maps>
</zabbix_export>
+1895 -1895
View File
File diff suppressed because it is too large Load Diff
+572 -572
View File
File diff suppressed because it is too large Load Diff
+71 -2
View File
@@ -1,6 +1,6 @@
zabbix_export:
version: '5.2'
date: '2021-10-07T01:08:08Z'
date: '2022-02-27T06:16:08Z'
groups:
-
name: 'Antminer S19'
@@ -132,6 +132,75 @@ zabbix_export:
- '0.001'
master_item:
key: 'Miner["stats", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: Hashrate1
type: DEPENDENT
key: AntMinerT17.Hashrate1
delay: '0'
history: 1d
trends: 1d
value_type: FLOAT
units: TH/s
applications:
-
name: AntMinerT17
preprocessing:
-
type: JSONPATH
parameters:
- '$[1][''chain_rate1'']'
-
type: MULTIPLIER
parameters:
- '0.001'
master_item:
key: 'Miner["stats", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: Hashrate2
type: DEPENDENT
key: AntMinerT17.Hashrate2
delay: '0'
history: 1d
trends: 1d
value_type: FLOAT
units: TH/s
applications:
-
name: AntMinerT17
preprocessing:
-
type: JSONPATH
parameters:
- '$[1][''chain_rate2'']'
-
type: MULTIPLIER
parameters:
- '0.001'
master_item:
key: 'Miner["stats", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: Hashrate3
type: DEPENDENT
key: AntMinerT17.Hashrate3
delay: '0'
history: 1d
trends: 1d
value_type: FLOAT
units: TH/s
applications:
-
name: AntMinerT17
preprocessing:
-
type: JSONPATH
parameters:
- '$[1][''chain_rate3'']'
-
type: MULTIPLIER
parameters:
- '0.001'
master_item:
key: 'Miner["stats", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: LastOnline_pool1
type: DEPENDENT
@@ -392,7 +461,7 @@ zabbix_export:
value: '1200'
-
macro: '{$TEMP_LOW}'
value: '90'
value: '85'
-
macro: '{$UNAME}'
value: root
+847 -847
View File
File diff suppressed because it is too large Load Diff
+98 -1
View File
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>5.2</version>
<date>2021-10-07T01:08:45Z</date>
<date>2022-02-27T06:12:24Z</date>
<groups>
<group>
<name>Antminer T17</name>
@@ -185,6 +185,102 @@
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Hashrate5</name>
<type>DEPENDENT</type>
<key>AntMinerT17.Hashrate5</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<value_type>FLOAT</value_type>
<units>TH/s</units>
<applications>
<application>
<name>AntMinerT17</name>
</application>
</applications>
<preprocessing>
<step>
<type>JSONPATH</type>
<parameters>
<parameter>$[1]['chain_rate1']</parameter>
</parameters>
</step>
<step>
<type>MULTIPLIER</type>
<parameters>
<parameter>0.001</parameter>
</parameters>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Hashrate6</name>
<type>DEPENDENT</type>
<key>AntMinerT17.Hashrate6</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<value_type>FLOAT</value_type>
<units>TH/s</units>
<applications>
<application>
<name>AntMinerT17</name>
</application>
</applications>
<preprocessing>
<step>
<type>JSONPATH</type>
<parameters>
<parameter>$[1]['chain_rate2']</parameter>
</parameters>
</step>
<step>
<type>MULTIPLIER</type>
<parameters>
<parameter>0.001</parameter>
</parameters>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Hashrate7</name>
<type>DEPENDENT</type>
<key>AntMinerT17.Hashrate7</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<value_type>FLOAT</value_type>
<units>TH/s</units>
<applications>
<application>
<name>AntMinerT17</name>
</application>
</applications>
<preprocessing>
<step>
<type>JSONPATH</type>
<parameters>
<parameter>$[1]['chain_rate3']</parameter>
</parameters>
</step>
<step>
<type>MULTIPLIER</type>
<parameters>
<parameter>0.001</parameter>
</parameters>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>LastOnline_pool1</name>
<type>DEPENDENT</type>
@@ -599,6 +695,7 @@ return $123;</parameter>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{AntMiner T17:AntMinerT17.Fan_num.last()}=2</recovery_expression>
<name>Асик завис !!!</name>
<status>DISABLED</status>
<manual_close>YES</manual_close>
</trigger>
</triggers>
+307 -307
View File
@@ -1,307 +1,307 @@
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>5.0</version>
<date>2020-06-10T13:57:57Z</date>
<groups>
<group>
<name>Cheetah F1</name>
</group>
</groups>
<templates>
<template>
<template>Cheetah F1</template>
<name>Cheetah F1</name>
<groups>
<group>
<name>Cheetah F1</name>
</group>
</groups>
<items>
<item>
<name>Elapsed</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Elapsed</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Elapsed']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan1</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Fan1</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan0 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan2</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Fan2</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan0 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Hashrate</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Hashrate</key>
<delay>0</delay>
<history>60d</history>
<trends>60d</trends>
<units>TH/s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['MHS 5s']</params>
</step>
<step>
<type>MULTIPLIER</type>
<params>0.001</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp1</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp1</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp2</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp2</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp3</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp3</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[2]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp4</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp4</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[3]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>UP_DOwn</name>
<type>SIMPLE</type>
<key>icmpping</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
<item>
<name>AntMinerGetAlldevs</name>
<type>EXTERNAL</type>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllpool</name>
<type>EXTERNAL</type>
<key>Miner[&quot;pools&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllstats</name>
<type>EXTERNAL</type>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllsummary</name>
<type>EXTERNAL</type>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>Asic</name>
<type>SIMPLE</type>
<key>net.tcp.service[tcp,,4028]</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
</items>
<macros>
<macro>
<macro>{$FAN_LOW}</macro>
<value>500</value>
</macro>
<macro>
<macro>{$HASH_LOW}</macro>
<value>18000</value>
</macro>
<macro>
<macro>{$HOST.PORT}</macro>
<value>4028</value>
</macro>
<macro>
<macro>{$TEMP_LOW}</macro>
<value>90</value>
</macro>
<macro>
<macro>{$UNAME}</macro>
<value>yongyi</value>
</macro>
<macro>
<macro>{$UPASS}</macro>
<type>SECRET_TEXT</type>
</macro>
</macros>
</template>
</templates>
<triggers>
<trigger>
<expression>{Cheetah F1:AntMinerF1.Hashrate.nodata(15m)}=1 and {Cheetah F1:icmpping.last()}=1</expression>
<name>AntMiner F1 Hashrate information not available on {HOST.NAME}</name>
<priority>HIGH</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Cheetah F1:AntMinerF1.Temp1.min(15m)}&gt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp2.min(15m)}&gt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp3.min(15m)}&gt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp4.min(15m)}&gt;{$TEMP_LOW}) and {Cheetah F1:icmpping.last()}=1</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>({Cheetah F1:AntMinerF1.Temp1.last()}&lt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp2.last()}&lt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp3.last()}&lt;{$TEMP_LOW}) and {Cheetah F1:icmpping.last()}=1</recovery_expression>
<name>AntMiner F1 High temp on {HOST.NAME}</name>
<priority>AVERAGE</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>{Cheetah F1:icmpping.last(5m)}=0 and {Cheetah F1:net.tcp.service[tcp,,4028].last(5m)}=0</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Cheetah F1:icmpping.last()}=1 or {Cheetah F1:net.tcp.service[tcp,,4028].last()}=1</recovery_expression>
<name>AntMiner F1 Host DOWN {HOST.NAME}</name>
<priority>DISASTER</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Cheetah F1:AntMinerF1.Fan1.last(10m)}&lt;{$FAN_LOW} or {Cheetah F1:AntMinerF1.Fan2.last(10m)}&lt;{$FAN_LOW}) and {Cheetah F1:icmpping.last()}=1</expression>
<name>AntMiner F1 low fan speed {HOST.NAME}</name>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Cheetah F1:AntMinerF1.Hashrate.last()}&lt;{$HASH_LOW} and {Cheetah F1:AntMinerF1.Elapsed.last()}&gt;600) and ({Cheetah F1:icmpping.last()}=1 and {Cheetah F1:net.tcp.service[tcp,,4028].last()}=1)</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Cheetah F1:AntMinerF1.Hashrate.last(#3)}&gt;{$HASH_LOW}</recovery_expression>
<name>AntMiner F1 Low hashrate on {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
<value_maps>
<value_map>
<name>Service state</name>
<mappings>
<mapping>
<value>0</value>
<newvalue>Down</newvalue>
</mapping>
<mapping>
<value>1</value>
<newvalue>Up</newvalue>
</mapping>
</mappings>
</value_map>
</value_maps>
</zabbix_export>
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>5.0</version>
<date>2020-06-10T13:57:57Z</date>
<groups>
<group>
<name>Cheetah F1</name>
</group>
</groups>
<templates>
<template>
<template>Cheetah F1</template>
<name>Cheetah F1</name>
<groups>
<group>
<name>Cheetah F1</name>
</group>
</groups>
<items>
<item>
<name>Elapsed</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Elapsed</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Elapsed']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan1</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Fan1</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan0 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Fan2</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Fan2</key>
<delay>0</delay>
<history>1d</history>
<trends>0</trends>
<units>RPM</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Fan0 rpm']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Hashrate</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Hashrate</key>
<delay>0</delay>
<history>60d</history>
<trends>60d</trends>
<units>TH/s</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['MHS 5s']</params>
</step>
<step>
<type>MULTIPLIER</type>
<params>0.001</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp1</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp1</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[0]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp2</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp2</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[1]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp3</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp3</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[2]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>Temp4</name>
<type>DEPENDENT</type>
<key>AntMinerF1.Temp4</key>
<delay>0</delay>
<history>1d</history>
<trends>1d</trends>
<units>C</units>
<preprocessing>
<step>
<type>JSONPATH</type>
<params>$[3]['Temperature']</params>
</step>
</preprocessing>
<master_item>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
</master_item>
</item>
<item>
<name>UP_DOwn</name>
<type>SIMPLE</type>
<key>icmpping</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
<item>
<name>AntMinerGetAlldevs</name>
<type>EXTERNAL</type>
<key>Miner[&quot;devs&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllpool</name>
<type>EXTERNAL</type>
<key>Miner[&quot;pools&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllstats</name>
<type>EXTERNAL</type>
<key>Miner[&quot;stats&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>AntMinerGetAllsummary</name>
<type>EXTERNAL</type>
<key>Miner[&quot;summary&quot;, &quot;{HOST.CONN}&quot;, &quot;{$HOST.PORT}&quot;]</key>
<delay>300s</delay>
<history>0</history>
<trends>0</trends>
<value_type>TEXT</value_type>
</item>
<item>
<name>Asic</name>
<type>SIMPLE</type>
<key>net.tcp.service[tcp,,4028]</key>
<delay>60s</delay>
<history>60d</history>
<trends>60d</trends>
<valuemap>
<name>Service state</name>
</valuemap>
</item>
</items>
<macros>
<macro>
<macro>{$FAN_LOW}</macro>
<value>500</value>
</macro>
<macro>
<macro>{$HASH_LOW}</macro>
<value>18000</value>
</macro>
<macro>
<macro>{$HOST.PORT}</macro>
<value>4028</value>
</macro>
<macro>
<macro>{$TEMP_LOW}</macro>
<value>90</value>
</macro>
<macro>
<macro>{$UNAME}</macro>
<value>yongyi</value>
</macro>
<macro>
<macro>{$UPASS}</macro>
<type>SECRET_TEXT</type>
</macro>
</macros>
</template>
</templates>
<triggers>
<trigger>
<expression>{Cheetah F1:AntMinerF1.Hashrate.nodata(15m)}=1 and {Cheetah F1:icmpping.last()}=1</expression>
<name>AntMiner F1 Hashrate information not available on {HOST.NAME}</name>
<priority>HIGH</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Cheetah F1:AntMinerF1.Temp1.min(15m)}&gt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp2.min(15m)}&gt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp3.min(15m)}&gt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp4.min(15m)}&gt;{$TEMP_LOW}) and {Cheetah F1:icmpping.last()}=1</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>({Cheetah F1:AntMinerF1.Temp1.last()}&lt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp2.last()}&lt;{$TEMP_LOW} or {Cheetah F1:AntMinerF1.Temp3.last()}&lt;{$TEMP_LOW}) and {Cheetah F1:icmpping.last()}=1</recovery_expression>
<name>AntMiner F1 High temp on {HOST.NAME}</name>
<priority>AVERAGE</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>{Cheetah F1:icmpping.last(5m)}=0 and {Cheetah F1:net.tcp.service[tcp,,4028].last(5m)}=0</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Cheetah F1:icmpping.last()}=1 or {Cheetah F1:net.tcp.service[tcp,,4028].last()}=1</recovery_expression>
<name>AntMiner F1 Host DOWN {HOST.NAME}</name>
<priority>DISASTER</priority>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Cheetah F1:AntMinerF1.Fan1.last(10m)}&lt;{$FAN_LOW} or {Cheetah F1:AntMinerF1.Fan2.last(10m)}&lt;{$FAN_LOW}) and {Cheetah F1:icmpping.last()}=1</expression>
<name>AntMiner F1 low fan speed {HOST.NAME}</name>
<manual_close>YES</manual_close>
</trigger>
<trigger>
<expression>({Cheetah F1:AntMinerF1.Hashrate.last()}&lt;{$HASH_LOW} and {Cheetah F1:AntMinerF1.Elapsed.last()}&gt;600) and ({Cheetah F1:icmpping.last()}=1 and {Cheetah F1:net.tcp.service[tcp,,4028].last()}=1)</expression>
<recovery_mode>RECOVERY_EXPRESSION</recovery_mode>
<recovery_expression>{Cheetah F1:AntMinerF1.Hashrate.last(#3)}&gt;{$HASH_LOW}</recovery_expression>
<name>AntMiner F1 Low hashrate on {HOST.NAME}</name>
<priority>WARNING</priority>
<manual_close>YES</manual_close>
</trigger>
</triggers>
<value_maps>
<value_map>
<name>Service state</name>
<mappings>
<mapping>
<value>0</value>
<newvalue>Down</newvalue>
</mapping>
<mapping>
<value>1</value>
<newvalue>Up</newvalue>
</mapping>
</mappings>
</value_map>
</value_maps>
</zabbix_export>
+1373 -1373
View File
File diff suppressed because it is too large Load Diff
+175 -175
View File
@@ -1,175 +1,175 @@
zabbix_export:
version: '5.2'
date: '2021-03-29T07:44:35Z'
groups:
-
name: Whatsminer
templates:
-
template: Whatsminer
name: Whatsminer
groups:
-
name: Whatsminer
applications:
-
name: WhatsHW
-
name: WhatsInfo
-
name: WhatsState
items:
-
name: Fan-In
type: DEPENDENT
key: FanIn
delay: '0'
history: 1d
trends: '0'
value_type: FLOAT
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''Fan Speed In'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: Fan-Out
type: DEPENDENT
key: FanOut
delay: '0'
history: 1d
trends: '0'
value_type: FLOAT
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''Fan Speed Out'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: Hashrate
type: DEPENDENT
key: Hash
delay: '0'
history: 1d
trends: '0'
value_type: FLOAT
units: TH/s
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''MHS av'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: UpDown
type: SIMPLE
key: icmpping
delay: 60s
history: 1d
trends: '0'
applications:
-
name: WhatsState
valuemap:
name: 'Service state'
-
name: Asic
type: SIMPLE
key: 'net.tcp.service[tcp,,4028]'
delay: 60s
history: 1d
trends: '0'
applications:
-
name: WhatsState
valuemap:
name: 'Service state'
request_method: POST
-
name: Temperature
type: DEPENDENT
key: Temp
delay: '0'
history: 1d
trends: '0'
value_type: TEXT
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''Temperature'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: AsicPolls
type: EXTERNAL
key: 'Whats["pools", "{HOST.CONN}", "{$HOST.PORT}"]'
delay: 300s
history: '0'
trends: '0'
value_type: TEXT
applications:
-
name: WhatsInfo
-
name: AsicSummary
type: EXTERNAL
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
delay: 300s
history: 1d
trends: '0'
value_type: TEXT
applications:
-
name: WhatsInfo
macros:
-
macro: '{$TEMP_HIGH}'
value: '80'
triggers:
-
expression: '{Whatsminer:Hash.nodata(15m)}=1 and {Whatsminer:icmpping.last()}=1'
name: 'Whatsminer Hashrate information not available on {HOST.NAME}'
priority: HIGH
manual_close: 'YES'
-
expression: '{Whatsminer:icmpping.max(#3)}=0 and {Whatsminer:net.tcp.service[tcp,,4028].last(#3)}=0'
recovery_mode: RECOVERY_EXPRESSION
recovery_expression: '{Whatsminer:icmpping.last()}=1 and {Whatsminer:net.tcp.service[tcp,,4028].last()}=1'
name: 'WhatsMiner Host Down {HOST.NAME}'
priority: DISASTER
manual_close: 'YES'
-
expression: '{Whatsminer:Temp.last(,15m)}>{$TEMP_HIGH} and {Whatsminer:icmpping.last()}=1'
recovery_mode: RECOVERY_EXPRESSION
recovery_expression: '{Whatsminer:Temp.last(,15m)}<{$HIGH_TEMP} and {Whatsminer:icmpping.last()}=1'
name: 'Whatsminer {HOST.NAME} High Temp'
priority: AVERAGE
manual_close: 'YES'
value_maps:
-
name: 'Service state'
mappings:
-
value: '0'
newvalue: Down
-
value: '1'
newvalue: Up
zabbix_export:
version: '5.2'
date: '2021-03-29T07:44:35Z'
groups:
-
name: Whatsminer
templates:
-
template: Whatsminer
name: Whatsminer
groups:
-
name: Whatsminer
applications:
-
name: WhatsHW
-
name: WhatsInfo
-
name: WhatsState
items:
-
name: Fan-In
type: DEPENDENT
key: FanIn
delay: '0'
history: 1d
trends: '0'
value_type: FLOAT
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''Fan Speed In'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: Fan-Out
type: DEPENDENT
key: FanOut
delay: '0'
history: 1d
trends: '0'
value_type: FLOAT
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''Fan Speed Out'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: Hashrate
type: DEPENDENT
key: Hash
delay: '0'
history: 1d
trends: '0'
value_type: FLOAT
units: TH/s
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''MHS av'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: UpDown
type: SIMPLE
key: icmpping
delay: 60s
history: 1d
trends: '0'
applications:
-
name: WhatsState
valuemap:
name: 'Service state'
-
name: Asic
type: SIMPLE
key: 'net.tcp.service[tcp,,4028]'
delay: 60s
history: 1d
trends: '0'
applications:
-
name: WhatsState
valuemap:
name: 'Service state'
request_method: POST
-
name: Temperature
type: DEPENDENT
key: Temp
delay: '0'
history: 1d
trends: '0'
value_type: TEXT
applications:
-
name: WhatsHW
preprocessing:
-
type: JSONPATH
parameters:
- '$[0][''Temperature'']'
master_item:
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
-
name: AsicPolls
type: EXTERNAL
key: 'Whats["pools", "{HOST.CONN}", "{$HOST.PORT}"]'
delay: 300s
history: '0'
trends: '0'
value_type: TEXT
applications:
-
name: WhatsInfo
-
name: AsicSummary
type: EXTERNAL
key: 'Whats["summary", "{HOST.CONN}", "{$HOST.PORT}"]'
delay: 300s
history: 1d
trends: '0'
value_type: TEXT
applications:
-
name: WhatsInfo
macros:
-
macro: '{$TEMP_HIGH}'
value: '80'
triggers:
-
expression: '{Whatsminer:Hash.nodata(15m)}=1 and {Whatsminer:icmpping.last()}=1'
name: 'Whatsminer Hashrate information not available on {HOST.NAME}'
priority: HIGH
manual_close: 'YES'
-
expression: '{Whatsminer:icmpping.max(#3)}=0 and {Whatsminer:net.tcp.service[tcp,,4028].last(#3)}=0'
recovery_mode: RECOVERY_EXPRESSION
recovery_expression: '{Whatsminer:icmpping.last()}=1 and {Whatsminer:net.tcp.service[tcp,,4028].last()}=1'
name: 'WhatsMiner Host Down {HOST.NAME}'
priority: DISASTER
manual_close: 'YES'
-
expression: '{Whatsminer:Temp.last(,15m)}>{$TEMP_HIGH} and {Whatsminer:icmpping.last()}=1'
recovery_mode: RECOVERY_EXPRESSION
recovery_expression: '{Whatsminer:Temp.last(,15m)}<{$HIGH_TEMP} and {Whatsminer:icmpping.last()}=1'
name: 'Whatsminer {HOST.NAME} High Temp'
priority: AVERAGE
manual_close: 'YES'
value_maps:
-
name: 'Service state'
mappings:
-
value: '0'
newvalue: Down
-
value: '1'
newvalue: Up
+48 -48
View File
@@ -1,48 +1,48 @@
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>4.2</version>
<date>2019-07-10T14:29:22Z</date>
<value_maps>
<value_map>
<name>Asic</name>
<mappings>
<mapping>
<value>1</value>
<newvalue>Normal</newvalue>
</mapping>
<mapping>
<value>240</value>
<newvalue>Low Power Enhanced Mode</newvalue>
</mapping>
<mapping>
<value>241</value>
<newvalue>HashRate-0.5TH/S</newvalue>
</mapping>
<mapping>
<value>242</value>
<newvalue>HashRate-1.0TH/S</newvalue>
</mapping>
<mapping>
<value>243</value>
<newvalue>HashRate-1.5TH/S</newvalue>
</mapping>
<mapping>
<value>244</value>
<newvalue>HashRate-2.0TH/S</newvalue>
</mapping>
<mapping>
<value>245</value>
<newvalue>HashRate-2.5TH/S</newvalue>
</mapping>
<mapping>
<value>246</value>
<newvalue>HashRate-3.0TH/S</newvalue>
</mapping>
<mapping>
<value>250</value>
<newvalue>Hashrate Unchanged - Lower Voltage</newvalue>
</mapping>
</mappings>
</value_map>
</value_maps>
</zabbix_export>
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>4.2</version>
<date>2019-07-10T14:29:22Z</date>
<value_maps>
<value_map>
<name>Asic</name>
<mappings>
<mapping>
<value>1</value>
<newvalue>Normal</newvalue>
</mapping>
<mapping>
<value>240</value>
<newvalue>Low Power Enhanced Mode</newvalue>
</mapping>
<mapping>
<value>241</value>
<newvalue>HashRate-0.5TH/S</newvalue>
</mapping>
<mapping>
<value>242</value>
<newvalue>HashRate-1.0TH/S</newvalue>
</mapping>
<mapping>
<value>243</value>
<newvalue>HashRate-1.5TH/S</newvalue>
</mapping>
<mapping>
<value>244</value>
<newvalue>HashRate-2.0TH/S</newvalue>
</mapping>
<mapping>
<value>245</value>
<newvalue>HashRate-2.5TH/S</newvalue>
</mapping>
<mapping>
<value>246</value>
<newvalue>HashRate-3.0TH/S</newvalue>
</mapping>
<mapping>
<value>250</value>
<newvalue>Hashrate Unchanged - Lower Voltage</newvalue>
</mapping>
</mappings>
</value_map>
</value_maps>
</zabbix_export>
+43 -43
View File
@@ -1,44 +1,44 @@
LogFile=/var/log/zabbix/zabbix_server.log
LogFileSize=1
DebugLevel=1
PidFile=/var/run/zabbix/zabbix_server.pid
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=password
DBSocket=/var/run/mysqld/mysqld.sock
# DBPort=
StartPollers=32
# StartPreprocessors=3
StartPollersUnreachable=16
StartTrappers=15
StartPingers=32
# StartDiscoverers=1
StartHTTPPollers=0
StartEscalators=10
# StartAlerters=3
ListenIP=0.0.0.0
HousekeepingFrequency=0
# MaxHousekeeperDelete=0
CacheSize=1G
StartDBSyncers=10
HistoryCacheSize=512M
#HistoryIndexCacheSize=128M
TrendCacheSize=128M
ValueCacheSize=256M
Timeout=30
# UnreachablePeriod=45
# UnavailableDelay=60
# UnreachableDelay=15
AlertScriptsPath=/usr/lib/zabbix/alertscripts
ExternalScripts=/usr/lib/zabbix/externalscripts
FpingLocation=/usr/bin/fping
LogSlowQueries=3000
# TmpDir=/tmp
StartProxyPollers=0
# ProxyConfigFrequency=3600
# ProxyDataFrequency=1
AllowRoot=1
# User=zabbix
# Include=/usr/local/etc/zabbix_server.conf.d/
LogFile=/var/log/zabbix/zabbix_server.log
LogFileSize=1
DebugLevel=1
PidFile=/var/run/zabbix/zabbix_server.pid
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=password
DBSocket=/var/run/mysqld/mysqld.sock
# DBPort=
StartPollers=32
# StartPreprocessors=3
StartPollersUnreachable=16
StartTrappers=15
StartPingers=32
# StartDiscoverers=1
StartHTTPPollers=0
StartEscalators=10
# StartAlerters=3
ListenIP=0.0.0.0
HousekeepingFrequency=0
# MaxHousekeeperDelete=0
CacheSize=1G
StartDBSyncers=10
HistoryCacheSize=512M
#HistoryIndexCacheSize=128M
TrendCacheSize=128M
ValueCacheSize=256M
Timeout=30
# UnreachablePeriod=45
# UnavailableDelay=60
# UnreachableDelay=15
AlertScriptsPath=/usr/lib/zabbix/alertscripts
ExternalScripts=/usr/lib/zabbix/externalscripts
FpingLocation=/usr/bin/fping
LogSlowQueries=3000
# TmpDir=/tmp
StartProxyPollers=0
# ProxyConfigFrequency=3600
# ProxyDataFrequency=1
AllowRoot=1
# User=zabbix
# Include=/usr/local/etc/zabbix_server.conf.d/
StatsAllowedIP=127.0.0.1