in reply to Re^2: Net:::SSH::Perl to windows machine
in thread Net:::SSH::Perl to windows machine

In order to provide complete help, it is necessary to know what sshd server is running on windows. Most importantly, what shell is being executed. When you type some-command 1>nul 2>&1 you should get nothing in either stdout or stderr, as you have redirected stdout to 'nul' and sent stderr there as well. The output 'some-command: not found' is a stderr msg, which you should not be receiving.
  1. Can you run the command with no arguments or redirections?
  2. It is clear that the 'ls' command works. Can you invoke it using a full path (including the drive letter)?
  3. If you are running ssh-2, can you execute the command using a relative path, ie
    $$sshobj->cmd("cd \"C:\platform\ilo\bin\""); $$ssh->obj->cmd(".\lo100cfg.exe");

Replies are listed 'Best First'.
Re^4: Net:::SSH::Perl to windows machine
by perldesire (Scribe) on Sep 17, 2009 at 14:27 UTC
    @Illuminatus, Thanks for your help. Finally it works..
    ($out,$err,$ext)= $sshobj->cmd('cd \"C:\\platform\\ilo\\bin\\"; ./lo10 +0cfg.exe -s');