New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[dev.icinga.com #7165] Invalid host address leads to exception w/ PostgreSQL #1008
Comments
Updated by tgelf on 2014-09-10 12:26:45 +00:00
Tried to reproduce this without success. DB type? Something special in your host/service name? Full URL? Thanks, |
Updated by harvey on 2014-09-10 12:58:30 +00:00 Hi, db is postgres 8.4.20 on CentOS 6.5 I have this Problem with ALL services on ALL hosts (ok, I did not check all of the 586 services, but some with the same result :-) The produced URL looks goot to me, something like : icingaweb/monitoring/show/service?host=&service= I have the problem when selecting the service in "problems->service-problems" selecting the service or in a hostview selecting any service. Host- and Servicedefinitions are simply out of the box, eg. apply Service "swap" to Host { check_command = "check_nrpe" The old icinga-web gives full details on Services (select the twisty to see more buttons) -> Details. It looks to me that the "hostname" used in the sql-query does not fit with the type "inet"? cu |
Updated by tgelf on 2014-09-10 13:39:41 +00:00 harvey wrote:
This helped, thank you. Icinga Web 2 uses a virtual host_ipv4 column, it might help to get hosts sorted by IP or filtered by subnet. MySQL gives NULL for invalid IPs, Postgres seems to be stricter. You are using domain names in the "address" field - and therefore the query fails. Best practice are IPs, as the monitoring should not depend on DNS, but your config is perfectly valid. Could you please try if removing the line saying 'host_ipv4' from modules/monitoring/library/Monitoring/Object/Service.php helps? Dropping it should be fine, it is not needed in that place. Cheers, |
Updated by harvey on 2014-09-10 13:47:49 +00:00 Y_E_S that helped! thanks |
Updated by elippmann on 2014-12-12 11:41:12 +00:00
|
Updated by zearan on 2015-02-06 13:12:52 +00:00 Found this issue when searching for my problem. My DynDNS clients change their IPv4 addresses, so I configured their host record. Any chance to have this issue raised? =) |
Updated by elippmann on 2015-03-31 08:53:25 +00:00
|
Updated by elippmann on 2015-03-31 13:20:30 +00:00
|
Updated by aklimov on 2015-05-12 11:06:58 +00:00
|
Updated by aklimov on 2015-05-12 14:40:04 +00:00
Applied in changeset 7353c0d. |
Updated by elippmann on 2015-06-02 07:11:32 +00:00
|
This issue has been migrated from Redmine: https://dev.icinga.com/issues/7165
Created by harvey on 2014-09-10 08:54:47 +00:00
Assignee: aklimov
Status: Resolved (closed on 2015-05-12 14:40:04 +00:00)
Target Version: 2.0.0-rc1
Last Update: 2015-05-12 14:40:04 +00:00 (in Redmine)
clicking on the service of an incident gives sql error starting with:
Server error: SQLSTATE[22P02]: Invalid text representation: 7 ERROR: invalid input syntax for type inet: "####this_is_the_hostname###", query was: SELECT ho.name1 AS host_name, CASE WHEN hs.has .....
The #### text is the hostname of the system, the service incident is on, something like "server1.my.domain"
Changesets
2015-05-12 14:35:14 +00:00 by aklimov 7353c0d
Relations:
The text was updated successfully, but these errors were encountered: