How to change icons on statusmap of nagios 2.02b?


#1

well, I’d like to change the default icons (bo:evil: of my hosts on statusmap.
I try to insert every definition in hosts.cfg file but nagios does’t return me what I attend.
Exactly I see my new icon on pupup when I scroll on host in statusmap.
I’d like to see my icons directly in statusmap, how can I solve?
Thank’s


#2

First you must have compiled nagios to use template-based hostext info.
Then edit your hostextinfo.cfg and add something like this.
define hostextinfo {
host_name Bus-tia2665
notes_url x.x.x.x/
icon_image Compaq_Pro_1600p.gif
gd2_image Compaq_Pro_1600p.gd2
2d_coords 50,20
}

the image files go into the folder nagios/images/logos

Or you could use nagiosmap, and it would make alot of this easier for you.


#3

Excuse me, but in manual of nagios I find that from release 2.XX this part is changed…
You don’t create any new hostextinfo.cfg file, but you edit the host.cfg file with same instruction that you write above.
To confirm what I say you can find this :

"
* New location - Extended host info and service info definitions are now stored in object config files along with host definitions, etc. As a result, extended info definitions are now parsed and validated by the Nagios daemon before startup.
* New directives - Extended host info and service info definitions now have two new directives: notes and action_url. "

Infact I edit as I read in documention, and every icons are loaded ecxept on status Map.

So I ask a confirm what understand…
Probably I have a mistake caused from my bad english…


#4

You didn’t state a version so I assumed. Ooops. hehe
ok, from 2.0 docs it states your hostextinfo is defined like this
define hostextinfo{
host_name host_name
notes note_string
notes_url url
action_url url
icon_image image_file
icon_image_alt alt_string
vrml_image image_file
statusmap_image image_file
2d_coords x_coord,y_coord
3d_coords x_coord,y_coord,z_coord
}
So you can put a file named pc.gif in the /usr/local/nagios/share/images/logos
directory and then make icon_image pc.gif and statusmap_image pc.gif


#5

Thanks, but it doesn’t work.
I copy you my row that I edit in hosts.cfg file

define hostextinfo{
host_name SV_sviluppo
notes Questo è il server di implementazione di tutte le prove
icon_image servermod.jpg
vrml_image servermod.jpg
statusmap_image servermod.jpg
}

I refert the same icon for every declaration and I insert it in {…}/logos .
Path is correct because I can see the correct icons for every other windos except for statusmap.
So i have a dubt about this problem.
Have I any mistake or this is a little bug of beta version of nagios?
For the moment I’m not interesting in personal layout of hosts, so I don’t insert any declaration about 2d or 3d coordinates of map.
Thank’s


#6

Give nagiosmap a try and see if it at least fixes the icon problem. You may want to ignore the ugly layout of the hosts for the time being, and just try to setup icons for one host, just to see if it works.


#7

Thank’s, I’m newby, i find nagiosmap.pl version 1.5 but I don’t understand How can I use it:?: :frowning:
First I cannot download it but I save it as a text file that I name nagiosmap.pl and I save it on my pc.
Now I don’t understant where have I insert it and if have I follow any procedure to install it, if I have to change right, owner or somelse.
This is link where I downloaded it from
cvs.orion.education.fr/cgi-bin/v … h_tag=MAIN


#8

ftp it to your nagios box
export the display to your pc
and run the perl script.
Your might need to get some additional perl modules whic you can get from www.cpan.org


#9

Thank’s, i try that pugin, but when I try to install it the the process doesn’t go wrong.
I have Perl compiler module and gd librarries correct.
However, I don’t think to solve my problem with that plugin.
More probably thare is some declaration wrong in my nagios.cfg or cgi.cfg.
Can someone help me to find the exactly row where I have to indicate how to custom my statusmap.
I’m only sure that hosttexinfo is correct.


#10

Hi,
i have the same problem. My Nagios version is 2.0b2. What and how i should configure to see the pics in the statusmap.

Best regards
Michael


#11

I installed nagios2.0beta just to help answer some of these questions quite awhile ago. Of course, I didn’t keep it installed since it had so much wrong with it, I found it not worth the trouble. So now, you guys have found something else wrong, and I’m sorry, but your cfg’s look just fine per the docs, and it might just be that BETA is broke. Why not use 1.2 and save yourself the headache. I know for a fact, that my status map and host views have different icons in each one. So 1.2 works, that much I know. Sorry for the lame suggestion, but I’m pretty much done with 2.0beta junk, since it was nothing but trouble just to get it working, let alone, fine tune it.


#12

Thanks jakkedup.
I installed nagios2.0 beta because my boss suggest it me.
I’m not a linux expert. I use linux from 2 months only, This is my first experience and when I read the “advise for beginner” of nagios, I have to decide if procede or to do anything else.
In this case I follow your suggestion; however nagios is opensoure, it is necessary that someone create new code and someelse tests it.
With my extreme difficults I have the second works.
Thank you


#13

For what it’s worth I’m having no problems on the 2.02b :smiley:
Had some changes while migrating from 1.2 to 2 but mostly lines to be stripped of the hosts definitions :slight_smile:

Luca


#14

If that is the case luca, does your icons work correctly, and if so, why doesnt’ his work?


#15

don’t know, can’t help on this. no GD installed :smiley: (yet)

Luca


#16

I installed 1.2 and it works perfectly, I have gd installed


#17

That is good news. Glad you got it working finally.