[hobbit] Editing thresholds from a web page.

Steve Holmes sholmes42 at gmail.com
Mon Jul 13 18:39:49 CEST 2009


I fixed this with a symlink in my /opt/www2/htdocs directory. Thanks,
Steve.


On Thu, Jul 9, 2009 at 7:25 PM, <david.peters at dpi.nsw.gov.au> wrote:

>
> Okay, the menu problem you are having appears to be because I am sourcing
> the menu that comes installed with hobbit. On my system (which I thought was
> pretty default, the menu.js is in /menu/ relative to DocumentRoot.
>
>
>
>
> ------------------------------------------------------------------------------
> David Peters
>
> +61 2 63913565
> +61 4 17863572
>
> ------------------------------------------------------------------------------
>
>
>
>  From: Steve Holmes <sholmes42 at gmail.com>
> To: hobbit at hswn.dk Date: 10/07/2009 02:46 AM
> Subject: Re: [hobbit] Editing thresholds from a web page.
> ------------------------------
>
>
>
> Nope. Sorry. I got 0.2 and here are the changes I made to
> selection_page.pl. The additions of the two 'next' statements are just
> speedups (I think :-), but the critical change is the way you are testing to
> see if a line is a real host line or not. All of my hosts have an IP of
> 0.0.0.0, and it looks like you are wanting the second character of the line
> to be a digit, but since the second character of my line is a dot ('.') it
> never matches. This works for me wrt getting the hosts loaded, but it still
> doesn't change the config file.
>
> Thanks,
> Steve
>
> --- selection_page.pl   Thu Jul  9 12:28:53 2009
> ***************
> *** 44,49 ****
> --- 44,50 ----
>         while( <BBHOST> ) {
>
>                 chomp;
> +         next if (/^\s*\#/ );
>
>                 ($leading, $data) = split( ' ' , $_ );
>
> ***************
> *** 59,68 ****
>         foreach( @files ) {
>                 open(FILE, $_);
>                 while( <FILE> ) {
>                         ($leading, $data) = split( ' ' , $_ );
>
>
> !                       if( substr( $leading, 1,1 ) ge 0 && substr(
> $leading, 1, 1 ) le 9 ) {
>                                 $hosts{$data}{hostname} = $data;
>                         }
>                 }
> --- 60,72 ----
>         foreach( @files ) {
>                 open(FILE, $_);
>                 while( <FILE> ) {
> +                 next if ( /^\s*\#/ );
>                         ($leading, $data) = split( ' ' , $_ );
>
>
> ! #                     if( substr( $leading, 1,1 ) ge 0 && substr(
> $leading, 1, 1 ) le 9 ) {
> !                       ($byte1,$byte2,$byte3,$byte4) =
> split('\.',$leading);
> !                       if ($byte1 ge 0 && $byte1 le 255) {
>                                 $hosts{$data}{hostname} = $data;
>                         }
>                 }
>
>
> On Thu, Jul 9, 2009 at 3:43 AM, David Peters <*davidp at electronf.com*<davidp at electronf.com>>
> wrote:
> Version 0.2 is now available for download. It fixes an issue relating to
> hosts not loading. Hopefully that was the one you saw Steve.
>
>
>
> It also fixes a couple of other minor things including removing a hardcoded
> directory in one of the html header files.
>
>
>
>
>
> ------------------------------
>
> *From:* Steve Holmes [mailto:*sholmes42 at gmail.com* <sholmes42 at gmail.com>]
> *Sent:* Thursday, 9 July 2009 6:13 AM
>
> *To:* *hobbit at hswn.dk* <hobbit at hswn.dk>*
> Subject:* Re: [hobbit] Editing thresholds from a web page.
>
>
>
> Hi David,
>
>
>
> Ok, so I downloaded the scripts from sourceforge. I couldn't find them on
> xymonton. What I have might not be your latest. So, the fixes I had to make
> might be unneeded on a later version, but:
>
>
>
> The first thing was that the first edit-thresholds page had no hosts
> loaded. I fixed that. The next problem is that it isn't actually making the
> changes I've entered. An error from the web server (which might not have
> anything to do with this behavior) is:
>
>
>
> File does not exist: /opt/www2/htdocs/menu, referer: *
> https://my-server/hobbit-seccgi/edit-thresholds/trunk/edit-threshold.pl*<https://my-server/hobbit-seccgi/edit-thresholds/trunk/edit-threshold.pl>
>
>
>
> It's true that my apache home
> dir is /opt/www2 and the htdocs dir is htdocs, but where is it getting the path to menu there, which doesn't exist. I've searched through everything I can think of. I've obviously overlooked something.
>
>
>
> If I fix this error and it still doesn't make the changes I'll look
> further.
>
>
>
> Any ideas? I'm excited to get this working. It should save me a significant
> amount of time if my co-admins could make these changes without asking me to
> edit the files!
>
>
>
> Thanks,
>
> Steve
>
>
>
> On Wed, Jul 8, 2009 at 4:54 AM, David Peters <*davidp at electronf.com*<davidp at electronf.com>>
> wrote:
>
> Yes I think that might be a good idea. Just beware of the two bugs that
> currently exist.
>
>
>
> -----Original Message-----
> From: Martin Flemming [mailto:*martin.flemming at desy.de*<martin.flemming at desy.de>
> ]
> Sent: Wednesday, 8 July 2009 4:05 PM
> To: *hobbit at hswn.dk* <hobbit at hswn.dk>
>
> Subject: Re: [hobbit] Editing thresholds from a web page.
>
>
> Hi, David !
>
> thanks, for the scripts !
>
> I recognize, that the scripts didn't make a backup of hobbit-clients.cfg
> ...
>
> Maybe, we could added a backupfunction with timestamp  ?
>
> thanks & cheeers
>
>        martin
>
> On Tue, 7 Jul 2009, Steve Holmes wrote:
>
> > The link seems to work now. From the OP:
> >
> >> Anyway, I have put it up on sourceforge: *http://xymon-addons.svn*<http://xymon-addons.svn/>
> .
> >> *sourceforge.net/viewvc/xymon-addons/edit-thresholds/*<http://sourceforge.net/viewvc/xymon-addons/edit-thresholds/>
> >
> > Download the tarball from the bottom of the page.
> >
> >
> > Steve.
> >
> > On Tue, Jul 7, 2009 at 6:28 AM, Shaun Phillips <
> > *tainted.soul69 at googlemail.com* <tainted.soul69 at googlemail.com>> wrote:
> >
> >> Where can I get  edit-thresholds.tar ?
> >>
> >>
> >> On Tue, Jul 7, 2009 at 8:51 AM, Cayo de Moraes
> <*camorae at googlemail.com* <camorae at googlemail.com>>wrote:
> >>
> >>> Hi David,
> >>>
> >>> infortunately i couldnt download it...
> >>> The "edit-thresholds.tar" file could not be found. Please select
> another
> >>> file
>
>
>
>
> --
> Do you wish to rise? Begin by descending. You plan a tower that will pierce
> the clouds? Lay first the foundation of humility. -St. Augustine (354-430)
>
> Truth never damages a cause that is just. -Mohandas Karamchand Gandhi
> (1869-1948)
>
>
>
>
>
>
> This message is intended for the addressee named and may contain confidential information. If you are not the intended recipient, please delete it and notify the sender. Views expressed in this message are those of the individual sender, and are not necessarily the views of their organisation.
>
>


-- 
Do you wish to rise? Begin by descending. You plan a tower that will pierce
the clouds? Lay first the foundation of humility. -St. Augustine (354-430)

Truth never damages a cause that is just. -Mohandas Karamchand Gandhi
(1869-1948)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20090713/57d849c9/attachment.html>


More information about the Xymon mailing list