I was finally able to spend some time and isolate this problem.
The problem is in grapher.cgi. At line 185, the scripts attempts to do
'inst' to 'inst-names' mapping. My problem is, that I don't have
"inst-names" tags in my target dictionary, and when grapher.cgi attempted to
get the "inst-names" values and assign them to $ins, it received an
undefined variable. (Which is correct.) The problem is that the variable
$ins is then handed to the function "expandStrings()" which will choke on
undefined variables.
The workaround I implemented, is redefine $ins to a null length string, if
it is undefined.
$ diff -c grapher.cgi.sav grapher.cgi
*** grapher.cgi.sav Sun Aug 22 02:03:10 1999
--- grapher.cgi Sun Aug 22 02:07:40 1999
***************
*** 181,186 ****
--- 181,187 ----
print "<center><table width=80%>";
my($ins) = $targRef->{'inst-names'};
+ $ins = "" unless defined $ins;
$ins = ConfigTree::Cache::expandString($ins,
$targRef);
my($instNameMap) = makeInstMap($ins, $inst);
$
Matthew Stier wrote:
> From: Matthew Stier <Matthew.Stier@tddny.fujitsu.com>
>
> I've updated my installation of Cricket to version 0.70, and RRDTool to
> version 1.0.6.
>
> I am trying to use the "inst = (1..4)" to monitor a range of etherswitch
> interfaces. The Cricket collector has no problems with this syntax, but
> the grapher.cgi fails.
>
> The config and log files are:
>
> cricket-config/switch-interfaces:
> target c5k-cr
> short-desc = "Cisco Catalyst 5000 in computer room"
> inst = (1..4)
>
> cricket-logs/switches.0
> [16-Aug-1999 17:25:07 ] Retrieved data for c5k-cr (1): 2960536368,0
> [16-Aug-1999 17:25:07 ] Retrieved data for c5k-cr (2): 0,0
> [16-Aug-1999 17:25:07 ] Retrieved data for c5k-cr (3):
> 4044936577,4189170045
> [16-Aug-1999 17:25:07 ] Retrieved data for c5k-cr (4):
> 3575559438,43343089
>
> The webserver log file entry is:
>
> [16/Aug/1999:15:49:27] failure ( 273): for host 167.254.240.152 trying
> to GET /~cricket/cricket/grapher.cgi, cgieng_scan_headers reports: the
> CGI program /d0/cricket/public_html/cricket/grapher.cgi did not produce
> a valid header (name without value: got line "use of uninitialized value
> at /d0/cricket/public_html/cricket/./lib/configtree/cache.pm line 222.")
>
> Notes:
> The Cricket server is a Ultra-2 server (clone) running Solaris 2.6.
> The webserver is Netscape Enterprise Server 3.61.
> The version of Perl is 5.005_03
>
> --
> Matthew Lee Stier * Fujitsu Network Communications
> Unix Systems Administrator | Two Blue Hill Plaza
> Ph: 914-731-2097 Fx: 914-731-2011 | Sixth Floor
> Matthew.Stier@fnc.fujitsu.com * Pearl River, NY 10965
>
> --------------------------- ONElist Sponsor ----------------------------
>
> ONElist: home to the world's liveliest email communities.
>
> ------------------------------------------------------------------------
-- Matthew Lee Stier * Fujitsu Network Communications Unix Systems Administrator | Two Blue Hill Plaza Ph: 914-731-2097 Fx: 914-731-2011 | Sixth Floor Matthew.Stier@fnc.fujitsu.com * Pearl River, NY 10965
This archive was generated by hypermail 2b29 : Mon Mar 06 2000 - 19:01:00 PST