Skip to content

Commit d0dcc11

Browse files
Import TP-Link EAP MIB
Signed-off-by: Jean-Sébastien Hedde <[email protected]>
1 parent 850e8f1 commit d0dcc11

File tree

3 files changed

+29
-1
lines changed

3 files changed

+29
-1
lines changed

generator/Makefile

+15-1
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ LIEBERT_URL := https://www.vertiv.com/globalassets/documents/software/moni
5151
CYBERPOWER_VERSION := 2.10
5252
CYBERPOWER_URL := https://dl4jz3rbrsfum.cloudfront.net/software/CyberPower_MIB_v$(CYBERPOWER_VERSION).MIB.zip
5353

54+
EAP_VERSION := 1.0
55+
EAP_URL := http://static.tp-link.com/EAP_Private_Mibs_$(EAP_VERSION).zip
56+
5457
.DEFAULT: all
5558

5659
.PHONY: all
@@ -126,7 +129,9 @@ mibs: \
126129
$(MIBDIR)/PDU2-MIB.txt \
127130
$(MIBDIR)/Infrapower-MIB.mib \
128131
$(MIBDIR)/LIEBERT_GP_PDU.MIB \
129-
$(MIBDIR)/CyberPower.MIB
132+
$(MIBDIR)/CyberPower.MIB \
133+
$(MIBDIR)/EAP.MIB \
134+
$(MIBDIR)/EAP-Client.MIB
130135

131136
$(MIBDIR)/apc-powernet-mib:
132137
@echo ">> Downloading apc-powernet-mib"
@@ -320,3 +325,12 @@ $(MIBDIR)/CyberPower.MIB:
320325
@sed -i.bak -E 's/(DisplayString[[:space:]]*FROM )RFC1213-MIB/\1SNMPv2-TC/' $@
321326
@rm $@.bak
322327
@rm -v $(TMP)
328+
329+
$(MIBDIR)/EAP.MIB $(MIBDIR)/EAP-Client.MIB:
330+
$(eval TMP := $(shell mktemp))
331+
@echo ">> Downloading EAP.MIB to $(TMP)"
332+
@curl $(CURL_OPTS) -o $(TMP) $(EAP_URL)
333+
@unzip -j -d $(MIBDIR) $(TMP) EAP_Private-Mibs_$(EAP_VERSION)/TPLINK.mib EAP_Private-Mibs_$(EAP_VERSION)/EAP/clientMib/client.mib
334+
@mv -v $(MIBDIR)/TPLINK.mib $(MIBDIR)/EAP.MIB
335+
@mv -v $(MIBDIR)/client.mib $(MIBDIR)/EAP-Client.MIB
336+
@rm -v $(TMP)

generator/generator.yml

+6
Original file line numberDiff line numberDiff line change
@@ -599,3 +599,9 @@ modules:
599599
- 1.3.6.1.4.1.3808.1.1.1 # ups
600600
- 1.3.6.1.4.1.3808.1.1.4 # environmentSensor
601601
- 1.3.6.1.4.1.3808.1.1.6 # ePDU2
602+
#
603+
# TP LINK EAP
604+
# http://static.tp-link.com/EAP_Private_Mibs_1.0.zip
605+
eap:
606+
walk:
607+
- 1.3.6.1.4.1.11863.10.1.1.1 # client count

snmp.yml

+8
Original file line numberDiff line numberDiff line change
@@ -6439,6 +6439,14 @@ modules:
64396439
type: DisplayString
64406440
help: Describes whether the amount of available swap space (as reported by 'memAvailSwap(4)'),
64416441
is less than the desired minimum (specified by 'memMinimumSwap(12)'). - 1.3.6.1.4.1.2021.4.101
6442+
eap:
6443+
get:
6444+
- 1.3.6.1.4.1.11863.10.1.1.1.0
6445+
metrics:
6446+
- name: clientCount
6447+
oid: 1.3.6.1.4.1.11863.10.1.1.1
6448+
type: gauge
6449+
help: this used to get the count of clients - 1.3.6.1.4.1.11863.10.1.1.1
64426450
if_mib:
64436451
walk:
64446452
- 1.3.6.1.2.1.2

0 commit comments

Comments
 (0)