Skip to content
This repository has been archived by the owner on Jan 15, 2019. It is now read-only.

[dev.icinga.com #3686] Host Overview - Empty contacts & contactgroups #42

Closed
icinga-migration opened this issue Feb 11, 2013 · 7 comments
Milestone

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/3686

Created by tkoeberl on 2013-02-11 08:48:58 +00:00

Assignee: mfriedrich
Status: Resolved (closed on 2013-03-03 18:55:14 +00:00)
Target Version: 1.8.2
Last Update: 2013-03-03 18:55:14 +00:00 (in Redmine)

Icinga Version: 1.8.3
DB Type: MySQL
DB Version: mysql  Ver 14.14 
Jasper Version: 5.0.0

In the Host Overview Report, the sub dataset with the contactgroups is empty.

Attachments

Changesets

2013-03-03 18:51:02 +00:00 by (unknown) cac85a7

fix empty contacts and contactgroups in host overview

fixes #3686

2013-03-03 19:40:57 +00:00 by (unknown) 51d35ae

fix empty contacts and contactgroups in host overview

fixes #3686
@icinga-migration
Copy link
Author

Updated by tkoeberl on 2013-02-11 08:53:26 +00:00

  • File added config_report.png

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-02-12 19:49:09 +00:00

  • Target Version set to 1.8.2

for discussion and a possible fix, check http://www.monitoring-portal.org/wbb/index.php?page=Thread&postID=184032#post184032

patches as usual welcome!

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-03-03 17:29:58 +00:00

from the discussion, grepped for the string outputs on the report.

jasperreports/templates/sub/host/contactgroups.jrxml

will test my fix now.

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-03-03 17:53:59 +00:00

same goes for contacts.jrxml where the join is missing as well. host_id != host_object_id

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-03-03 18:39:50 +00:00

  • Status changed from New to Assigned
  • Assigned to set to mfriedrich

ok, the contacts query is a bit more broken too. the join of icinga_contacts with icinga_hosts_contacts must be done on the contact_object_id in both cases. the contact_id itsself is just an incremented primary key of the icinga_contacts table, and useless on joins when select objects (select from where is an implicit join).

this query is correct and works in my tests.

select a.name1,
  b.alias,
  b.email_address
from icinga_objects a,
  icinga_contacts b,
  icinga_host_contacts c,
  icinga_hosts d
where a.object_id = b.contact_object_id
and b.contact_object_id  = c.contact_object_id
and c.host_id     = d.host_id
and d.host_object_id = 263;

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-03-03 18:45:57 +00:00

  • File added icinga_reporting_1.8_host_contactgroups_fixed.png
  • File added icinga_reporting_1.8_host_contacts_fixed.png

i'm using this config to the contact - https://git.icinga.org/?p=icinga-core.git;a=blob;f=tests/etc/1502.cfg;hb=HEAD
and this one for the contactgroup - https://git.icinga.org/?p=icinga-core.git;a=blob;f=tests/etc/1066.cfg;hb=HEAD

the generic contacts are to be found here - https://git.icinga.org/?p=icinga-core.git;a=blob;f=tests/etc/contacts.cfg;hb=HEAD

fixed host contactgroup

icinga_reporting_1.8_host_contactgroups_fixed.png

fixed host contact

icinga_reporting_1.8_host_contacts_fixed.png

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-03-03 18:55:14 +00:00

  • Status changed from Assigned to Resolved
  • Done % changed from 0 to 100

works for me.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant