Db Access denied in Frontend

Hi guys,

i have a strange problem with the mysql database connection in librenms.

i done a fresh install on a raspberry pi.

by execute the sudo php validate.php command i get the following output:

====================================
Component | Version
--------- | -------
LibreNMS | 1.41-8-gd9ceaf783
DB Schema | 253
PHP | 7.0.27-0+deb9u1
MySQL | 10.1.23-MariaDB-9+deb9u1
RRDTool | 1.6.0
SNMP | NET-SNMP 5.7.3
====================================

[OK] Composer Version: 1.6.5
[OK] Dependencies up-to-date.
[OK] Database connection successful
[OK] Database schema correct

everything ok… but when i trying to connect via the web interface i get this:

Error connecting to database.

Access denied for user ‘librenms’@‘localhost’ (using password: YES)

some ideas?

thx
p

Did you configure database credentials in the .env file?

hi,

no i just configure this one:
/opt/librenms/config.php

You .env-file (/opt/librenms/.env) should look similar to this:

APP_KEY=base64:sgqGy7GPio9lNnLYCPsbg3nIvq0lma3MP0= (key replaced)

DB_HOST=localhost
DB_DATABASE=YOUR_DB_NAME
DB_USERNAME=YOUR_DB_USER
DB_PASSWORD=YOUR_DB_PW

#APP_URL=
NODE_ID=123abc
DB_PORT=3306
LIBRENMS_USER=YOUR_LIBRENMS_USER

Do you have such file?

yes the file exist, so i updates the db login.
Now the following is now on the index site:

In Red: Whoops, looks like something went wrong.

Have you rerun daily.sh?

Yes

nothing happend.

Have you gone through this?

https://community.librenms.org/t/new-requirements-for-1-40/4057

Maybe you could try to add /debug=yes/ at the end of your URI and see if it shows up some errors