# su – oracle
# mkdir ~/.ssh
# chmod 755 ~/.ssh
# /usr/bin/ssh-keygen -t rsa
# /usr/bin/ssh-keygen -t dsa
# touch ~/.ssh/authorized_keys
$ ssh db01 cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
$ ssh db01 cat ~/.ssh/id_dsa.pub >> ~/.ssh/authorized_keys
$ ssh db02 cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
$ ssh db02 cat ~/.ssh/id_dsa.pub >> ~/.ssh/authorized_keys
节点2:
bash-3.2$ ssh db02 cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
oracle@db02's password:
WARNING: Your password has expired.
Password change required but no TTY available.
节点一上面测试成功
收起