I would like to make an item go away from the home menu under Maps.
The Network Status Map causes web browser to hang, and starts my Nagios host CPU load to rise dramatically.
Then the user kills the browser page that is not responding, and tries again.
After a few attempts, and a dozen orphaned statusmap processes, the Nagios XI CPU load goes from a normal state of about 5 to well over 30, and the system starts to slow down.
So, how can I remove that from my home menu?
Thanks
Steve B
How do I remove an item from the Home menu
-
SteveBeauchemin
- Posts: 524
- Joined: Mon Oct 14, 2013 7:19 pm
How do I remove an item from the Home menu
XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
Re: How do I remove an item from the Home menu
I was not able to remove it, but I could disable it basically. /usr/local/nagiosxi/html/includes/utils-menu.inc.php
Change this:
to this:
It'll just reload the main page basically. I tried removing that section entirely, but that caused the other map links to disappear as well. Not a ton of time to play with this, but it's a start.
You'll need to actually click Home for this to refresh, since our refresh seems to affect the inner frames only. And of course this will be overwritten on an upgrade.
Change this:
Code: Select all
add_menu_item(MENU_HOME, array(
"type" => "link",
"title" => _("Network Status Map"),
"id" => "menu-home-networkstatusmap",
"order" => 401,
"opts" => array(
"href" => get_statusmap_link()
)
));
Code: Select all
add_menu_item(MENU_HOME, array(
"type" => "link",
"title" => _("Network Status Map"),
"id" => "menu-home-networkstatusmap",
"order" => 401,
"opts" => array(
"href" => "includes/page-default-splash.php"
)
));
You'll need to actually click Home for this to refresh, since our refresh seems to affect the inner frames only. And of course this will be overwritten on an upgrade.
Former Nagios employee
-
SteveBeauchemin
- Posts: 524
- Joined: Mon Oct 14, 2013 7:19 pm
Re: How do I remove an item from the Home menu
Trevor,
Thanks for trying. I had the same experience, that all items under Maps vanished if I removed that section of code.
I took a different path while waiting for a forum solution. I changed some other code, modified the case statement and made the command drop through to use the default page. I edited status.php and commented out the case for map. With no match is uses the 'default' at the bottom of the case statement. Still not removed from the menu but much less dangerous for my installation.
cd /usr/local/nagiosxi/html/includes/components/xicore
vi status.php
//case "map":
// show_status_map();
// break;
by inserting // in the code it becomes commented out and that command will drop down to use the default page
As long as it stops folks from trying and failing to get that page open.
I have 8700+ hosts and 37900 services. The map just won't open for a very long time, and will be useless once it does open.
Thanks.
Steve B
Thanks for trying. I had the same experience, that all items under Maps vanished if I removed that section of code.
I took a different path while waiting for a forum solution. I changed some other code, modified the case statement and made the command drop through to use the default page. I edited status.php and commented out the case for map. With no match is uses the 'default' at the bottom of the case statement. Still not removed from the menu but much less dangerous for my installation.
cd /usr/local/nagiosxi/html/includes/components/xicore
vi status.php
//case "map":
// show_status_map();
// break;
by inserting // in the code it becomes commented out and that command will drop down to use the default page
As long as it stops folks from trying and failing to get that page open.
I have 8700+ hosts and 37900 services. The map just won't open for a very long time, and will be useless once it does open.
Thanks.
Steve B
XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
Re: How do I remove an item from the Home menu
Is there anything else we can do for you? It seems like it would be a good thing to feature request, but I have a feeling it wouldn't see much traction, as it's a pretty out of the ordinary scenario.
Former Nagios Employee.
me.
me.
-
SteveBeauchemin
- Posts: 524
- Joined: Mon Oct 14, 2013 7:19 pm
Re: How do I remove an item from the Home menu
Close it I guess. Too bad that function does not work for my installation size.
Thanks
Steve B
Thanks
Steve B
XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
Re: How do I remove an item from the Home menu
I'll link this thread to the developers to see if there are any optimization possibilities. You have a pretty giant environment.
Former Nagios Employee.
me.
me.
Re: How do I remove an item from the Home menu
... Wow.SteveBeauchemin wrote: I have 8700+ hosts and 37900 services.
That's uh... That's a lot. What sort of hardware do you have? Usually around 20k we see systems hit their limit without some tweaking. What optimizations have you performed?
Former Nagios employee