第一步:改public ip metalink文档id:283684.1
[oracle@db2 ~]$oifcfg getif ***查看public ip内容
[oracle@db2 ~]$oifcfg delif -global eth0 ***删除
[oracle@db2 ~]$oifcfg setif -global eth0/192.168.3.0:public ***重新设置
第二步:改vip metalink文档id:276434.1
[oracle@db2 ~]$srvctl config nodeapps -n db1 -a ***查看vip内容
[oracle@db2 ~]$srvctl stop instance -d racdb -i racdb1
[oracle@db2 ~]$srvctl stop instance -d racdb -i racdb2
[oracle@db2 ~]$srvctl stop database -d racdb
[oracle@db2 ~]$srvctl stop nodeapps -n db1
[oracle@db2 ~]$srvctl stop nodeapps -n db2
修改hosts文件,将各个名称与新改地址对应好
修改eth文件 将eth0的地址即public地址改成新地址
之后以root执行以下命令
[root@db2 ~]#srvctl modify nodeapps -n db1 -A 192.168.3.202/255.255.255.0/eth0
[root@db2 ~]#srvctl modify nodeapps -n db2 -A 192.168.3.204/255.255.255.0/eth0
[root@db1 ~]# srvctl config nodeapps -n db1 -a
VIP exists.: /db1-vip/192.168.3.202/255.255.255.0/eth0
[root@db1 ~]# srvctl config nodeapps -n db2 -a
VIP exists.: /db2-vip/192.168.3.204/255.255.255.0/eth0
在各节点修改listener文件,将涉及到监听地址的地方改为新的ip地址
然后启动:
[oracle@db2 ~]$srvctl start nodeapps -n db1
[oracle@db2 ~]$srvctl start nodeapps -n db2
[oracle@db2 ~]$srvctl start database -d racdb
[oracle@db2 ~]$srvctl start instance -d racdb -i racdb1
[oracle@db2 ~]$srvctl start instance -d racdb -i racdb2
或者直接重启各个节点。
一个知识点:nodeapps服务控制VIP、GSD、LISTENER、和ONS等。
第一次做完后,在启动nodeapps 时候报错:
[oracle@db1 ~]$ srvctl start nodeapps -n db1
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:LSNRCTL for Linux: Version 10.2.0.4.0 - Production on
13-APR-2009 18:11:13
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:Copyright (c) 1991, 2007, Oracle. All rights reserved.
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:Starting /opt/oracle/app/prod102/bin/tnslsnr: please
wait...
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:TNSLSNR for Linux: Version 10.2.0.4.0 - Production
db1:ora.db1.LISTENER_DB1.lsnr:System parameter file is
/opt/oracle/app/prod102/network/admin/listener.ora
db1:ora.db1.LISTENER_DB1.lsnr:Log messages written to
/opt/oracle/app/prod102/network/log/listener_db1.log
db1:ora.db1.LISTENER_DB1.lsnr:Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)
(HOST=192.168.3.202)(PORT=1521)))
db1:ora.db1.LISTENER_DB1.lsnr:Error listening on: (DESCRIPTION=(ADDRESS=
(PROTOCOL=TCP)(HOST=192.168.1.201)(PORT=1521)(IP=FIRST)))
db1:ora.db1.LISTENER_DB1.lsnr:TNS-12545: Connect failed because target host or object
does not exist
db1:ora.db1.LISTENER_DB1.lsnr: TNS-12560: TNS:protocol adapter error
db1:ora.db1.LISTENER_DB1.lsnr: TNS-00515: Connect failed because target host or
object does not exist
db1:ora.db1.LISTENER_DB1.lsnr: Linux Error: 99: Cannot assign requested address
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:Listener failed to start. See the error message(s)
above...
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:LSNRCTL for Linux: Version 10.2.0.4.0 - Production on
13-APR-2009 18:11:16
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:Copyright (c) 1991, 2007, Oracle. All rights reserved.
db1:ora.db1.LISTENER_DB1.lsnr:
db1:ora.db1.LISTENER_DB1.lsnr:Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)
(HOST=db1-vip)(PORT=1521)(IP=FIRST)))
db1:ora.db1.LISTENER_DB1.lsnr:TNS-12541: TNS:no listener
db1:ora.db1.LISTENER_DB1.lsnr: TNS-12560: TNS:protocol adapter error
db1:ora.db1.LISTENER_DB1.lsnr: TNS-00511: No listener
db1:ora.db1.LISTENER_DB1.lsnr: Linux Error: 111: Connection refused
db1:ora.db1.LISTENER_DB1.lsnr:Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)
(HOST=192.168.1.201)(PORT=1521)(IP=FIRST)))
db1:ora.db1.LISTENER_DB1.lsnr:TNS-12560: TNS:protocol adapter error
db1:ora.db1.LISTENER_DB1.lsnr: TNS-00530: Protocol adapter error
db1:ora.db1.LISTENER_DB1.lsnr: Linux Error: 113: No route to host
db1:ora.db1.LISTENER_DB1.lsnr:Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)
(KEY=EXTPROC)))
db1:ora.db1.LISTENER_DB1.lsnr:TNS-12541: TNS:no listener
db1:ora.db1.LISTENER_DB1.lsnr: TNS-12560: TNS:protocol adapter error
db1:ora.db1.LISTENER_DB1.lsnr: TNS-00511: No listener
db1:ora.db1.LISTENER_DB1.lsnr: Linux Error: 2: No such file or directory
CRS-0215: Could not start resource 'ora.db1.LISTENER_DB1.lsnr'.
这个错误就是没有修改各节点listener文件所导致,其监听地址还为原来的地址。
阅读(2726) | 评论(0) | 转发(0) |