Passwordless SSH

From INIwiki
Jump to: navigation, search

Digg this!

<meta name="keywords" content="linux, ssh, passwordless"></meta> <meta name="description" content="Configure passwordless ssh access across multiple machines"></meta>

Generate SSH Key on client machine.

# ssh-keygen -t dsa

Press enter for the next three questions. By default your key will be saved as in /home/user/.ssh/

Create a copy of your public key to a unique name that identifies the client host:

# cd /root/.ssh/
# cp

Send the file to the target host.

# rsync -rave ssh /root/.ssh/ targethost:/root/.ssh/

On the target host copy the contents of the client host's key into the authorized_keys file.

# cat /root/.ssh/ >> /root/.ssh/authorized_keys

Test a ssh connection from client to target. No password required!

Digg this!

Personal tools