System corrupted original librenms directory, so I installed from git. Now I’m receiving an app key error when validating. I’ve run the suggested “lnms key:rotate” and checked the keys in “.env”. I’ve also generated new keys with ./lnms key:generate, but can’t seem to get the keys to match.
Any insight?
Output of ./validate.php:
===========================================
Component | Version
--------- | -------
LibreNMS | 22.9.0-63-g3e3752eb7 (2022-10-17T12:18:38-05:00)
DB Schema | 2022_09_03_091314_update_ports_adsl_table_with_defaults (246)
PHP | 8.1.11
Python | 3.9.2
Database | MariaDB 10.5.15-MariaDB-0+deb11u1
RRDTool | 1.7.2
SNMP | 5.9
===========================================
[OK] Composer Version: 2.4.3
[OK] Dependencies up-to-date.
[FAIL] APP_KEY does not match key used to encrypt data. APP_KEY must be the same on all nodes.
[FIX]:
If you rotated APP_KEY, run lnms key:rotate to resolve.
[OK] Database connection successful
[OK] Database Schema is current
[OK] SQL Server meets minimum requirements
[OK] lower_case_table_names is enabled
[OK] MySQL engine is optimal
[OK]
[OK] Database schema correct
[OK] MySQl and PHP time match
[OK] Active pollers found
[OK] Dispatcher Service not detected
[OK] Locks are functional
[OK] Python poller wrapper is polling
[OK] Redis is unavailable
[OK] rrdtool version ok
[OK] Connected to rrdcached
And how are we to know we should backup APP_KEY, along with our rrd data, Libre config, php dependencies in a separate directory and sideloaded application data? It would seem the real test of failure isn’t on the user…
Same problem here, didn’t show an advice to save .env, had to reinstall after a disk failure.
Is there a way to reinitialize that app_key as it is not yet used ? (tried the lnms key:rotate --generate-new-key without any success).
Or do I have to do a new installation starting with an empty database ?
I don’t want to populate my instance (which already have 140 devices) with more devices and discover in a few months that I have to start from zero because app_key will now be really used.