Nagios 'could not connect' to MySQL database
Werner Flamme
werner.flamme at ufz.de
Tue Aug 16 13:58:53 CEST 2005
Richard.Luys at vanderlet.nl schrieb am 16.08.2005 12:57:
> I know, this sounds like a newbie question, but unfortunately it seems a
> bit more complex...
>
---snip---
> When I check the nagios.log I get the following errors:
> [1123752497] Finished daemonizing... (New PID=26747)
> [1123752497] Error: Could not connect to MySQL database 'nagios' on host
> 'localhost' using username 'nagios' and password 'removed'. Status data
> will not be saved!
>
> As I said, the provided host, database, username and password are
> correct. I can use them with the mysql-client to connect to the
> database, and use SELECT and INSERT statements succesfully.
>
> It looks like nagios cannot find the database; the MySQL-logging does
> not show any connection attempts from the Nagios-process... Port (3306)
> is used, and telnet localhost 3306 works fine.
Yes, AFAIk there is an issue when you use localhost - the connection will
be made via socket instead of port 3306.
Try your machine's name or IP address (as you find in /etc/hosts) instead
of 'localhost' in the config - same error then?
>
> Who helps me out?
Dunno yet ;-)
>
>
> Thanks in advance and best regards,
> VANDERLET B.V.
>
> R. (Richard) Luys
>
HTH
Werner
--
Werner Flamme, Abt. WKDV
UFZ Umweltforschungszentrum Leipzig-Halle GmbH,
Permoserstr. 15, 04318 Leipzig - http://www.ufz.de
eMail: werner.flamme at ufz.de, Tel.: (0341) 235-2500
-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list