Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: OpenSSH capture perl-command

by salva (Monsignor)
on Mar 15, 2014 at 07:16 UTC ( #1078426=note: print w/ replies, xml ) Need Help??


in reply to OpenSSH capture perl-command

The command argument to Net::OpenSSH methods must be a system command (e.g. ls, grep, etc.). You can not pass perl code there.

In your particular case, you can use SFTP to query the remote filesystem:

use Data::Dumper; my $sftp = $ssh->sftp; my $stat = $sftp->stat($remote_file); print Dumper($stat), "\n";


Comment on Re: OpenSSH capture perl-command
Select or Download Code
Re^2: OpenSSH capture perl-command
by Alasharin (Initiate) on Mar 17, 2014 at 10:27 UTC

    ....Thanks...
    Regards, Armin </>

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (3)
As of 2014-09-21 10:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (168 votes), past polls