一、依據IBM官網上文檔進行動作
内容提要:
環境:
AIX 5L
HACMP 5.2/5.3/5.4
步驟:
1.擷取目前HACMP環境裡配置的IP位址
#/usr/sbin/cluster/utilities/cllsif > /tmp/cllsif.orig
/tmp/cllsif.orig檔案裡就會包含HACMP網卡目前的IP位址
2.停止所有節點的HACMP服務
#smit clstop --> 選擇HA的兩個節點 --> 回車
3.在兩個節點上分别編輯/etc/hosts,将boot, standby, service更改成要求的IP位址
4.在兩個節點上分别用”smit chinet”更改boot和standby網卡的IP為要求的IP,需要和/etc/hosts中的IP對應一緻
5.在兩個節點上互相ping對方的boot和standby的IP,確定能ping通
6.在HACMP配置裡更改IP
6.1.更改Service IP
第一步:删除原來的service IP label
# smit hacmp --> Extended Configuration --> Extended Resource Configuration --> HACMP Extended Resources Configuration --> Configure HACMP Service IP Labels/Addresses --> Remove Service IP Label(s)/Address(es) --> 選擇IP标簽 --> 回車
第二步:添加新的Service IP Label
# smit hacmp --> Extended Configuration --> Extended Resource Configuration --> HACMP Extended Resources Configuration --> Configure HACMP Service IP Labels/Addresses --> Add a Service IP Label/Address --> Configurable on Multiple Nodes --> 選擇網絡(比如net_ether_01) --> 在IP Label/Address處選擇新的Server IP标簽(清單中應該能看到更改後的server IP) --> 回車
6.2.更改boot IP
# smit hacmp --> Extended Configuration --> Extended Topology Configuration --> Configure HACMP Nodes --> Change/Show a Node in the HACMP Cluster --> 選擇一個節點 --> 在Communication Path to Node處重新選擇新的boot IP --> 回車執行
用同樣的方法為另一個節點選擇新的boot IP
6.3.更改standby IP
第一步:删除原來的standby interface
# smit hacmp --> Extended Configuration --> Extended Topology Configuration --> Configure HACMP Communication Interfaces/Devices --> Remove Communication Interfaces/Devices --> 選擇一個節點的standby接口 --> 回車執行
第二步:添加新的standby interface到網絡(比如net_ether_01)中
# smit hacmp --> Extended Configuration --> Extended Topology Configuration --> Configure HACMP Communication Interfaces/Devices --> Add Communication Interfaces/Devices --> Add Pre-defined Communication Interfaces and Devices --> Communication Interfaces --> 選擇網絡(比如net_ether_01) --> 在IP Label/Address處選擇更改後的standby IP,在Node Name處選擇standby IP對應的節點名,在Network Interface處輸入standby IP對應的網絡接口 --> 回車執行
用上述方法更改另一個節點的standby IP。
7.同步HACMP
#smit hacmp --> Extended Configuration --> Extended Verification and Synchronization --> 在Verify, Synchronize or Both處選擇Both --> 回車執行
8.檢查更改是否生效
1) #cd /var/hacmp/odmcache
2) 進入另一個節點名為名字的檔案夾
3) #cd _etc_objrepos
4) #export ODMDIR=./
5) #odmget CuAt | grep –p enX //enX為boot後者standby的接口名
6) 察看上述指令輸出的IP位址是否已經是更改後的,然後用同樣的方法察看本節點的IP位址是否已經被改變。
7) #export ODMDIR=/etc/objrepos //将ODM的路徑改回原來的路徑
如果條件允許,也請在另一個節點上察看ODM的IP記錄是否變更正确。
9.啟動HACMP服務
# smit clstart --> 選擇兩個節點啟動
#/usr/sbin/cluster/utilities/cllsif > /tmp/cllsif.new //檢視HA啟動後的IP設定,比較/tmp/cllsif.new檔案和先前的/tmp/cllsif.orig檔案,所有ip位址的改變都将反映出來。
10. 進行必要的HACMP資源接管測試。
本文轉自 liu99fifa 51CTO部落格,原文連結:http://blog.51cto.com/andrewliu/697807,如需轉載請自行聯系原作者