ITPub博客

首页 > Linux操作系统 > Linux操作系统 > 转载一个step by step change public-ip and vip on RAC

转载一个step by step change public-ip and vip on RAC

原创 Linux操作系统 作者:lwitpub 时间:2012-03-22 15:36:48 0 删除 编辑
更改10g RAC公网IP以及VIP的简单步骤:
1. Stop all crs resources 标准操作步骤,参考另一帖子:
http://space.itpub.net/628922/viewspace-690171
2. Modify /etc/hosts 这里修改以后为如下:
[oracle@hsdb1 admin]$ cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
 
127.0.0.1        localhost.localdomain localhost
::1              localhost6.localdomain6 localhost6
 
#### for oracle rac
 
192.168.5.220    hsdb1
192.168.5.222    hsdb1-vip
10.10.10.1       hsdb1-priv
 
192.168.5.221    hsdb2
192.168.5.223    hsdb2-vip
10.10.10.2       hsdb2-priv
(注:RAC中所有节点都需要进行修改。)

3. Change $ORACLE_HOME/network/admin/listener.ora 这里修改以后如下:
[oracle@hsdb1 admin]$ cat listener.ora ……………………………………………………………………………………………………
LISTENER_HSDB1 = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.5.222)(PORT = 1521)(IP = FIRST)) (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.5.220)(PORT = 1521)(IP = FIRST)) ) )
(注:如果这里host你用的name,那么不必进行修改。)

4. Delete Public eth0 (在其中一个node操作即可) [root@localhost bin]# ./oifcfg getif
eth0 192.168.1.0 global public eth1 10.10.10.0 global cluster_interconnect   [root@localhost bin]# ./oifcfg delif -global eth0 [root@localhost bin]# ./oifcfg getif
eth1 10.10.10.0 global cluster_interconnect

5. Add new public eth0 [root@localhost bin]# ./oifcfg setif -global eth0/192.168.5.0:public   [root@localhost bin]# ./oifcfg getif
eth0 192.168.5.0 global public <== 新的网段 eth1 10.10.10.0 global cluster_interconnect   (注:因为vip地址必须跟public ip处于同一网段,故公网IP网段更改以后,必须更改vip地址或网段。)
6. Change vip
++++++ Node 1 ++++++
[root@hsdb1 bin]# ./srvctl modify nodeapps -n hsdb1 -A 192.168.5.222/255.255.255.0/eth0
 
++++++ Node 2 ++++++
[root@hsdb2 bin]# ./srvctl modify nodeapps -n hsdb2 -A 192.168.5.223/255.255.255.0/eth0

7. Start cluster all resource
参考另一个帖子:
http://space.itpub.net/628922/viewspace-690171 crs_stat -t 如果有OFFLINE的resource,手工crs_start启动即可

8. Change local_listener
++++++ Node 1 ++++++

SQL>show parameter listener

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
local_listener string (ADDRESS=(PROTOCOL=tcp)(HOST=1
92.168.1.222)(PORT=1521))

SQL>ALTER system SET local_listener = '(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.5.222)(PORT = 1521))' scope = BOTH sid = 'hskj1';

System altered.

++++++ Node 2 ++++++

SQL> ALTER system SET local_listener = '(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.5.223)(PORT = 1521))' scope = BOTH sid = 'hskj2';

System altered.

另外,ssh等效性不需要重新配置。

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/628922/viewspace-719290/,如需转载,请注明出处,否则将追究法律责任。

下一篇: ORA-01152 故障解决
请登录后发表评论 登录
全部评论

注册时间:2009-05-08

  • 博文量
    107
  • 访问量
    385883