Can't connect client when runned from Windows Service
Adriana Rodean
adrya1984 at gmail.com
Tue Dec 16 19:08:13 EST 2008
Hi all,
Thank you all for the help :)
Finally good news, made it to work as Network Service and connects
successfully :)
This is the correct script:
@echo off
:RUN echo Connecting…
"C:/Program Files/OpenSSH/bin/ssh.exe" -R 20210:localhost:50300 -o
BatchMode=yes -o StrictHostKeyChecking=no -o VerifyHostKeyDNS=no -o
TCPKeepAlive=no -o ServerAliveInterval=15 -o ServerAliveCountMax=2 -i
"C:/Program Files/Visma/OPGatewayService/id_rsa" visma at 10.55.40.123
echo Restarting in 10 seconds…
GOTO RUN
Best regards and thanks again,
Adriana
On Mon, Dec 15, 2008 at 23:18, Jim Knoble <jmknoble at pobox.com> wrote:
> Circa 2008-12-15 11:22 dixit Adriana Rodean:
>
> : Hi, thanks for replying.
> : I tried:
> :
> : "C:/Program Files/OpenSSH/bin/ssh.exe" -R 40201:localhost:50300 -o
> : TCPKeepAlive=no -o ServerAliveInterval=15 -o ServerAliveCountMax=2 -T
> : -N -i "C:/id_rsa" visma at 10.55.40.123
> :
> : still doesn't connect when started as service.
> :
> [...]
> : I am thinking that it allows to connect with user account because the
> : known_hosts file was previous created. As soon as i deleted that file
> : ssh asked if i am sure to connect to the linux machine because is not
> : known. If i answered yes known_hosts file was created in c:\documents
> : and settings\[user]\.ssh folder.
> [...]
> : Is it a way to make ssh not ask that first question (we can't input
> : yes from service)? or make it recognize the known_hosts file?
>
> Look for 'StrictHostKeyChecking' in the 'ssh_config' man page.
>
> : And is it a way to output the verbose to a file? Tried '-ddd' it said
> : invalid command.
>
> The '-d' switch is for sshd (the server). Use '-v' (lowercase vee) for
> ssh (the client).
>
> You probably need to create either a (Cygwin or MinGW) bash.exe script
> or a CMD/BAT script in order to redirect the output to a file.
>
> Good luck.
>
> --
> jim knoble | jmknoble at pobox.com | http://www.pobox.com/~jmknoble/
> (GnuPG key ID: C6F31FFA >>>>>> http://www.pobox.com/~jmknoble/keys/ )
> (GnuPG fingerprint: 99D8:1D89:8C66:08B5:5C34::5527:A543:8C33:C6F3:1FFA)
> +----------------------------------------------------------------------+
> |[L]iberty, as we all know, cannot flourish in a country that is perma-|
> | nently on a war footing, or even a near-war footing. --Aldous Huxley|
> +----------------------------------------------------------------------+
>
More information about the openssh-unix-dev
mailing list