| Tairone 2006-10-31, 7:25 pm |
| Hi all,
I wrote a script to verify if the comand ssh is correctly configured in
some servers, and I'm having problems with return codes. I previously
made a copy of the public keys files from a central server to the file
authorized_keys of all servers in my network, so everything is ok.
When conect via ssh to the server "serv10" from the central server, the
server does not prompt for password. I type the comand "exit 0" and
again in the central server "echo $?". It returns the correct code: 0.
But in the following script, which I wrote for making the verification,
the behavior is diferent.
#!/bin/ksh
ssh -o ConnectTimeout=3D30 -o NumberOfPasswordPrompts=3D0 -o
StrictHostKeyChecking=3Dno serv10 << ENDSSH
exit 0
ENDSSH
echo $?
Surprisingly, the ssh is returning the code 255 when I execute this
script. This happens only for this and other 2 servers.
Can anyone help me?
=20
Thanks in advance.
=20
Tairone Nunes Magalh=E3es
Telemar - Brazil
|