Page 1 of 1

SSH in Command Line

Posted: Mon Feb 13, 2006 8:49 am
by eyalush
Hi There, :lol: :?: :o

I'm working with 7.5.1.a on Win 2003.
We are trying to run a shell command on a remote Linux server,
We install an Open SSH and copied the Key between the servers and when I use a cmd line on the DS server and it works fine (the command is: "ssh etl01@rotemtest /home/etl01/etl.sh") it runs a ls -l command.

BUT, when I run a DS JOB from the same server as a command stage or Execute command on Seq or a before job subroutine it get stuck in the same place and can't be stopped.
When I look on the Process I can see that it started a SSH.exe Process and That it stuck and preventing the DS to finish.

I think that It some how connected to the user that runs the JOB but I don't know how to fix the Problem.....

Does anyone know the Answer?

Eyal

Re: SSH in Command Line

Posted: Mon Feb 13, 2006 8:55 am
by manojkumarnayak
r u giving all the parameters right like server name , user id & password .
All value are case sensitive.


regards
manoj

Posted: Mon Feb 13, 2006 9:54 am
by roy
Hi Eyal and Welcome aboard :)

As far as I recall you need to configure something or invoke it with a full path to make it work via command stage.
Contact one of our guys at "Sherutei Briut Clalit" and ask how they used the SFU pack for windows on their server.

I recall it had also similar issues in the beginning.

Did you compare the environment between the command line you use in a cmd window and the one showing in the job log entry?

:idea: I know of cases where the only thing that worked was using a filter command in a sequential file stage to run the command, so try that as well.

Do post back your findings.
(Or I'll hunt your cell phone for a while j/k ;))

IHTH,

RE:

Posted: Tue Feb 14, 2006 4:18 am
by eyalush
Well, :roll: :?:

I checked the ENV between DS JOB ( in the Director the Environment variable settings against the Windows ENV cmd:>"SET" ),

This is the Results:
DS JOB ENV:
USER=CAMPUS\e069515
USERPROFILE=C:\Documents and Settings\Default User
WINDOWS ENV:
USERNAME=e069515
USERPROFILE=C:\Documents and Settings\e069515

I think that this is the Problem ...to run a SSH from the same USER PROFILE ...does anyone knows or have another solution?

Thanks,
Eyal R

Posted: Tue Feb 14, 2006 7:13 am
by Amos.Rosmarin
Hi,


The command hangs because it prompts and it is waiting for your answer.
You should use a routine that simulates the process (look at the ftp routine as an example).

Once you'll manage to do the first handshake you will be able to use this without pwd



Amos