建立兩台電腦間已ssh連線不需輸入密碼的方式
建立兩台電腦間已ssh連線不需密碼的方式
1. in both node execute
/usr/bin/ssh-keygen -t rsa
/usr/bin/ssh-keygen -t dsa
2. in both node execute
cat /home/staff/ghoster/.ssh/id_rsa.pub >> authorized_keys
cat /home/staff/ghoster/.ssh/id_dsa.pub >> authorized_keys
3. in both node
scp authorized_keys xx.xx.xx.xx:/home/ghoster/.ssh/
done
ps. 須注意覆蓋的檔. 並可以存很多不同的內容於同一各擋內