Refreshing VRML Map

Justin Seitz jseitz at crossflux.com
Thu Jan 26 20:16:26 CET 2006


Hi All,

Not sure if anyone has posted anything like this, but I had seen a
request awhile back about getting the VRML map to refresh or to do
"realtime". Because of state problems, of course, realtime is not
possible, but I have changed the .c file that generates the map to
refresh the map once a minute, which is very handy as you can have your
map open and see if any hosts go down rather easily.

Go into your uncompiled nagios directory and enter the /cgi/ directory,
and edit statuswrl.c

Page down through the code until you see a line like this:

printf("Expires %s\n",date_time);

Directly underneath that line enter the following or copy / paste it:

printf("Refresh: 60\n");

Save the file, and go back into your main nagios directory. Do your
./configure (with whatever options you normally would), do a "make all"
when it's finished but DO NOT do a "make install" or it will completely
overwrite your current installation.

Backup your orignal statuswrl.cgi just in case :)

cp /usr/local/nagios/sbin/statuswrl.cgi /home/

Put the new compiled version in place:

cp /yourcurrentnagiosdirectory/cgi/statuswrl.cgi /usr/local/nagios/sbin

Now load up your web interface and watch the map, every minute you
should see it "flash" and it updates itself! :) If you have any
questions email me. You can change the time of refresh to shorter or
longer depending on how you like it, but a very low number will cause
the map to flash annoyingly.

JS



-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list