Loop while socket connection exists

2007-03-08 Thread mlist
I have a script which will create a socket connection to a host. It should loop through while the socket connection is active. The problem is that it still continues to loop even if I take down the interface on the host machine. What am I missing (no doubt somthing simple). Any help would b

Re: Grep through a log file

2006-11-09 Thread mlist
> > Matt, > > The problem is that has already returned EOF. The next > time around, Perl says "nothing more to see here, folks; move along" > and exits the while block. If you want to read from it again, you need > to reopen it. Just put the open inside the while () block. > That did it, than

Re: Grep through a log file

2006-11-09 Thread mlist
> Matt, > > A couple of things here. first, you don't perform any modification of > $culist, but the strings in $culist don't appear unmodified in the log > file. the string perl reads into $_ from a file like you're example is > e.g. "SUN9-GT:\n". The string in the log file, though, is just > "SU

Grep through a log file

2006-11-09 Thread mlist
I hope this is an easy one (I have a feeling it is). I'm trying to parse through a single, large firewall log file. I need to run through a file to get the firewall name and push the associated data to it's own log file. This is what I have so far: #!/usr/bin/perl use warnings; use strict; op