sshHost.pl 247 Bytes Raw Blame History Permalink 1 2 3 4 5 6 7 8 9 10 11 12 13 14 use strict; use Net::OpenSSH; my $host = $ARGV[1]; my $user = $ARGV[2]; my $pwd = $ARGV[3]; my $ssh = Net::OpenSSH->new($host, user=>$user, password=>$pwd , timeout => 10); my $cmd = "uname -a"; my @out = $ssh->capture($cmd); print "@out";