shanthiann has asked for the wisdom of the Perl Monks concerning the following question:
How can i get output,how can i debug this code and give me comments on this code.#!/usr/bin/perl use Net::SSH2; my $ssh2 = Net::SSH2->new(); $ssh2->connect('$HostName') or die "Unable to connect $HostName $@ \n" +; $ssh2->auth_password('$user_id','$password') or die "Unable to login $ +@ \n"; my $chan = $ssh2->channel(); $chan->exec('ls -ltr') or die "Unable to execute the command $@ \n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: help on Net::SSH2
by madbombX (Hermit) on Aug 21, 2006 at 17:06 UTC | |
|
Re: help on Net::SSH2
by zentara (Cardinal) on Aug 21, 2006 at 17:33 UTC | |
by shanthiann (Acolyte) on Aug 22, 2006 at 11:51 UTC | |
by zentara (Cardinal) on Aug 22, 2006 at 12:00 UTC | |
|
Re: help on Net::SSH2
by zentara (Cardinal) on Aug 22, 2006 at 15:54 UTC |