SSH in BatchMode

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

 



> Hi All,
> 
> We have a requirement of connecting two linux machines for executing
> some scripts. These script will invoke SSH command to login to the
> remote linux machine and execute some commands. We are able to do so
> manually, but in batch mode (via scripts), we are prompted for a
> password. To avoid it, the documentation for SSH says
> 
> 1. Log in to the remote linux machine once manually, to store the RSA
> key of the remote machine. After completing the step, we cross checked
> and the key is rightly stored in /etc/ssh/known_hosts
> 
> 2. Generate the RSA/DSA keys on the client machine and copy the public
> keys on the remote machine. The public keys should be copied to a file
> ~/.ssh/authorized_keys on the remote machine. We have done this as
> well. 
> 
> 3. We have also changed the file/directory permission for ~/.ssh &
> ~/.ssh/authorized_key to be read-write for user only by executing 
> >chmod -R 600 .ssh
> 
> 4. Additionally, we have created ~/.ssh/known_hosts at the client
> machine containing the RSA public key of remote linux machine.
> 
> As per the documentation, we should now be able to login on the remote
> linux machine without being prompted for the password. For us, we
> still get a Permission denied error i.e. after invoking the following
> command on client
> >ssh -2o BatchMode=true -l <usrlogin> <remoteLinuxMachine>
> It results in 
> > Permission denied (publickey,gssapi-with-mic,password)
> 
> Anyone has any idea on how to get through this problem.
> 
> The concerned files containing the appropriate debug/configuration
> information are attached.
> 
> Regards,
> Vikas
> 
>  <<ssh-debug3.log>>  <<remote.sshd_config>>  <<sshd-ddd.log>>  
> <<client.ssh_config>> 
-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux