in reply to Re^2: Help...Issue with Net::SSH::Perl Module
in thread Help...Issue with Net::SSH::Perl Module

i find that, this module works fine on Linux, but it always has some issues on Windows.
Do you mean the system running your perl program, or the target of the program? Is the target Linux?

Do you have another ssh2 client program (like putty) that you can use to make sure your windows system has all the necessary libraries? It seems like the code can login, it's just when it tries to execute the command, something goes wrong.

fnord

  • Comment on Re^3: Help...Issue with Net::SSH::Perl Module

Replies are listed 'Best First'.
Re^4: Help...Issue with Net::SSH::Perl Module
by toddyce (Initiate) on Nov 26, 2010 at 06:18 UTC
    thanks for your reply. yes, i ran the same script on Linux, it works fine, it can connect to the remote host and execute all the commands i sent. but on Windows, it can't. The target host is a Linux machine.
    I have SSH, putty and SecureCRT on my Windows, they all work fine.
    yes, it can login, but when executing the comand, it hangs. very strange, if i change the command as this: $ssh->cmd("ls -al > /dev/null","\n"), then it works. but i can not do that, i want the output of the command.
      This might solve your problem.
        That link logs folks out Khen1950fx, use [id://758068|This]