Snmp-scan.py failing on distributed poller: decoder.py

Here is the error I’m getting when running snmp-scan.py:

Traceback (most recent call last):
File “./snmp-scan.py”, line 227, in
CONFIG = json.loads(
File “/usr/lib/python3.8/json/init.py”, line 357, in loads
return _default_decoder.decode(s)
File “/usr/lib/python3.8/json/decoder.py”, line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “/usr/lib/python3.8/json/decoder.py”, line 355, in raw_decode
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

Output from ./validate.php
[email protected]:~$ ./validate.php

Component Version
LibreNMS 22.1.0-34-ga3bd1b9a6
DB Schema 2021_12_02_113537_ports_stp_designated_cost_change_to_int (234)
PHP 7.4.3
Python 3.8.10
MySQL 10.3.32-MariaDB-0ubuntu0.20.04.1
RRDTool 1.7.2
SNMP 5.8

====================================

[OK] Composer Version: 2.2.5
[OK] Dependencies up-to-date.

Enable distributed polling

$config[‘distributed_poller’] = true;
$config[‘distributed_poller_group’] = 1;
$config[‘distributed_poller_name’] = php_uname(‘n’);
$config[‘distributed_poller_memcached_host’] = “10.100.250.104”;
$config[‘distributed_poller_memcached_port’] = 11211;
$config[‘distributed_poller’] = true;
$config[‘rrdcached’] = “10.100.250.104:42217”;

Default community

$config[‘snmp’][‘community’] = array(‘612.clarionst.snmp2c’);
[OK] Database connection successful
[OK] Database schema correct

What are you typing in when you run snmp-scan.py?

Kevin, thanks for reaching out. I have tried:
./snmp-scan.py
./snmp-scan.py -r 172.20.0.0/16
./snmp-scan.py -v

I THINK the error actually is mis-leading. I think this is actually a redis error, just found this in the /opt/librenms/logs/librenms.log:
[2022-02-01T12:34:02.106139-05:00] production.ERROR: Connection refused [tcp://10.100.250.104:6379] {“exception”:"[object] (Predis\Connection\ConnectionException(code: 111): Connection refused [tcp://10.100.250.104:6379] at /opt/librenms/vendor/predis/predis/src/Connection/AbstractConnection.php:155)"}
[2022-02-01T12:35:02.003458-05:00] production.ERROR: Connection refused [tcp://10.100.250.104:6379] {“exception”:"[object] (Predis\Connection\ConnectionException(code: 111): Connection refused [tcp://10.100.250.104:6379] at /opt/librenms/vendor/predis/predis/src/Connection/AbstractConnection.php:155)"}
[2022-02-01T12:35:02.070828-05:00] production.ERROR: Connection refused [tcp://10.100.250.104:6379] {“exception”:"[object] (Predis\Connection\ConnectionException(code: 111): Connection refused [tcp://10.100.250.104:6379] at /opt/librenms/vendor/predis/predis/src/Connection/AbstractConnection.php:155)"}
[2022-02-01T12:36:01.893530-05:00] production.ERROR: Connection refused [tcp://10.100.250.104:6379] {“exception”:"[object] (Predis\Connection\ConnectionException(code: 111): Connection refused [tcp://10.100.250.104:6379] at /opt/librenms/vendor/predis/predis/src/Connection/AbstractConnection.php:155)"}
[2022-02-01T12:37:02.561853-05:00] production.ERROR: Connection refused [tcp://10.100.250.104:6379] {“exception”:"[object] (Predis\Connection\ConnectionException(code: 111): Connection refused [tcp://10.100.250.104:6379] at /opt/librenms/vendor/predis/predis/src/Connection/AbstractConnection.php:155)"}

As a test I did a second install on a different server, same result. HOWEVER, I did get a little more information firing off some of the other tasks:

/opt/librenms/discovery-wrapper.py 1
ERROR: Could not execute command [[’/usr/bin/env’, ‘php’, ‘/opt/librenms/config_to_json.php’]]: Expecting value: line 1 column 1 (char 0)
Could not run discovery wrapper. Missing config

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.