my $pid = open SSH, '-|', qw[ ssh -l gmon 3par-S400 statvv -ni ] or die $!; my @lines; push @lines, $_ while ( $_ = ) !~ m[Press the enter key to stop...]; kill 9, $pid; ## process data