Solaris下修改RAC環境節點IP地址
簡單描述一下如何修改RAC環境中節點的IP地址。
這是一個3節點RAC環境:
SQL> SELECT INSTANCE_NUMBER, INSTANCE_NAME, HOST_NAME, VERSION, STATUS
2 FROM GV$INSTANCE;
INSTANCE_NUMBER INSTANCE_NAME HOST_NAME VERSION STATUS
--------------- ---------------- ---------- ----------------- ------------
1 testrac1 racnode1 10.2.0.4.0 OPEN
3 testrac3 racnode3 10.2.0.4.0 OPEN
2 testrac2 racnode2 10.2.0.4.0 OPEN
檢查三個節點的地址配置:
bash-2.03$ more /etc/hosts
#
# Internet host table
#
127.0.0.1 localhost
172.25.198.222 racnode1 loghost
172.25.198.224 racnode1-vip
10.0.0.1 racnode1-priv
172.25.198.223 racnode2
172.25.198.225 racnode2-vip
10.0.0.2 racnode2-priv
172.25.198.226 racnode3
172.25.198.227 racnode3-vip
10.0.0.3 racnode3-priv
下面準備修改節點3對應的PUBLIC IP、PRIVATE IP和VITUAL IP。
首先關閉例項3上的資料庫和CLUSTERWARE:
# /etc/init.d/init.crs stop
Shutting down Oracle Cluster Ready Services (CRS):
Jun 13 11:07:50.361 | INF | daemon shutting down
Stopping resources. This could take several minutes.
Successfully stopped CRS resources.
Stopping CSSD.
Shutting down CSS daemon.
Shutdown request successfully issued.
Shutdown has begun. The daemons should exit soon.
修改三個主機上的/etc/hosts檔案,將裡面的節點3的配置改為目標IP地址:
172.25.198.228 racnode3 loghost
172.25.198.229 racnode3-vip
10.0.0.4 racnode3-priv
確保3個節點上的/etc/host檔案都被修改:
# more /etc/hosts
#
# Internet host table
#
::1 localhost
127.0.0.1 localhost
172.25.198.228 racnode3 loghost
172.25.198.229 racnode3-vip
10.0.0.4 racnode3-priv
172.25.198.222 racnode1
172.25.198.224 racnode1-vip
10.0.0.1 racnode1-priv
172.25.198.223 racnode2
172.25.198.225 racnode2-vip
10.0.0.2 racnode2-priv
在節點三上手工修改IP:
# ifconfig ce1 10.0.0.4 netmask 255.255.0.0 broadcast 10.0.255.255
# ifconfig ce0 172.25.198.228 netmask 255.255.0.0 broadcast 172.25.255.255
修改PUBLIC IP後,需要以新的IP地址重新連線節點3:
# ifconfig -a
lo0: flags=2001000849
inet 127.0.0.1 netmask ff000000
ce0: flags=1000843
inet 172.25.198.228 netmask ffff0000 broadcast 172.25.255.255
ether 0:3:ba:2c:d8:da
ce1: flags=1000843
inet 10.0.0.4 netmask ffff0000 broadcast 10.0.255.255
ether 0:3:ba:2c:d8:da
確認PUBLIC IP和PRIVATE IP已經正常。
檢查各個節點上的tnsnames.ora以及資料庫中的remote_listener引數,如果這些配置是透過主機名進行的配置則無需修改。如果是透過IP直接配置的,那麼根據節點3的新地址進行相應的修改。
修改結束後,在節點1或節點2上以圖形方式用root啟動VIPCA,進行節點3VIP的配置:
# xhost +
access control disabled, clients can connect from any host
# /data/oracle/product/10.2/crs/bin/vipca
如果前面對/etc/hosts下的修改正確的話,這裡不需要進行任何的修改,Oracle自動可以找到對應的新地址。點選確認後,Oracle在重新配置VIP過程中會報錯,因為節點3上的CLUSTERWARE並未啟動,忽略這個錯誤。
在節點3上啟動CLUSTERWARE和資料庫:
# /etc/init.d/init.crs start
Startup will be queued to init within 30 seconds.
切換到Oracle,檢查
$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.4.0 - Production on 星期日 6月 13 11:36:40 2010
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
連線到:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options
SQL> SET PAGES 100 LINES 120
SQL> COL HOST_NAME FORMAT A10
SQL> SELECT INSTANCE_NUMBER, INSTANCE_NAME, HOST_NAME, VERSION, STATUS
2 FROM GV$INSTANCE;
INSTANCE_NUMBER INSTANCE_NAME HOST_NAME VERSION STATUS
--------------- ---------------- ---------- ----------------- ------------
3 testrac3 racnode3 10.2.0.4.0 OPEN
2 testrac2 racnode2 10.2.0.4.0 OPEN
1 testrac1 racnode1 10.2.0.4.0 OPEN
SQL> SELECT INSTANCE_NAME FROM V$INSTANCE;
INSTANCE_NAME
----------------
testrac3
節點地址修改完成。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/4227/viewspace-667732/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- RAC修改IP地址
- 【RAC】Oracle rac修改IP地址及埠號命令參考Oracle
- RAC環境修改spfile的位置
- 【RAC】如何修改SCAN IP的IP地址、名稱、埠等資訊
- 11.2.0.4 RAC生產環境刪除故障節點與增加新服務節點
- DM8 配置DMDSC主備環境(rac到單節點 )
- 更改rac scanIP IP的地址
- Solaris下Oracle RAC 11.2.0.4 安裝方法Oracle
- RAC環境下建立物理DATAGUARD(1)
- RAC環境下建立物理DATAGUARD(2)
- RAC和ASM環境下打patchASM
- Solaris 10.5配置主機名、IP地址、閘道器
- Oracle RAC 環境下的連線管理Oracle
- Oracle RAC修改Scan IP,Public IP的方法Oracle
- Solaris叢集節點重啟
- ElasticSearch(單節點)環境配置Elasticsearch
- Oracle RAC修改public, VIP, SCAN IPOracle
- ubuntu22.04修改IP地址Ubuntu
- CentOS8修改IP地址CentOS
- ubuntu系統 IP地址修改Ubuntu
- Solaris 10下遷移10G RAC (二)
- Solaris 10下遷移10G RAC (七)
- Solaris 10下遷移10G RAC (三)
- Solaris 10下遷移10G RAC (一)
- Solaris 10下遷移10G RAC (五)
- Solaris 10下遷移10G RAC (六)
- Solaris 10下遷移10G RAC (八)
- Solaris 10下遷移10G RAC (四)
- Oracle RAC環境下ASM磁碟組擴容OracleASM
- kubernetes環境部署單節點redisRedis
- 如何修改 Rancher Server 的 IP 地址Server
- Oracle RAC新增節點Oracle
- Linux IP地址修改與配置問題Linux
- RAC環境下的SEQUENCE對應用的影響
- 【Swagger】2.不在生產環境暴露,可以修改預設地址Swagger
- 2節點RAC安裝
- rac新增節點前之清除節點資訊
- 11g RAC 修改PUBLIC-IP、VIP、PRIV-IP、SCAN-IP
- Oracle 12.2 RAC修改public ip address或public ip(subnet (netmask) or interface)Oracle