in reply to Re^3: Net::SCP::Expect Error Handling
in thread Net::SCP::Expect Error Handling

I have executed the command. and its working fine. It also display the error message. It creates the scp-capture file but does not write anything to it.

Replies are listed 'Best First'.
Re^5: Net::SCP::Expect Error Handling
by salva (Canon) on Jan 29, 2016 at 12:38 UTC
    It creates the scp-capture file but does not write anything to it.

    Yes, the scp command doesn't output anything by default unless some error happens. You can set the verbose option in order to change that.