Page 1 of 1

Nagiosql MySQL DB connection error

Posted: Thu Sep 22, 2016 5:21 am
by goslinb
Hi Nagios Support,

I'm hoping someone can help me here. I am running nagios 4.2.0 on RHEL 7 box. I was looking for a config tool and cam across nagiosql as probably one of the only ones recommended for core 4.

Ive gone through the installation fine, however when I get to the login page for nagiosql I get a DB connection error, and I cannot login. Error below -

"Error while connectiong to database [localhost] Connection to the database server has failed by reason: Accessed denied for user 'nagiosql_user'@'localhost' (using password: YES)"

I am running the web UI install on the box itself, hence "localhost", but I have tried running from an external browser specifying either the IP or FQHN.

Running mariaDB server 5.5.50. I can log into the DB locally with the nagiosql user, using the mysql console.


Everything checks out on the pre-install steps so I am confused by this one.

Has anyone experienced the same?

At this stage I am also open to trying a different config tool - I just haven't found one for version 4.2.0


Any help/insight much appreciated.

Re: Nagiosql MySQL DB connection error

Posted: Thu Sep 22, 2016 11:04 am
by rkennedy
You mention that 'nagiosql' works to log in to the database, but the access denied is for 'nagiosql_user'. I would take a look at configuration files to make sure you're passing the right credentials.

Just so you know, NagiosQL isn't our product so we're a bit limited on the support we can provide.

Re: Nagiosql MySQL DB connection error

Posted: Fri Sep 23, 2016 4:20 am
by goslinb
Thanks for your reply.

Yes I checked the config file and it looks like the information passed is ok.

Your point led me down the road of credential issues.

I was able to resolve this in a rather strange way. I was setting the db user password (nagiousql_user), to be the same as the nagiosql admin user (admin). I ran the install again and gave unique passwords for both, and things went ok.

Thanks for your help.

Re: Nagiosql MySQL DB connection error

Posted: Fri Sep 23, 2016 10:38 am
by rkennedy
No problem, those little things get us all at times. Glad to see you resolved the issue!

Going to close this one up.