Hi! 

I've been installing bcnu (in /usr/local/lib/bcnu), and I have a few 
patches for you! 

1. There were a couple of references to /usr/local/bcnu left over. 
2. I started from source, and the 'make install' didn't work. 
3. After acknowledging all the alerts, the 'unacknowledged alerts' 
thing didn't go away (Changed file test from -f to -s) 
4. I put in a javascript clock to a) indicate how long it's been since 
a reload, and to b) reload the screen if the 'meta refresh' fails to 
work, which it does often. 
5. Took out a slash that was making it look up .../data//files/... 
6. Put in a chmod 644 so that the static pages were readable even with 
a umask of 022. (bcnud runs as adm, webserver runs as nobody) 
7. If you've only got one host, the summary table looked bad. 
(colspan=$PERLINE was larger than number of cells) 
8. There was no key anywhere but the source... see attached key.cgi 

Sorry if the patches are all jumbled together, I wasn't going to 
bother at all, but then thought you'd be interested. 

Thanks for a good program! Keep up the good work! 
-- 
Charles Howes -- chowes@micro-logistics.com 
"The percentage of users running Windows NT Workstation 4.0 whose PCs 
stopped working more than once a month was less than half that of Windows 
95 users."-- microsoft.com/ntworkstation/overview/Reliability/Highest.asp 





diff -ru src/Setup /usr/local/lib/bcnu/Setup
--- src/Setup	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/Setup	Thu Mar  9 10:26:28 2000
@@ -72,7 +72,7 @@
 fi
 
 # setup perl 
-PERLBIN="/usr/local/bin/perl"
+PERLBIN="/usr/bin/perl"
 
 if [ ! -x $PERLBIN ]
 	then
diff -ru src/agent/av /usr/local/lib/bcnu/agent/av
--- src/agent/av	Wed Mar  8 06:59:22 2000
+++ /usr/local/lib/bcnu/agent/av	Fri Mar 10 13:33:58 2000
@@ -12,11 +12,13 @@
 echo "--------" >>$BCNUTMP/bcnu.out
 if [ -f $BCNUHOME/etc/systeminfo ]
 	then
+		echo "${MYNAME}:$BCNUHOME/etc/systeminfo :" >>$BCNUTMP/bcnu.out
 		cat $BCNUHOME/etc/systeminfo >>$BCNUTMP/bcnu.out
 		echo "--------" >>$BCNUTMP/bcnu.out
 fi
 $BCNU -a show $MYNAME >>$BCNUTMP/bcnu.out
 echo "--------" >>$BCNUTMP/bcnu.out
+echo "${MYNAME}:$BCNUHOME/etc/agents :" >>$BCNUTMP/bcnu.out
 $BCNU -a get -f /etc/agents $MYNAME >>$BCNUTMP/bcnu.out
 
 }
diff -ru src/cgi-bin/bcnu.cgi /usr/local/lib/bcnu/cgi-bin/bcnu.cgi
--- src/cgi-bin/bcnu.cgi	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/cgi-bin/bcnu.cgi	Fri Mar 10 15:08:12 2000
@@ -78,7 +78,7 @@
 	$agdisp = '</TABLE><P><TABLE border=1>';
 	$agdisp .= "<TR><TH bgcolor=#bbaacc colspan=6 align=center>Recent Error History - $acks alerts unacknowledged</TH></TR>";
 	$agdisp .= "<FORM ACTION=\"$ENV{SCRIPT_NAME}\" METHOD=\"POST\" NAME=\"mainForm\">";
-	$agdisp .= "<TR><TH $DEFCELL>System<TH $DEFCELL>Status<TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message<TH $DEFCELL>Comment/Clear history</TR>\n";
+	$agdisp .= "<TR><TH $DEFCELL>System<TH $DEFCELL><A HREF=\"key.cgi\">Status</A><TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message<TH $DEFCELL>Comment/Clear history</TR>\n";
 
 	$agdisp .= $ackdisp;
 
@@ -108,6 +108,7 @@
 # produce default home page
 #
 
+if (scalar(keys %cell) < $PERLINE) { $PERLINE=scalar(keys %cell);}
 print &printhdr;
 if ($in{"status"}) {
 	print &header("Status only",$errlevel,5);
diff -ru src/cgi-bin/bcnu.inc /usr/local/lib/bcnu/cgi-bin/bcnu.inc
--- src/cgi-bin/bcnu.inc	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/cgi-bin/bcnu.inc	Thu Mar  9 16:01:22 2000
@@ -9,11 +9,11 @@
 
 require "dotsh.pl";
 
-dotsh("/usr/local/bcnu/etc/bcnuenv");
+dotsh("/usr/local/lib/bcnu/etc/bcnuenv");
 
 if ( $BCNUSERVER eq "linux" ) {	# linux doesn't seem to work correctly with bash
 	$ENV{'SHELL'}="/bin/sh";
-	dotsh("/usr/local/bcnu/etc/bcnulocal");
+	dotsh("/usr/local/lib/bcnu/etc/bcnulocal");
 }
 
 
diff -ru src/cgi-bin/bcnulib.pl /usr/local/lib/bcnu/cgi-bin/bcnulib.pl
--- src/cgi-bin/bcnulib.pl	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/cgi-bin/bcnulib.pl	Fri Mar 10 16:45:57 2000
@@ -34,8 +34,35 @@
 
 $hd1 = <<"Endofhd";
 <HTML><HEAD><TITLE>BCNU($BCNUHOST) monitor @ $now</TITLE>
-<META HTTP-EQUIV=REFRESH CONTENT=$refresh></HEAD>
-<BODY BGCOLOR=$DEFBG>
+<META HTTP-EQUIV=REFRESH CONTENT=$refresh>
+<script Language="JavaScript">
+//<!-- Hide me from other browsers
+var timerID = null;
+var timerRunning = false;
+var starttime= new Date();
+function stopclock (){
+   if(timerRunning)
+           clearTimeout(timerID);
+   timerRunning = false;
+}
+function startclock () {
+   // Make sure the clock is stopped
+   stopclock();
+   showtime();
+}
+function showtime () {
+   var now = new Date();
+   var diff = Math.floor((now-starttime)/1000);
+   document.clock.face.value = diff;
+// backup for meta tag reload, which sometimes doesn't work:
+   if ( diff > $refresh ) { window.location.reload(); }
+   timerID = setTimeout("showtime()",1000);
+   timerRunning = true;
+}
+// -->
+</SCRIPT>
+</HEAD>
+<BODY BGCOLOR=$DEFBG onLoad="startclock()">
 $SOUND<CENTER>
 <TABLE border=0><TR>
 <TD valign=top>
@@ -63,12 +90,13 @@
 
 Endofhd
 
-if ( ! $BCNUSTATIC && -r "$BCNUHOME/flags/bcnud.ack") {
+if ( ! $BCNUSTATIC && -s "$BCNUHOME/flags/bcnud.ack") {
 	$hd2 .= "<TR><TD><TH ALIGN=CENTER BGCOLOR=$RED>There are unacknowledged alerts</TD></TR>";
 }
 
 $hd3 = <<"Endofhd";
-<TR><TD><TD ALIGN=CENTER><B>Last update $now</TD><TD></TD>
+<TR><TD></TD><TD ALIGN=CENTER><B><form name="clock">Last update $now, <input type="text" name="face" size=4 value=""> seconds ago</form>
+</TD>
 </TABLE><P>$navigate
 <CENTER>
 <TABLE BORDER=1>
@@ -267,7 +295,7 @@
 
 local ($host) =@_;
 
-	$agdisp = "<TR><TH $DEFCELL>System<TH $DEFCELL>Status<TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message</TR>\n";
+	$agdisp = "<TR><TH $DEFCELL>System<TH $DEFCELL><A HREF=\"key.cgi\">Status</A><TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message</TR>\n";
 
         foreach $agent (@agents) {
 
@@ -296,7 +324,7 @@
 	        close (BFILE);
 	        }
 	else {
-	        @incfile="Unable to open $bfilename";
+	        @incfile="Unable to open $bfilename: $!";
 	}
 	$agdisp .= "<TR><TD $BGCELL COLSPAN=7 >Contents of $bfilename\n";
 	$agdisp .= "<TR><TD COLSPAN=7 $ECELL><PRE>@incfile</pre></td></TR></TABLE>\n";
@@ -508,29 +536,29 @@
 
 if ( $type == 9 ) {
 	$IMG="$SAD ALT=\"Last error: $lasterr{\"$host-$type\"}\" >";
-	$cell{$host} .= "<TD $CELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $CELL ALIGN=CENTER>$ANCHOR $IMG";
 	}
 elsif ($type == 5 || $type == 6) {
 	$IMG="$WORRY ALT=\"Last warning: $lasterr{\"$host-$type\"}\" >";
-	$cell{$host} .= "<TD $CELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $CELL ALIGN=CENTER>$ANCHOR $IMG";
 	}
 elsif ($type == 1) {		# blackouts
 	$IMG="$NORMAL ALT=\"Blackout\" >";
-	$cell{$host} .= "<TD $BLACKCELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $BLACKCELL ALIGN=CENTER>$ANCHOR $IMG";
 	$DARK=1
 	}
 elsif ($type == 2) {		# Ignore
 	$IMG="$IMGIGNORE ALT=\"$lasterr{\"$host-$type\"}\" >";
-	$cell{$host} .= "<TD $IGNORECELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $IGNORECELL ALIGN=CENTER>$ANCHOR $IMG";
 	$DARK=1;
 	}
 elsif ($type == 3) {		# No report recently
 	$IMG="$NORMAL ALT=\"No report recently\" >";
-	$cell{$host} .= "<TD $WARNCELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $WARNCELL ALIGN=CENTER>$ANCHOR $IMG";
 	}
 else    {
 	$IMG="$NORMAL ALT=\"OK\" >";
-	$cell{$host} .= "<TD $CELL WIDTH=70>$ANCHOR$IMG";
+	$cell{$host} .= "<TD $CELL ALIGN=CENTER>$ANCHOR$IMG";
 	}
 if ($DARK) {
 	$cell{$host} .= "<BR><TABLE BGCOLOR=#FFFFFF><TD>$host</TABLE></a></TD>";
diff -ru src/cgi-bin/bcnuweb /usr/local/lib/bcnu/cgi-bin/bcnuweb
--- src/cgi-bin/bcnuweb	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/cgi-bin/bcnuweb	Fri Mar 10 13:03:19 2000
@@ -11,7 +11,7 @@
 require "getopts.pl";
 
 push (@INC,"$ENV{'BCNUHOME'}/cgi-bin");
-push (@INC,"/usr/local/bcnu/cgi-bin");
+push (@INC,"/usr/local/lib/bcnu/cgi-bin");
 
 require "bcnu.inc";
 require "bcnulib.pl";
@@ -140,6 +140,7 @@
         &agenthost ($host);
 
 	open (WEB,">$WWW/hosts/$host.htm") || die "can't write web page $WWW/hosts/$host.htm";
+	chmod 0644,"$WWW/hosts/$host.htm";
 
         print WEB &header("$host - Agent Summary",$errlevel,2);
         print WEB $agdisp;
diff -ru src/cgi-bin/buildanon /usr/local/lib/bcnu/cgi-bin/buildanon
--- src/cgi-bin/buildanon	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/cgi-bin/buildanon	Thu Mar  9 16:02:14 2000
@@ -19,7 +19,7 @@
 		);
 
 push (@INC,"$ENV{'BCNUHOME'}/cgi-bin");
-push (@INC,"/usr/local/bcnu/cgi-bin");
+push (@INC,"/usr/local/lib/bcnu/cgi-bin");
 
 require "bcnu.inc";
 require "bcnulib.pl";
diff -ru src/docs/help.html /usr/local/lib/bcnu/docs/help.html
--- src/docs/help.html	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/docs/help.html	Fri Mar 10 11:44:40 2000
@@ -411,3 +411,6 @@
 </FONT><FONT FACE="Terminal"><P>
 </FONT>
 
+</TABLE>
+</BODY>
+</HTML>
diff -ru src/etc/agents.distrib /usr/local/lib/bcnu/etc/agents.distrib
--- src/etc/agents.distrib	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/etc/agents.distrib	Thu Mar  9 10:37:32 2000
@@ -1,11 +1,11 @@
 ##
-## Sample agent config file - Solaris
+## Sample agent config file - linux
 ##
 ## standard monitoring agents
 ##
 agent:procs:8-18:10:12:enabled:inetd syslogd:
-agent:fs:8-18:15:8:enabled:/tmp=90=95 /=90=95 /usr=90=95:
-agent:logs:8-18:15:8:enabled:/var/adm/messages /var/adm/sulog:
+agent:fs:8-18:15:8:enabled:/=90=95:
+agent:logs:8-18:15:8:enabled:/var/log/messages /var/log/secure:
 agent:uptime:8-18:15:8:enabled:1=5=8:
 agent:vmstat:8-18:15:8:enabled:PROCSWAP=0:
 ##
@@ -21,8 +21,8 @@
 ##
 ## agents below ONLY required on master
 ##
-#agent:alert:8-18:5:0:enabled:MAIL:
-#agent:buildweb:8-18:60:0:enabled::
+agent:alert:8-18:5:0:enabled:MAIL ACK:
+agent:buildweb:8-18:60:0:enabled::
 ##
 ## Solaris, hpux, aix only for now - checks SDS and LVM integrity
 ##
diff -ru src/etc/bcnuenv.distrib /usr/local/lib/bcnu/etc/bcnuenv.distrib
--- src/etc/bcnuenv.distrib	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/etc/bcnuenv.distrib	Thu Mar  9 10:37:32 2000
@@ -6,7 +6,7 @@
 
 # host name of controlling server - where logging is done
 # and updates are allowed from
-BCNUHOST=dns1
+BCNUHOST=eddie.ics.bc.ca
 
 # home directory will be set if not already set
 BCNUHOME=${BCNUHOME:="/usr/local/bcnu"}
diff -ru src/etc/hostinfo.distrib /usr/local/lib/bcnu/etc/hostinfo.distrib
--- src/etc/hostinfo.distrib	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/etc/hostinfo.distrib	Thu Mar  9 10:37:32 2000
@@ -5,8 +5,8 @@
 # or agent are specified
 
 [default]
-DEFEMAIL="$techmail" 
-DEFPAGER="$techpage"
+DEFEMAIL="root@eddie.ics.bc.ca" 
+DEFPAGER="none"
 DEFMALERT="20"					# max mail alerts per host per day
 PAGEDAYS="Mon Tue Wed Thu Fri"
 MAILDAYS="Mon Tue Wed Thu Fri"
diff -ru src/scripts/buildweb /usr/local/lib/bcnu/scripts/buildweb
--- src/scripts/buildweb	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/scripts/buildweb	Fri Mar 10 13:03:19 2000
@@ -11,7 +11,7 @@
 require "getopts.pl";
 
 push (@INC,"$ENV{'BCNUHOME'}/cgi-bin");
-push (@INC,"/usr/local/bcnu/cgi-bin");
+push (@INC,"/usr/local/lib/bcnu/cgi-bin");
 
 require "bcnu.inc";
 require "bcnulib.pl";
@@ -140,6 +140,7 @@
         &agenthost ($host);
 
 	open (WEB,">$WWW/hosts/$host.htm") || die "can't write web page $WWW/hosts/$host.htm";
+	chmod 0644,"$WWW/hosts/$host.htm";
 
         print WEB &header("$host - Agent Summary",$errlevel,2);
         print WEB $agdisp;
diff -ru src/scripts/master_setup /usr/local/lib/bcnu/scripts/master_setup
--- src/scripts/master_setup	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/scripts/master_setup	Thu Mar  9 10:26:28 2000
@@ -72,7 +72,7 @@
 fi
 
 # setup perl 
-PERLBIN="/usr/local/bin/perl"
+PERLBIN="/usr/bin/perl"
 
 if [ ! -x $PERLBIN ]
 	then
diff -ru src/src/Makefile /usr/local/lib/bcnu/src/Makefile
--- src/src/Makefile	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/src/Makefile	Thu Mar  9 10:36:39 2000
@@ -7,11 +7,11 @@
 #LIBS	= -L/usr/local/mysql/lib -lmysqlclient -lsocket -lnsl -lgen -lm
 #
 #LIBS = -lsocket -lnsl -L/usr/ucblib -lucb	# DRS NX only
-LIBS =  -lnsl -lsocket -ll			# solaris only
-#LIBS = 					# others
+#LIBS =  -lnsl -lsocket -ll			# solaris only
+LIBS = 					# others
 
 # where to install it
-prefix = /usr/local
+prefix = /usr/local/lib
 exec_prefix = $(prefix)/bcnu
 bindir = $(exec_prefix)/bin
 confdir = $(exec_prefix)/etc
@@ -33,6 +33,7 @@
 #
 
 all: bcnud bcnu bcnumsg
+	cp bcnud bcnu bcnumsg ../bin
 
 bcnu: bcnu.h bcnu.o lib.o ../etc/bcnu_version
 	${CC} ${CFLAGS} -o $@ bcnu.o lib.o ${LIBS}
@@ -44,7 +45,9 @@
 	${CC} ${CFLAGS} -o $@ bcnumsg.o lib.o ${LIBS}
 
 install: platform
-	cp bcnu bcnud bcnumsg $(bindir)
+	cp bcnu $(bindir)/bcnu.linux
+	cp bcnud $(bindir)/bcnud.linux
+	cp bcnumsg $(bindir)/bcnumsg.linux
 
 clean:	
 	rm -f *.o *~ bcnud bcnu bcnumsg
diff -ru src/src/process.c /usr/local/lib/bcnu/src/process.c
--- src/src/process.c	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/src/process.c	Fri Mar 10 12:42:37 2000
@@ -374,7 +374,7 @@
   if (err || msg || agt)
     {
       if (strlen (bcnud_in.bcnud_filename) == 0)
-	sprintf (otfile, "%s/files/%s.%d", bcnumsg, hostname, getpid ());
+	sprintf (otfile, "%sfiles/%s.%d", bcnumsg, hostname, getpid ());
       else
 	{
 	  if (!masterok)
diff -ru src/www/cgi-bin/bcnu.cgi /usr/local/lib/bcnu/www/cgi-bin/bcnu.cgi
--- src/www/cgi-bin/bcnu.cgi	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/www/cgi-bin/bcnu.cgi	Fri Mar 10 15:08:12 2000
@@ -78,7 +78,7 @@
 	$agdisp = '</TABLE><P><TABLE border=1>';
 	$agdisp .= "<TR><TH bgcolor=#bbaacc colspan=6 align=center>Recent Error History - $acks alerts unacknowledged</TH></TR>";
 	$agdisp .= "<FORM ACTION=\"$ENV{SCRIPT_NAME}\" METHOD=\"POST\" NAME=\"mainForm\">";
-	$agdisp .= "<TR><TH $DEFCELL>System<TH $DEFCELL>Status<TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message<TH $DEFCELL>Comment/Clear history</TR>\n";
+	$agdisp .= "<TR><TH $DEFCELL>System<TH $DEFCELL><A HREF=\"key.cgi\">Status</A><TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message<TH $DEFCELL>Comment/Clear history</TR>\n";
 
 	$agdisp .= $ackdisp;
 
@@ -108,6 +108,7 @@
 # produce default home page
 #
 
+if (scalar(keys %cell) < $PERLINE) { $PERLINE=scalar(keys %cell);}
 print &printhdr;
 if ($in{"status"}) {
 	print &header("Status only",$errlevel,5);
diff -ru src/www/cgi-bin/bcnu.inc /usr/local/lib/bcnu/www/cgi-bin/bcnu.inc
--- src/www/cgi-bin/bcnu.inc	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/www/cgi-bin/bcnu.inc	Thu Mar  9 16:01:22 2000
@@ -9,11 +9,11 @@
 
 require "dotsh.pl";
 
-dotsh("/usr/local/bcnu/etc/bcnuenv");
+dotsh("/usr/local/lib/bcnu/etc/bcnuenv");
 
 if ( $BCNUSERVER eq "linux" ) {	# linux doesn't seem to work correctly with bash
 	$ENV{'SHELL'}="/bin/sh";
-	dotsh("/usr/local/bcnu/etc/bcnulocal");
+	dotsh("/usr/local/lib/bcnu/etc/bcnulocal");
 }
 
 
diff -ru src/www/cgi-bin/bcnulib.pl /usr/local/lib/bcnu/www/cgi-bin/bcnulib.pl
--- src/www/cgi-bin/bcnulib.pl	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/www/cgi-bin/bcnulib.pl	Fri Mar 10 16:45:57 2000
@@ -34,8 +34,35 @@
 
 $hd1 = <<"Endofhd";
 <HTML><HEAD><TITLE>BCNU($BCNUHOST) monitor @ $now</TITLE>
-<META HTTP-EQUIV=REFRESH CONTENT=$refresh></HEAD>
-<BODY BGCOLOR=$DEFBG>
+<META HTTP-EQUIV=REFRESH CONTENT=$refresh>
+<script Language="JavaScript">
+//<!-- Hide me from other browsers
+var timerID = null;
+var timerRunning = false;
+var starttime= new Date();
+function stopclock (){
+   if(timerRunning)
+           clearTimeout(timerID);
+   timerRunning = false;
+}
+function startclock () {
+   // Make sure the clock is stopped
+   stopclock();
+   showtime();
+}
+function showtime () {
+   var now = new Date();
+   var diff = Math.floor((now-starttime)/1000);
+   document.clock.face.value = diff;
+// backup for meta tag reload, which sometimes doesn't work:
+   if ( diff > $refresh ) { window.location.reload(); }
+   timerID = setTimeout("showtime()",1000);
+   timerRunning = true;
+}
+// -->
+</SCRIPT>
+</HEAD>
+<BODY BGCOLOR=$DEFBG onLoad="startclock()">
 $SOUND<CENTER>
 <TABLE border=0><TR>
 <TD valign=top>
@@ -63,12 +90,13 @@
 
 Endofhd
 
-if ( ! $BCNUSTATIC && -r "$BCNUHOME/flags/bcnud.ack") {
+if ( ! $BCNUSTATIC && -s "$BCNUHOME/flags/bcnud.ack") {
 	$hd2 .= "<TR><TD><TH ALIGN=CENTER BGCOLOR=$RED>There are unacknowledged alerts</TD></TR>";
 }
 
 $hd3 = <<"Endofhd";
-<TR><TD><TD ALIGN=CENTER><B>Last update $now</TD><TD></TD>
+<TR><TD></TD><TD ALIGN=CENTER><B><form name="clock">Last update $now, <input type="text" name="face" size=4 value=""> seconds ago</form>
+</TD>
 </TABLE><P>$navigate
 <CENTER>
 <TABLE BORDER=1>
@@ -267,7 +295,7 @@
 
 local ($host) =@_;
 
-	$agdisp = "<TR><TH $DEFCELL>System<TH $DEFCELL>Status<TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message</TR>\n";
+	$agdisp = "<TR><TH $DEFCELL>System<TH $DEFCELL><A HREF=\"key.cgi\">Status</A><TH $DEFCELL>Agent<TH $DEFCELL>Date/Time<TH $DEFCELL>Message</TR>\n";
 
         foreach $agent (@agents) {
 
@@ -296,7 +324,7 @@
 	        close (BFILE);
 	        }
 	else {
-	        @incfile="Unable to open $bfilename";
+	        @incfile="Unable to open $bfilename: $!";
 	}
 	$agdisp .= "<TR><TD $BGCELL COLSPAN=7 >Contents of $bfilename\n";
 	$agdisp .= "<TR><TD COLSPAN=7 $ECELL><PRE>@incfile</pre></td></TR></TABLE>\n";
@@ -508,29 +536,29 @@
 
 if ( $type == 9 ) {
 	$IMG="$SAD ALT=\"Last error: $lasterr{\"$host-$type\"}\" >";
-	$cell{$host} .= "<TD $CELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $CELL ALIGN=CENTER>$ANCHOR $IMG";
 	}
 elsif ($type == 5 || $type == 6) {
 	$IMG="$WORRY ALT=\"Last warning: $lasterr{\"$host-$type\"}\" >";
-	$cell{$host} .= "<TD $CELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $CELL ALIGN=CENTER>$ANCHOR $IMG";
 	}
 elsif ($type == 1) {		# blackouts
 	$IMG="$NORMAL ALT=\"Blackout\" >";
-	$cell{$host} .= "<TD $BLACKCELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $BLACKCELL ALIGN=CENTER>$ANCHOR $IMG";
 	$DARK=1
 	}
 elsif ($type == 2) {		# Ignore
 	$IMG="$IMGIGNORE ALT=\"$lasterr{\"$host-$type\"}\" >";
-	$cell{$host} .= "<TD $IGNORECELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $IGNORECELL ALIGN=CENTER>$ANCHOR $IMG";
 	$DARK=1;
 	}
 elsif ($type == 3) {		# No report recently
 	$IMG="$NORMAL ALT=\"No report recently\" >";
-	$cell{$host} .= "<TD $WARNCELL WIDTH=70>$ANCHOR $IMG";
+	$cell{$host} .= "<TD $WARNCELL ALIGN=CENTER>$ANCHOR $IMG";
 	}
 else    {
 	$IMG="$NORMAL ALT=\"OK\" >";
-	$cell{$host} .= "<TD $CELL WIDTH=70>$ANCHOR$IMG";
+	$cell{$host} .= "<TD $CELL ALIGN=CENTER>$ANCHOR$IMG";
 	}
 if ($DARK) {
 	$cell{$host} .= "<BR><TABLE BGCOLOR=#FFFFFF><TD>$host</TABLE></a></TD>";
diff -ru src/www/cgi-bin/bcnuweb /usr/local/lib/bcnu/www/cgi-bin/bcnuweb
--- src/www/cgi-bin/bcnuweb	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/www/cgi-bin/bcnuweb	Fri Mar 10 13:03:19 2000
@@ -11,7 +11,7 @@
 require "getopts.pl";
 
 push (@INC,"$ENV{'BCNUHOME'}/cgi-bin");
-push (@INC,"/usr/local/bcnu/cgi-bin");
+push (@INC,"/usr/local/lib/bcnu/cgi-bin");
 
 require "bcnu.inc";
 require "bcnulib.pl";
@@ -140,6 +140,7 @@
         &agenthost ($host);
 
 	open (WEB,">$WWW/hosts/$host.htm") || die "can't write web page $WWW/hosts/$host.htm";
+	chmod 0644,"$WWW/hosts/$host.htm";
 
         print WEB &header("$host - Agent Summary",$errlevel,2);
         print WEB $agdisp;
diff -ru src/www/cgi-bin/buildanon /usr/local/lib/bcnu/www/cgi-bin/buildanon
--- src/www/cgi-bin/buildanon	Wed Mar  8 06:59:24 2000
+++ /usr/local/lib/bcnu/www/cgi-bin/buildanon	Thu Mar  9 16:02:14 2000
@@ -19,7 +19,7 @@
 		);
 
 push (@INC,"$ENV{'BCNUHOME'}/cgi-bin");
-push (@INC,"/usr/local/bcnu/cgi-bin");
+push (@INC,"/usr/local/lib/bcnu/cgi-bin");
 
 require "bcnu.inc";
 require "bcnulib.pl";
diff -ru src/www/docs/help.html /usr/local/lib/bcnu/www/docs/help.html
--- src/www/docs/help.html	Wed Mar  8 06:59:23 2000
+++ /usr/local/lib/bcnu/www/docs/help.html	Fri Mar 10 11:44:40 2000
@@ -411,3 +411,6 @@
 </FONT><FONT FACE="Terminal"><P>
 </FONT>
 
+</TABLE>
+</BODY>
+</HTML>
