环境:
两台power720
AIX 5300-11
HACMP 5.5
oracle 10g(stanby模式)
需要操作:
原先系统运行在测试环境,经过一段时候测试后,系统运行状态稳定、可靠,需迁移至生产环境上进行生产,所以要进行IP地址的更换。结合IBM文档及网上的资料,我的实际操作步骤如下:
步骤:
1.获取当前HACMP环境里配置的IP地址
#/usr/sbin/cluster/utilities/cllsif > /tmp/cllsif.old
/tmp/cllsif.old文件里就会包含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. 修改boot网卡的IP地址,网关肯定也是要修改的,通过smitty mktcpip修改后,有一个问题就是通过netstat -rn查路由就会发再系统中有两个默认路由,这时必须通过smitty route删除原来的默认路由。(注意一点:系统重启后,netstat -rn才会出现两条路由,很多时候IP更换操作没注意到这点,等过了很长时候系统重启后,会发现连接主机的时候会时断时续,就是这个原因引起的!)
7.在HACMP配置里更改IP
7.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)
--> 回车
7.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,否则同步的时候会出现如下错误
------------------------------- ---------------------------------------------------
Command: failed stdout: yes stderr: no
Before command completion, additional instructions may appear below.
migcheck[471]: cl_connect() error, nodename=nntsyw2, rc=-1
cldare: A communication error prevents obtaining the VRMF from remote nodes.
A DARE cannot be run until this is corrected. Please ensure clcomd is running.
-----------------------------------------------------------------------------------
同时记得要把两个节点的/usr/es/sbin/cluster/etc/rhosts文件中的内容清空
7.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.4. service ip地址还需在资源组中进行改变,将新service ip地址添加资源组中,记住一点两边都做,涉及的资源组都要做;
HACMP
--> Extended Configuration
--> HACMP Extended Resources Configuration
-->Change/Show Resources and Attributes for a Resource Group
在Service IP Labels/Addresses [nntsyw1_svc] +中选择修改后service IP
8.同步HACMP
#smit hacmp
--> Extended Configuration
--> Extended Verification and Synchronization
--> 在Verify, Synchronize or Both处选择Both
--> 回车执行
9.检查更改是否生效
在这里我选择的检查方式是查看HACMP的配置信息。
10.启动HACMP服务
# smit clstart --> 选择两个节点启动
#/usr/sbin/cluster/utilities/cllsif > /tmp/cllsif.new //查看HA启动后的IP设置,比较/tmp/cllsif.new文件和先前的/tmp/cllsif.old文件,所有ip地址的改变都将反映出来。
11. 进行必要的HACMP资源接管测试。
具体操作:
smitty hacmp
--> System Management(C-SPOC)
--> HACMP Resouce group and application Management
--> Move a Resource Group to Another Node / Site
--> Move Resource Groups to Another Node
--> jcdb_res online org_scr (选择需要移动的资源)
--> select a Destination Node (选择需要移动的目的节点)
--> nntsyw2 (目标节点)
添加新评论1 条评论
2012-10-26 17:17