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>) { ... }
In reply to Re: Piping children?
by tilly
in thread Piping children?
by chrisl1433
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |