oracle rac ssh对等,如何为Oracle RAC配置SSH

众所周知,在安装Oracle Clusterware(Former Oracle CRS)之前,有一些必备的条件,比如双网卡,同版本的操作系统,一些必需的补丁等等,还有一些比如同样ID的组和用户,这些都可以通过clusterware附带的一个检查工具cluvfy进行检查。详细的列表和检查方法可以参考oracle的官方安装文档

除此之外,安装之前另外一个重要的前提就是ssh或者rsh的配置,这就是oracle在节点之间进行文件copy时候必须的,下面就分十个步骤介绍如何进行ssh的配置。

1. Login as oracle user

2. create .ssh directory in the oracle user’s home directory

$cd

$mkdir ~/.ssh

$chmod 700 ~/.ssh

3. Generate an RSA and DSA key for SSH

$/usr/bin/ssh-keygen -t rsa

$/usr/bin/ssh-keygen -t dsa

4. After this, four files generated

~/.ssh/id_rsa.pub

~/.ssh/id_rsa

~/.ssh/id_dsa.pub

~/.ssh/id_dsa

5. Create an authorized key file

$touch ~/.ssh/authorized_keys

$cd ~/.ssh

$ls

6. Copy the contents of rsa.pub and dsa.pub files to authrorized file

[oracle@node1 .ssh]$ ssh node1 cat /home/oracle/.ssh/id_rsa.pub >> authorized_keys

oracle@node1’s password:

[oracle@node1 .ssh]$ ssh node1 cat /home/oracle/.ssh/id_dsa.pub >> authorized_keys

[oracle@node1 .ssh$ ssh node2 cat /home/oracle/.ssh/id_rsa.pub >> authorized_keys

oracle@node2’s password:

[oracle@node1 .ssh$ ssh node2 cat /home/oracle/.ssh/id_dsa.pub >>authorized_keys

oracle@node2’s password:

7. Use scp to copy the authorized file to other nodes in ~/.ssh

[oracle@node1 .ssh]scp authorized_keys node2:/home/oracle/.ssh/

8. Change the permissions on the oracle user’s authorized file on all cluster nodes

$ chmod 600 ~/.ssh/authorized_keys

9. Enable OUI to use ssh and scp

$ exec /usr/bin/ssh-agent $SHELL

$ /usr/bin/ssh-add

10. Verify ssh configuration on all nodes

$ ssh nodename1 date

$ ssh nodename2 date

其他的具体步骤可以参考oracle的手册B28264-03,地址如下:

http://download.oracle.com/docs/cd/B28359_01/install.111/b28264/toc.htm

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值