Unconfigured objects nesting problem (2012R1.0)

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
nagiosadmin42
Posts: 96
Joined: Sat Feb 11, 2012 2:16 pm

Unconfigured objects nesting problem (2012R1.0)

Post by nagiosadmin42 »

CentOS 6.3, Nagios XI 2012R1.0

The Unconfigured Objects table is sometimes messed up, I tracked it down to the "rowspan" logic in missingobjects.php that uses the incorrect number of services value due to hidden services. I simply replicated the logic that's in the service loop, and used it to re-calculate the $total_services value that's used for the rowspan. See lines 286 to 292:

Code: Select all

/usr/local/nagiosxi/html/admin/missingobjects.php;

    281                 $displayed++;
    282
    283                 if($current_host>0)
    284                         echo "<tr><td colspan='5'></td></tr>";
    285
    286                 // xxx recalculate the $total_services using the same logic as in the loop below
    287                 $total_services = 0;
    288                 foreach($svcs as $sn => $sarr){
    289                         if(service_exists($hn,$sn)==true || in_array($sn,$hidden))
    290                                 continue;
    291                         $total_services++;
    292                 }
    293
    294                 echo "<tr>";
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Unconfigured objects nesting problem (2012R1.0)

Post by scottwilkerson »

Thanks. I made a slightly different modification to the Trunk of XI that should have the same affect.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked