Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^3: NET::OpenSSH to execute multiple commands

by hmb104 (Sexton)
on Aug 24, 2012 at 20:19 UTC ( #989635=note: print w/ replies, xml ) Need Help??


in reply to Re^2: NET::OpenSSH to execute multiple commands
in thread NET::OpenSSH to execute multiple commands

This is the ssh sub:

sub SSHconnect { my $ip = shift; my $user = shift; my $pass = shift; my %options = ( user => $user, passwd => $pass, master_stderr_discard => 1, master_opts => [ -o => "UserKnownHostsFile=/dev/null", ], ssh_cmd => '/usr/local/bin/ssh' ); my $ssh = Net::OpenSSH->new( $ip, %SSHOptions ); $ssh->error and die( $SSH->error ); return ($SSH); }


Comment on Re^3: NET::OpenSSH to execute multiple commands
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://989635]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2015-07-30 02:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (269 votes), past polls