Having issues resolving this table error. I recently switched to the stable release and now have these errors. There were about 20-30 others but I was able to resolve them by pasting the fix into the SQL server.
ALTER TABLE ‘pollers’ DROP INDEX PRIMARY
PRIMARY KEY (poller_name
);
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ‘‘pollers’ DROP INDEX PRIMARY
PRIMARY KEY (poller_name
)’ at line 1
====================================
Component | Version |
---|---|
LibreNMS | 1.43 |
DB Schema | 268 |
PHP | 7.2.10-0ubuntu0.18.04.1 |
MySQL | 10.1.34-MariaDB-0ubuntu0.18.04.1 |
RRDTool | 1.7.0 |
SNMP | NET-SNMP 5.7.3 |
====================================
[OK] Composer Version: 1.7.2
[OK] Dependencies up-to-date.
[OK] Database connection successful
[WARN] Your schema (268) is newer than than expected (262). If you just switch to the stable release from the daily release, your database is in between releases and this will be resolved with the next release.
[FAIL] Database: incorrect index (pollers/PRIMARY)
[FAIL] Database: incorrect index (poller_cluster/PRIMARY)
[FAIL] Database: incorrect index (poller_cluster_stats/PRIMARY)
[FAIL] We have detected that your database schema may be wrong, please report the following to us on IRC or the community site (https://t.libren.ms/5gscd):
[FIX] Run the following SQL statements to fix.
SQL Statements:
ALTER TABLE pollers
DROP INDEX PRIMARY
, PRIMARY KEY (poller_name
);
ALTER TABLE poller_cluster
DROP INDEX PRIMARY
, PRIMARY KEY (node_id
);
ALTER TABLE poller_cluster_stats
DROP INDEX PRIMARY
, PRIMARY KEY (parent_poller
,poller_type
);
[WARN] Some devices have not been polled in the last 5 minutes. You may have performance issues.
[FIX] Check your poll log and see:
Devices:
10.3.1.125
[FAIL] Some devices have not completed their polling run in 5 minutes, this will create gaps in data.
[FIX] Check your poll log and see:
Devices:
10.3.1.125
[FAIL] Discovery has not completed in the last 24 hours.
[FIX] Check the cron job to make sure it is running and using discovery-wrapper.py