再次查看集群资源状态
[grid@linuxidc1 ~]$crsctl stat res -t
---------------------------------------------------------------------
NAME TARGET STATE SERVER STATE_DETAILS
---------------------------------------------------------------------
Local Resources
---------------------------------------------------------------------ora.ARCH.dg
ONLINE ONLINE linuxidc1
ONLINE ONLINE linuxidc2
ora.CRS.dg
ONLINE ONLINE linuxidc1
ONLINE ONLINE linuxidc2
ora.DATA.dg
ONLINE ONLINE linuxidc1
ONLINE ONLINE linuxidc2
ora.LISTENER.lsnr
ONLINE ONLINE linuxidc1
ONLINE ONLINE linuxidc2
ora.asm
ONLINE ONLINE linuxidc1 Started
ONLINE ONLINE linuxidc2 Started
ora.gsd
OFFLINE OFFLINE linuxidc1
OFFLINE OFFLINE linuxidc2
ora.net1.network
ONLINE ONLINE linuxidc1
ONLINE ONLINE linuxidc2
ora.ons
ONLINE ONLINE linuxidc1
ONLINE ONLINE linuxidc2
ora.registry.acfs
ONLINE ONLINE linuxidc1
ONLINE ONLINE linuxidc2
---------------------------------------------------------------------
Cluster Resources
---------------------------------------------------------------------ora.LISTENER_SCAN1.lsnr
1 ONLINE ONLINE linuxidc2
ora.cvu
1 ONLINE ONLINE linuxidc2
ora.linuxidc.db
1 ONLINE ONLINE linuxidc1 Open
2 ONLINE ONLINE linuxidc2 Open
ora.linuxidc1.vip
1 ONLINE ONLINE linuxidc1
ora.linuxidc2.vip
1 ONLINE ONLINE linuxidc2
ora.oc4j
1 ONLINE ONLINE linuxidc2
ora.scan1.vip
1 ONLINE ONLINE linuxidc2
[grid@linuxidc1 ~]$
3. asmca图形界面创建
切换到grid用户下,执行asmca启动图形界面进行配置
启动图形界面后,点击asm instance可以看到advm driver状态为loaded。若acfs与advm驱动未加载时,状态为installed,volumes与asmcluster file systems标签栏为灰色无法点击。点击volumes标签,创建卷。
图中为使用命令创建成功的卷。再次点击create
指定卷名为linuxidcvol,大小为25G,点击OK。
创建成功,点击ok退出,显示如下:
点击asm clusterfile systems标签
点击create,选择刚才创建的卷,选择database home file system选项,并指定图中所示挂载点。选择该选项该文件系统将作为集群资源被注册在集群中,由集群进行管理。
点击ok,创建ACFS文件系统。点击ok执行的命令如下
Create ACFSCommand:
/sbin/mkfs -t acfs/dev/asm/linuxidc-347
Following commandsshould be run as privileged user :
/u01/app/11.2.0/grid/bin/srvctladd filesystem -d /dev/asm/linuxidc-347 -g 'DATA' -v linuxidcvol -m/u01/app/grid/acfsmounts/data_linuxidcvol -u grid
/u01/app/11.2.0/grid/bin/srvctlstart filesystem -d /dev/asm/linuxidc-347
chown grid:oinstall/u01/app/grid/acfsmounts/ data_linuxidcvol
chmod 775/u01/app/grid/acfsmounts/data_linuxidcvol
根据提示使用root账户在ASMCA图形界面启动的节点上执行途中所示命令,如下:
[root@linuxidc1 ~]#/u01/app/grid/cfgtoollogs/asmca/scripts/acfs_script.sh
ACFS file system isrunning on linuxidc1,jxcw2
[root@linuxidc1 ~]#
备注:途中所执行脚本内容如下:
[root@linuxidc1 ~]# vi/u01/app/grid/cfgtoollogs/asmca/scripts/acfs_script.sh
#!/bin/sh
/u01/app/11.2.0/grid/bin/srvctlstop filesystem -d /dev/asm/linuxidcvol-347
/u01/app/11.2.0/grid/bin/srvctlremove filesystem -d /dev/asm/linuxidcvol-347
/u01/app/11.2.0/grid/bin/srvctladd filesystem -d /dev/asm/linuxidcvol-347 -g 'DATA' -v linuxidcVOL -m/u01/app/grid/acfsmounts/data_linuxidcvol -u grid
if [ $? ="0" -o $? = "2" ]; then
/u01/app/11.2.0/grid/bin/srvctl startfilesystem -d /dev/asm/linuxidcvol-347
if [ $? = "0" ]; then
chown grid:oinstall/u01/app/grid/acfsmounts/data_linuxidcvol
chmod 775/u01/app/grid/acfsmounts/data_linuxidcvol
/u01/app/11.2.0/grid/bin/srvctl statusfilesystem -d /dev/asm/linuxidcvol-347
exit 0
fi
/u01/app/11.2.0/grid/bin/srvctl statusfilesystem -d /dev/asm/linuxidcvol-347
fi
执行成功在两节点分别查看,新加ACFS文件系统已被挂载。