ssh_without_a_password_using_public_private_keys
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
ssh_without_a_password_using_public_private_keys [2008/01/27 23:35] – created juckins | ssh_without_a_password_using_public_private_keys [2009/02/12 11:43] (current) – juckins | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | SSH / rysnc without password: \\ | + | ======SSH / rysnc without password====== |
make sure the same versions of ssh are on both machines (open version 3.1+ works best for HP-UX boxes) \\ | make sure the same versions of ssh are on both machines (open version 3.1+ works best for HP-UX boxes) \\ | ||
need to configure client (machine connecting from) and server (machine connecting to) \\ | need to configure client (machine connecting from) and server (machine connecting to) \\ | ||
on client: | on client: | ||
- | cd to ~/ | + | < |
- | ssh-keygen -t rsa -f ~/ | + | cd ~/.ssh |
- | ssh-keygen -t dsa -f ~/ | + | ssh-keygen -t rsa -f ~/ |
+ | ssh-keygen -t dsa -f ~/ | ||
+ | </ | ||
this creates id_dsa, id_dsa.pub, id_rsa, id_rsa.pub - optionally can enter a ' | this creates id_dsa, id_dsa.pub, id_rsa, id_rsa.pub - optionally can enter a ' | ||
on server: \\ | on server: \\ | ||
- | cd ~/.ssh/ \\ | + | < |
- | create authorized_keys files | + | cd ~/.ssh/ |
+ | </ | ||
+ | vi authorized_keys2 | ||
copy the id_dsa.pub and id_rsa.pub from client into authorized_keys file \\ | copy the id_dsa.pub and id_rsa.pub from client into authorized_keys file \\ | ||
make sure permissions 644 on authorized_keys \\ | make sure permissions 644 on authorized_keys \\ | ||
+ | Also: | ||
+ | < | ||
+ | chmod 0700 / | ||
+ | </ | ||
Repeat process for creating keys on server, and copy the .pub keys to the client' | Repeat process for creating keys on server, and copy the .pub keys to the client' | ||
Line 19: | Line 27: | ||
To restart sshd: kill running sshd process \\ | To restart sshd: kill running sshd process \\ | ||
- | issue the command | + | now issue: |
+ | < | ||
+ | </ | ||
- | Or for Red Hat systems: service sshd restart | + | Or for Red Hat systems: |
+ | < | ||
+ | service sshd restart | ||
+ | </ |
ssh_without_a_password_using_public_private_keys.txt · Last modified: 2009/02/12 11:43 by juckins