Closed leo29041982 closed 7 years ago
Hello,
Sorry, I can't reproduce your issue. Can you check the result of the query in the database ?
Thanks in advance
i've added some Hosts. but it is always the last entry which is displayed.
left click...
gets...
SELECT CONCAT (h.name, " - ", s.description) as fullname FROM hosts h, services s WHERE h.host_id = s.host_id AND s.enabled = "1" AND s.service_id = 6
Result: fullname DEM_RZ_KAM_RZVB-BZ1 - NTP-Time DEM_RZ_KAM_RZVB-BZ2 - NTP-Time DEM_RZ_KAM_RZVB-RZA-BF1 - NTP-Time DEM_RZ_KAM_RZVB-RZA-BF2 - NTP-Time DEM_RZ_KAM_RZVB-RZA-BF3 - NTP-Time DEM_RZ_KAM_RZVB-RZA-CA1 - NTP-Time DEM_RZ_KAM_RZVB-RZA-CA2 - NTP-Time DEM_RZ_KAM_RZVB-RZA-D1 - NTP-Time DEM_RZ_KAM_RZVB-RZA-D2 - NTP-Time DEM_RZ_KAM_RZVB-RZA-K1 - NTP-Time DEM_RZ_KAM_RZVB-RZA-K2 - NTP-Time DEM_RZ_KAM_RZVB-RZA-K3 - NTP-Time DEM_RZ_KAM_RZVB-RZA-S1 - NTP-Time DEM_RZ_KAM_RZVB-RZA-TF1 Eingang - NTP-Time DEM_RZ_KAM_RZVB-RZA-TF2 - NTP-Time DEM_RZ_KAM_RZVB-RZA-TF3 - NTP-Time DEM_RZ_KAM_RZVB-RZA-W1 - NTP-Time DEM_RZ_KAM_RZVB-RZA-W2 - NTP-Time DEM_RZ_KAM_RZVB-RZB-BF1 - NTP-Time DEM_RZ_KAM_RZVB-RZB-CB1 - NTP-Time DEM_RZ_KAM_RZVB-RZB-CB2 - NTP-Time DEM_RZ_KAM_RZVB-RZB-D1 - NTP-Time DEM_RZ_KAM_RZVB-RZB-D2 - NTP-Time DEM_RZ_KAM_RZVB-RZB-K1 - NTP-Time DEM_RZ_KAM_RZVB-RZB-K2 - NTP-Time DEM_RZ_KAM_RZVB-RZB-K3 - NTP-Time DEM_RZ_KAM_RZVB-RZB-K4 - NTP-Time DEM_RZ_KAM_RZVB-RZB-TF1 - NTP-Time DEM_RZ_KAM_RZVB-RZB-TF2 - NTP-Time DEM_RZ_KAM_RZVB-RZB-W1 - NTP-Time DEM_RZ_KAM_RZVB-RZB-W2 - NTP-Time DEM_RZ_KAM_RZVB-RZB-W3 - NTP-Time WNS_KAM_Tank_CAM01 - NTP-Time WNS_KAM_Tank_CAM02 - NTP-Time WNS_KAM_Tank_CAM03 - NTP-Time WNS_KAM_Tank_CAM04 - NTP-Time WNS_KAM_Tank_CAM05 - NTP-Time WNS_KAM_Tank_CAM06 - NTP-Time WNS_KAM_Tank_CAM07 - NTP-Time WNS_KAM_Tank_CAM08 - NTP-Time
This may solve the problem, same cause as #4955 , no Hostid checked.
File: www\include\views\graphs\graphs.php
} else if (preg_match('/^(.+);(.+)/', $svc, $matches)) {
list($hostname, $serviceDescription) = explode(";", $svc);
$hostId = getMyHostID($hostname);
$serviceId = getMyServiceID($serviceDescription, $hostId);
$graphId = $hostId . '-' . $serviceId;
//old: $graphTitle = $serviceObj->getMonitoringFullName($serviceId);
$graphTitle = $serviceObj->getMonitoringFullName($serviceId, #$hostId);
File: www\class\centreonService.class.php
Your service is linked to multiple hosts ? right ?
yes.
Hello,
Can you test the fix ?
Thanks
it worked on my installation.
Fix is working also on my servers. Thanks a lot and sorry for the duplicate issue.
BUG REPORT INFORMATION
Centreon Web version: 2.8.4
Steps to reproduce the issue:
Describe the results you received: Last Hostname from "SELECT CONCAT (h.name, " - ", s.description) as fullname FROM hosts h, services s WHERE h.host_id = s.host_id AND s.enabled = "1" AND s.service_id = 6" -> DEM_RZ_KAM_SW-RZ-KAM - NTP-Time
Describe the results you expected: Hostname from URL "main.php?p=204&mode=0&svc_id=DEM_RZ_KAM_RZVB-BZ1;NTP-Time"
Additional information you think important (e.g. issue happens only occasionally): Failure in www/include/views/graphs/graphs.php or www/class/centreonService.class.php