SOS...on system command
- From: cyrusgreats@xxxxxxxxx
- Date: Thu, 17 Jul 2008 13:35:30 -0700 (PDT)
I'm trying to store out put into the array the search for string in
this case truncating, but when I run the following command it prints
all the output before going to the foreach loop, it was my
understanding that the out put of the of the command will be saved
into @output then it can be searched, can some tell me where I go
wrong on this..thanks in advance...
my $sys = "dude";
my @output= `snmpwalk -c public -v 1 $sys .1 |grep \"truncating\"`;
foreach my $el (@output) {
next if ($el !=m~ ^\truncating\);
print " .................$el\n";
}
.
- Follow-Ups:
- Re: SOS...on system command
- From: xhoster
- Re: SOS...on system command
- From: J. Gleixner
- Re: SOS...on system command
- Prev by Date: Re: How to identify a 32 or 64 bit OS?
- Next by Date: Re: How to identify a 32 or 64 bit OS?
- Previous by thread: find which subgroups don't match in regex
- Next by thread: Re: SOS...on system command
- Index(es):
Relevant Pages
|