其他分享
首页 > 其他分享> > 关于RAC修改scan ip

关于RAC修改scan ip

作者:互联网

修改scan ip无需停止数据库实例,asm或crs
例如:scan ip需要从192.168.10.24改为192.168.10.25

  1. 在节点1,进入grid安装的bin目录,查看当前scan ip状态信息 (需以root用户执行)
 [root@rac1 bin]# ./srvctl config scan
 SCAN name: rac-cluster-scan, Network:1/192.168.10.0/255.255.255.0/eth0 SCAN VIP name: scan1, IP:/rac-cluster-scan/192.168.10.24
  1. 以root用户停止scan_listener,scan ip服务
 [root@rac1 bin]# ./srvctl stop
 scan_listener [root@jzh1 bin]# ./srvctl stop scan 
 [root@rac1 bin]#./srvctl status scan 
 SCAN VIP scan1 is enabled SCAN VIP scan1 is not running
  1. 在所有节点/etc/hosts文件中修改新scan ip地址
 [root@rac1 bin]# vi /etc/hosts
 192.168.10.20 rac1
 192.168.10.21 rac2
    
 192.168.10.22 rac1-vip
 192.168.10.23 rac2-vip
     
 100.0.0.101 rac1-priv
 100.0.0.102 rac2-priv
    
 192.168.10.25 rac-scan
  1. 以root用户修改scan ip
[root@rac1 bin]# ./srvctl modify scan -n 192.168.10.25
  1. 修改后确认
[root@rac1 bin]# ./srvctl config scan
SCAN name: 192.168.10.25, Network: 1/192.168.10.0/255.255.255.0/eth0
SCAN VIP name: scan1, IP: /192.168.10.25/192.168.1.25

可以看到已经修改过来了。

  1. 启动scan_listener,scan
[root@rac1 bin]# ./srvctl start scan
[root@rac1 bin]# ./srvctl start scan_listener
  1. 进行ping测试
[root@rac1 bin]# ping 192.168.10.25
PING 192.168.10.25 (192.168.10.25) 56(84) bytes of data.
64 bytes from 192.168.10.25: icmp_seq=1 ttl=64 time=1.78 ms
64 bytes from 192.168.10.25: icmp_seq=2 ttl=64 time=1.23 ms
64 bytes from 192.168.10.25: icmp_seq=3 ttl=64 time=0.444 ms
64 bytes from 192.168.10.25: icmp_seq=4 ttl=64 time=0.512 ms
64 bytes from 192.168.10.25: icmp_seq=5 ttl=64 time=0.891 ms
  1. 确认scan,scan_listener.ora状态
[grid@rac1 ~]$ crs_stat -t | grep scan
ora.scan1.vip  ora....ip.type ONLINE    ONLINE   rac2   
[grid@rac1 ~]$ crs_stat -t | grep lsnr
ora....ER.lsnr ora....er.type ONLINE    ONLINE    rac1        
ora....N1.lsnr ora....er.type ONLINE    ONLINE   rac2        
ora....H1.lsnr application    ONLINE    ONLINE   rac1        
ora....H2.lsnr application    ONLINE    ONLINE   rac2 

标签:bin,10.25,rac1,ip,scan,192.168,root,RAC
来源: https://blog.csdn.net/qq_39111199/article/details/114660427