WARNING: Extinfo objects are deprecated and will be removed

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
muammer
Posts: 13
Joined: Tue Jul 07, 2015 7:55 am

WARNING: Extinfo objects are deprecated and will be removed

Post by muammer »

Hi all,
I am trying to add some new images for the hosts and get better view from nagios.
win4.png
win4.png (186.95 KiB) Viewed 6190 times
win3.png
To do this I've created a new cfg file extra_info.cfg like below.

define hostextinfo{
hostgroup_name x1_servers
notes Windows Server
icon_image hgs/hpsrv.png
icon_image_alt Windows Server
vrml_image hgs/hpsrv.gif
statusmap_image hgs/hpsrv.gd2
}
define hostextinfo{
hostgroup_name x2_servers, x3_servers
notes Windows Server
icon_image hgs/win40.png
icon_image_alt Windows Server
vrml_image hgs/win40.gif
statusmap_image hgs/win40.gd2
}

And add this line to nagios.cfg
cfg_file=/usr/local/nagios/etc/objects/extra_info.cfg

System works but I get that type of warnings:

"WARNING: Extinfo objects are deprecated and will be removed in future versions"

What does this warnings mean? How can I get rid of them?

Any help appreciated.
Regards
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: WARNING: Extinfo objects are deprecated and will be remo

Post by jdalrymple »

Here is the current documentation:

https://assets.nagios.com/downloads/nag ... tions.html

Note that all of those definitions:

icon_image
icon_image_alt
statusmap_image
etc

Have been relocated to the host definition. With any version of Core newer than 3.0 you should be able to move those directives to the host definition.
muammer
Posts: 13
Joined: Tue Jul 07, 2015 7:55 am

Re: WARNING: Extinfo objects are deprecated and will be remo

Post by muammer »

Thank you jdalrymple,

So I will edit all hosts again and set each an image. That means I am not able to assign any image to a "hostgroup".
Is there a way to address an image to a hostgroup?

Regards
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: WARNING: Extinfo objects are deprecated and will be remo

Post by jdalrymple »

Can you clarify what you want to do? Are you wanting to assign the image to all of the individual hosts in a hostgroup? If so this would be best performed using an appropriately configured template.

Or are you wanting to assign the image to the hostgroup itself? To the best of my knowledge that was never an option, however I haven't went through the old 2.x and older documents.
muammer
Posts: 13
Joined: Tue Jul 07, 2015 7:55 am

Re: WARNING: Extinfo objects are deprecated and will be remo

Post by muammer »

Hello again,
Yes, I want to assign all servers in a group the same image;
For example if I add image parameters to the template "ibm_windows-server"
define host{
name ibm_windows-server
use generic-host
check_period 24x7
check_interval 5
retry_interval 1
max_check_attempts 10
check_command check-host-alive
notification_period 24x7
notification_interval 30
notification_options d,r
contact_groups admins
hostgroups windows-servers
register 0
icon_image hgs/hpsrv.png
icon_image_alt Windows Server
vrml_image hgs/hpsrv.gif
statusmap_image hgs/hpsrv.gd2

}

and define a host like

define host{
use ibm_windows-server
host_name Nigdeguney_ibm
alias Nigdeguney_ibm
address xxx.xxx.xxx
hostgroups ibm_servers
parents Nigdeguney_gw
}

Is this ok?
Thank you
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: WARNING: Extinfo objects are deprecated and will be remo

Post by jdalrymple »

That should work perfectly, and is the preferred way.
Locked