Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: How do I debug a problem with Net:SSH

by injunjoel (Priest)
on Nov 15, 2005 at 23:19 UTC ( [id://508843]=note: print w/replies, xml ) Need Help??


in reply to How do I debug a problem with Net:SSH

Greetings,
you might want to check the errstr Attribute from your $scp->scp() call.
From docs:
... Returns false and sets the errstr attribute if there is an error.

So something like the following perhaps untested
$scp->scp( "/export/home/xorl/websterproject/xferlist.txt", "/tmp/websterproject_xfer.txt" ) or die $scp->{errstr}."\n";


-InjunJoel
"I do not feel obliged to believe that the same God who endowed us with sense, reason and intellect has intended us to forego their use." -Galileo

Replies are listed 'Best First'.
Re^2: How do I debug a problem with Net:SSH
by xorl (Deacon) on Nov 16, 2005 at 13:09 UTC

    Thanks but now I'm almost as perplexed as before.

    cp: cannot stat `/export/home/xorl/websterproject/xferlist.txt': No such file or directory

    Thinking I might need to tell it to look on the remote box I tried $scp->scp("10.33.1.75:/export/home/xorl/websterproject/xferlist.txt", "/tmp/websterproject_xfer.txt"); and I got

    Warning: something's wrong at ./getxfers.pl line 7. (which is the scp line)

    I then tried using the alternate $scp->get() syntax and got same something's wrong warning :(

    Now just to be sure I ssh'ed to the remote box and made sure the file exists, stat showed that the file exists with 644 permissions and my Uid and Gid.

    Now I have more information than before, but I feel more lost in the dark than ever. *sigh*

    Can anyone shed some light on this? Thanks again

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (6)
As of 2024-04-23 16:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found