From 80023979b3541bfb6881fe939dda0f9ed5a687b4 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Wed, 29 Dec 2021 21:26:40 +0100 Subject: zte-prometheus-exporter: ... --- overlays/zte-prometheus-exporter/zte-prometheus-exporter.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'overlays') diff --git a/overlays/zte-prometheus-exporter/zte-prometheus-exporter.py b/overlays/zte-prometheus-exporter/zte-prometheus-exporter.py index 67f13716..a0e1f23c 100644 --- a/overlays/zte-prometheus-exporter/zte-prometheus-exporter.py +++ b/overlays/zte-prometheus-exporter/zte-prometheus-exporter.py @@ -172,10 +172,10 @@ class ZTEMetrics: if 'received_bytes' not in eth_metrics: eth_metrics['received_bytes'] = {'type': 'counter', 'metrics': []} - eth_metrics['received_bytes']['metrics'] += [({"link": link_number}, int(self.attrs['ETH'][link]['BytesReceived']))] + eth_metrics['received_bytes']['metrics'] += [({"interface": link_number}, int(self.attrs['ETH'][link]['BytesReceived']))] if 'sent_bytes' not in eth_metrics: eth_metrics['sent_bytes'] = {'type': 'counter', 'metrics': []} - eth_metrics['sent_bytes']['metrics'] += [({"link": link_number}, int(self.attrs['ETH'][link]['BytesSent']))] + eth_metrics['sent_bytes']['metrics'] += [({"interface": link_number}, int(self.attrs['ETH'][link]['BytesSent']))] if eth_metrics: for metric_name in eth_metrics: metrics += _format_prom_metrics(f'eth_{metric_name}', eth_metrics[metric_name]['type'], eth_metrics[metric_name]['metrics']) -- cgit v1.2.3