in reply to Piping children?

The problem is that Net::SSH::Perl waits until the command ends to send you any output. Your choices are either to modify Net::SSH::Perl to do this (from a glance at the code this is not entirely simple because it is not internally line-oriented), or to use another approach.

Personally I would set ssh keys up so that the remote machine trusted the local one for autologin, then I would:

my $command = "ssh $machine 'tail -f /var/log/2001-log'"; open(REMOTE, "$command |") or die "Can't run \"$command\": $!"; while (my $line = <REMOTE>) { ... }