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

 

     Re: [nocol-users] webnocol.cgi

(this message got bounced because non-member submissions are not permitted
to the list and I think Rick sent it from a different email address ?

BTW- I do get about 2-3 bounced spam messages per week- so its good that
we made this list 'closed'  (at a price ofcourse).

	-vikas

 Date: Fri, 18 Dec 1998 09:32:51 -0500
 From: Rick Beebe <richard.beebe@yale.edu>
 Subject: Re: [nocol-users] webnocol.cgi
 To: Dirk Baetjer <db@stardivision.de>
 Cc: Alan Halachmi <alan@halachmi.net>, nocol-users@navya.com
 Message-id: <367A6793.D03FCD26@yale.edu>
 Organization: Yale University School of Medicine

No, that's not true. Both of these variations work--yours, Dirk, takes the
end of the file and filters it. Alan's searches the file and then displays
just the last few results. Also, tail only produces continuous output if you
use the '-f' switch.

I tried them both and they both work for me. What's happening for you Alan?
No output or an error message? One thing I found useful was to add

print "Command: $cmd<p>\n";

immediately following the line that reads
$cmd =~ s/DEVICE/$siteaddr/ ;

That reveals, for example, that when I run this on a hostmon variable (I had
a machine showing low disk space) $siteaddr was translating to '-' so my
command was

grep - logfile

which, indeed, didn't produce the results I was expecting.

  _______________________________________________________________________

    Rick Beebe                                           (203) 785-6416
    Manager, Systems & Network Engineering          FAX: (203) 785-3606
    ITS-Med Client & Technology Services         Richard.Beebe@yale.edu   
    Yale University School of Medicine                                 
    P.O. Box 208078, New Haven, CT 06520-8078
  _______________________________________________________________________


> tail is a program to visualize the last part of a file. If you want to
> filter the output, you have to use it in this way:
> 
> local ($tail) = "/usr/bin/tail /var/log/datalog| /usr/bin/grep
> DEVICE";
> 
> It has nothing to do with Perl... :-)
> 
> By the way: tail produces continous output. If you only want to see
> problems in the past, use cat instead.
> 
> Bye,
> 
> Dirk
> 
> >>>>>>>>>>>>>>>>>> Ursprüngliche Nachricht <<<<<<<<<<<<<<<<<<
> 
> Am 18.12.98, 08:08:54, schrieb Alan Halachmi <alan@halachmi.net> zum
> Thema [nocol-users] webnocol.cgi:
> 
> > Quick question...
> 
> >       I'm no PERL wizard, so I'm in need of some help.  I
> > added another command to the troubleshooting area of webnocol.
> > When I had the webnocol.cgi line read:
> > local ($tail) = "tail /var/log/datalog";
> > everything worked fine.
> 
> > However, when I changed it to:
> > local ($tail) = "/usr/bin/grep DEVICE /var/log/datalog |
> /usr/bin/tail";
> > it no longer works.
> 
> > I tried:
> > local ($tail) = "/usr/bin/grep DEVICE /var/log/datalog"
> > but that didn't work either.
> 
> > I'd like to be able to take a site, grep it from the datalog file and
> tail the output of the grep, but I'm not having any luck.
> 
> > Ideas?
> 
> > TIA,
> > Alan
> 
> > --
> > Alan Halachmi
> > Wide Area Networks Specialist
> > Ingram Entertainment Network Services
> > mailto:alan@halachmi.net
> > http://www.ingramentertainment.com


--

----- End of forwarded message from owner-nocol-users@navya.com -----

----- End of forwarded message from owner-nocol-users@navya.com -----