in reply to Re^2: Perl non-blocking IPC
in thread Perl non-blocking IPC

It's been a while since I've seen actual FileHandle usage. You don't need it; assuming you're using a perl newer than 5.00505:

open(my $fh, '-|', qw( tail -f -n command_file)) || die("Unable to run tail: $!.\n");

You can pass a single string, but whenever possible, call system(), open(), etc. with a list for the command; it's safer, because you're guaranteed not to get filtered through /bin/sh.