in reply to Watch log for string (tail -f)
"Not working" isn't particularly helpful. What is it doing? Any error messages, etc.?
Anyway, here's how I process the a log file with tail -f:
#!/usr/bin/perl use strict; use warnings; open my $FH, 'tail -f t |' or die; while (<$FH>) { chomp; # processing goes here.... }
...roboticus
When your only tool is a hammer, all problems look like your thumb.
In Section
Seekers of Perl Wisdom