shell-script-pt
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [shell-script] Executar comando ssh com CGI em Sheel Script


From: Eliel
Subject: Re: [shell-script] Executar comando ssh com CGI em Sheel Script
Date: Fri, 30 May 2014 18:15:08 -0300

Opa, vi uns scripts meus aqui, e me lembro que passei por um problema parecido quando precisei colocar ssh dentro de loop.

Tenta usar o parametro -n
ssh -n AÇÕES

 -n      Redirects stdin from /dev/null (actually, prevents reading from stdin).  This must be used when ssh is run in the background.  A common trick is to use this to
             run X11 programs on a remote machine.  For example, ssh -n shadows.cs.hut.fi emacs & will start an emacs on shadows.cs.hut.fi, and the X11 connection will be
             automatically forwarded over an encrypted channel.  The ssh program will be put in the background.  (This does not work if ssh needs to ask for a password or
             passphrase; see also the -f option.)


Espero ser util.


2014-05-30 17:11 GMT-03:00 address@hidden [shell-script] <address@hidden>:
 

Obrigado pela dica Eliel, o problema é que ele gera um arquivo sem conteudo, pelo fato de desconectar antes de receber o retorno do comando, como não é um terminal e sim o browser que interage com o script o comportamento é diferente, mas vou olhar o link que me passou acredito que vai ajudar, no mais obrigado.

Att.
Anderson Junior



reply via email to

[Prev in Thread] Current Thread [Next in Thread]