[Date Prev]   [Date Next] [Thread Prev]   [Thread Next] [Date Index]   [Thread Index]


     Re: [snips-users] snipsweb filter function

> is there some docs on the filter function?? and what should i be using in
> the file pattern section, i have tried *mis* , mis* , mis-* , but to no
> avail, ( the machines are called mis-<hostname> )
> am i also right in assuming that this is also a client-side action and
> doesn't affect the views of other users??

  The documentation on genweb-filter.cgi is lacking for me as 
well.  I turned to the source.  Genweb-filter will really only
do the job of creating a suitable URL for genweb.cgi.  If you can
craft a suitable parameter list by hand, you will have a mechanism
to create a coarse 'view' of SNIPs.  The filepat parameter refers 
to the monitor (nsmon,hostmon, xxmon).  I believe that you need 
the namepat parameter.

Info view:	http://snipshost/genweb-cgi?view=Info
Info view of all BGP sessions
Info view of all hosts named mis-<hostname> or <xxx>-server

I would edit the cgi where a text field is created named 'filepat'
line 110, changing the 'file pattern' to 'monitor name pattern'.  I
also add in the device name selector as well above or below.

  print "<p>device name pattern? \n",
                     ), "\n";

  print "<p>monitor name pattern? \n",
                     ), "\n";

Now for anyone else in the list, I would like to turn this around and
ask my own question.  How does one create a menu that lists a view
that requires multiple selectors.. e.g., select both a monitor and
a device name spec?
my %watchpat = (
        'namepat=otr|qtr|gtr|gigapop' => 'Northern Lights GigaPOP',
        'filepat=nsmon|radiusmon' => 'Nameservice/Authentication',
        'namepat=vpn' => 'VPN Service',
        'namepat=ntc-ww|ATM\.' => 'WireWall Aggregators',
        'filepat=hostmon' => 'Generic Host Monitoring'
my @watchfields = keys %watchpat;

in print_form():
  print "<p>Canned filters \n",
                        -values=> \ at watchfields ,

I expect that I need to modify make_url() but don't know how
to print the selector group properly.  I suspect that a line
that looks like &genpat=&namepat=this|that|theotherthing would
work.  Any suggestions for me?

Tim Peiffer	peiffer at umn edu

Zyrion Traverse Network Monitoring & Network Management Software