Oracle12cRAC搭建手册

来源:互联网 发布:淘宝ulzzang短发女模特 编辑:程序博客网 时间:2024/05/20 02:25

1 共享设备配置

1.1 设备划分说明

冗余策略

卷划分及大小说明

OCRVOTING

Ocrvoting01

8G

Ocrvoting02

8G

Ocrvoting03

8G

DATAFILE

Data01

8G

Data02

8G

FRA_ARCH

Fra01

8G

Fra02

8G

 

我们这里OCRVOTING 采用Normal,DATA和FRA 采用external。

 

11g中每个OCR和vote disk 至少需要600M空间。在ASM 的冗余级别中:

external >= 1

normal >=3

high >=5

 

在12c里面,OCR voting disk 外部冗余,至少需要4342MB的空间,Normal 至少需要8711MB的空间。

 

Cause - Insufficient spaceavailable in the selected Disks. At least, 4,342 MB of free space isrequired. Action - Chooseadditional disks such that the total size should be at least 4,342 MB.

 

Cause - Insufficient spaceavailable in the selected Disks. At least, 8,711 MB of free space isrequired. Action - Chooseadditional disks such that the total size should be at least 8,711 MB.

 

具体创建过程,直接在VBOX上创建,或者参考我以前的blog,这里不在详述。

 

1.2 配置UDEV

 

用如下脚本获取绑定脚本:

for i in b c d e f g h;doecho "KERNEL==\"sd*\", BUS==\"scsi\",PROGRAM==\"/sbin/scsi_id -g -u /dev/\$name\", RESULT==\"`/sbin/scsi_id -g -u/dev/sd$i`\", NAME=\"asm-disk$i\", OWNER=\"grid\",GROUP=\"asmadmin\", MODE=\"0660\""done--在所有节点创建并配置UDEV Rules 文件[root@asm ~]# touch /etc/udev/rules.d/99-oracle-asmdevices.rules--添加如下内容:KERNEL=="sd*",BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u /dev/$name",RESULT=="1ATA_VBOX_HARDDISK_VB0fe2de72-ff43e01f",NAME="asm-diskb", OWNER="grid", GROUP="asmadmin",MODE="0660"KERNEL=="sd*",BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u /dev/$name",RESULT=="1ATA_VBOX_HARDDISK_VBb84b3378-7205c629",NAME="asm-diskc", OWNER="grid", GROUP="asmadmin",MODE="0660"KERNEL=="sd*",BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u /dev/$name", RESULT=="1ATA_VBOX_HARDDISK_VB8c6d2199-64d26b1e",NAME="asm-diskd", OWNER="grid", GROUP="asmadmin",MODE="0660"KERNEL=="sd*",BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u /dev/$name",RESULT=="1ATA_VBOX_HARDDISK_VBc86e3f5c-ba9c8397",NAME="asm-diske", OWNER="grid", GROUP="asmadmin",MODE="0660"KERNEL=="sd*",BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u /dev/$name",RESULT=="1ATA_VBOX_HARDDISK_VB4776a8c1-0b444519",NAME="asm-diskf", OWNER="grid", GROUP="asmadmin",MODE="0660"KERNEL=="sd*",BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u /dev/$name",RESULT=="1ATA_VBOX_HARDDISK_VBb7771090-d177eeaf",NAME="asm-diskg", OWNER="grid", GROUP="asmadmin",MODE="0660"KERNEL=="sd*",BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u /dev/$name",RESULT=="1ATA_VBOX_HARDDISK_VBe7da4ea4-622fea96",NAME="asm-diskh", OWNER="grid", GROUP="asmadmin",MODE="0660"--重启UDEV:[root@asm rules.d]# start_udevStarting udev: [ OK ]--检查共享设备的所属关系和权限:[root@rac1 ~]# ll /dev/asm*brw-rw---- 1 grid asmadmin 8, 16 May 28 22:55 /dev/asm-diskbbrw-rw---- 1 grid asmadmin 8, 32 May 28 22:55 /dev/asm-diskcbrw-rw---- 1 grid asmadmin 8, 48 May 28 22:55 /dev/asm-diskdbrw-rw---- 1 grid asmadmin 8, 64 May 28 22:55 /dev/asm-diskebrw-rw---- 1 grid asmadmin 8, 80 May 28 22:55 /dev/asm-diskfbrw-rw---- 1 grid asmadmin 8, 96 May 28 22:55 /dev/asm-diskgbrw-rw---- 1 grid asmadmin 8, 112 May 2822:55 /dev/asm-diskh[root@rac1 ~]#

2 安装RAC的准备工作

 

2.1 添加组和用户(所有节点)

groupadd -g 1000 oinstallgroupadd -g 1200 asmadmingroupadd -g 1201 asmdbagroupadd -g 1202 asmopergroupadd -g 1300 dbagroupadd -g 1301 operuseradd -m -u 1100 -g oinstall -Gasmadmin,asmdba,asmoper,dba -d /home/grid -s /bin/bash griduseradd -m -u 1101 -g oinstall -Gdba,oper,asmdba -d /home/oracle -s /bin/bash oracle--将用户grid添加到dba组:[root@rac1 app]# gpasswd -a grid dbaAdding user grid to group dba--确认用户信息:[root@rac1 ~]# id oracleuid=502(oracle) gid=507(oinstall)groups=507(oinstall),502(dba),503(oper),506(asmdba)[root@rac1 ~]# id griduid=1100(grid) gid=507(oinstall) groups=507(oinstall),504(asmadmin),506(asmdba),505(asmoper)--修改密码:passwd oraclepasswd grid

 

 

2.2 禁用防火墙和SELNUX(所有节点)

 

关闭防火墙:

service iptables statusservice iptables stopchkconfig iptables offchkconfig iptables --list

 

设置/etc/selinux/config 文件,将SELINUX设置为disabled。

[root@rac1 ~]# cat/etc/selinux/config# This file controls the state of SELinuxon the system.# SELINUX= can take one of these threevalues:# enforcing - SELinux security policy is enforced.# permissive - SELinux prints warnings instead of enforcing.# disabled - No SELinux policy is loaded.SELINUX=disabled# SELINUXTYPE= can take one of these twovalues:# targeted - Targeted processes are protected,# mls - Multi Level Security protection.SELINUXTYPE=targeted

 

2.3 配置时间同步(所有节点)

 

这里我们使用CTSS.所以要停用 NTP 服务,并从初始化序列中禁用该服务,并删除 ntp.conf 文件。以 root 用户身份在两个 OracleRAC 节点上运行以下命令:

[root@rac1 ~]# /sbin/service ntpd stopShutting down ntpd: [ OK ][root@rac1 ~]# chkconfig ntpd off[root@rac1 ~]# mv /etc/ntp.conf/etc/ntp.conf.original[root@rac1 ~]# chkconfig ntpd --listntpd 0:off 1:off 2:off 3:off 4:off 5:off 6:off[root@rac2 ~]# /sbin/service ntpd stopShutting down ntpd: [ OK ][root@rac2 ~]# chkconfig ntpd off[root@rac2 ~]# mv /etc/ntp.conf/etc/ntp.conf.original[root@rac2 ~]# chkconfig ntpd --listntpd 0:off 1:off 2:off 3:off 4:off 5:off 6:off

还要删除以下文件:

rm /var/run/ntpd.pid

此文件保存了 NTP 后台程序的 pid。

 

2.4 创建目录结构(所有节点)

mkdir -p /u01/gridsoft/12.1.0mkdir -p /u01/gridbasechown -R grid:oinstall /u01chown -R grid:oinstall /u01mkdir -p/u01/oracle/12.1.0/db_1chown-R oracle:oinstall /u01/oraclechmod -R 775 /u01

2.5 配置环境变量

2.5.1 Grid用户

修改grid用户的.bash_profile.注意每个节点的不同内容:

export ORACLE_SID=+ASM1#export ORACLE_SID=+ASM2export ORACLE_BASE=/u01/gridbaseexport ORACLE_HOME=/u01/gridsoft/12.1.0exportPATH=$ORACLE_HOME/bin:$PATH:/usr/local/bin/:.export TEMP=/tmpexport TMP=/tmpexport TMPDIR=/tmpumask 022

 

2.5.2 Oracle 用户

修改oracle 用户的.bash_profile,注意每个节点的不同内容:

ORACLE_SID=cndba1;export ORACLE_SID#ORACLE_SID=cndba2;export ORACLE_SIDORACLE_UNQNAME=cndba;export ORACLE_UNQNAMEJAVA_HOME=/usr/local/java; export JAVA_HOMEORACLE_BASE=/u01/oracle; export ORACLE_BASEORACLE_HOME=$ORACLE_BASE/12.1.0/db_1; exportORACLE_HOMEORACLE_TERM=xterm; export ORACLE_TERMNLS_DATE_FORMAT="YYYY:MM:DDHH24:MI:SS"; export NLS_DATE_FORMATNLS_LANG=american_america.ZHS16GBK; exportNLS_LANGTNS_ADMIN=$ORACLE_HOME/network/admin; exportTNS_ADMINORA_NLS11=$ORACLE_HOME/nls/data; exportORA_NLS11PATH=.:${JAVA_HOME}/bin:${PATH}:$HOME/bin:$ORACLE_HOME/bin:$ORA_CRS_HOME/binPATH=${PATH}:/usr/bin:/bin:/usr/bin/X11:/usr/local/binexport PATHLD_LIBRARY_PATH=$ORACLE_HOME/libLD_LIBRARY_PATH=${LD_LIBRARY_PATH}:$ORACLE_HOME/oracm/libLD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/lib:/usr/lib:/usr/local/libexport LD_LIBRARY_PATHCLASSPATH=$ORACLE_HOME/JRECLASSPATH=${CLASSPATH}:$ORACLE_HOME/jlibCLASSPATH=${CLASSPATH}:$ORACLE_HOME/rdbms/jlibCLASSPATH=${CLASSPATH}:$ORACLE_HOME/network/jlibexport CLASSPATHTHREADS_FLAG=native; export THREADS_FLAGexport TEMP=/tmpexport TMPDIR=/tmpumask 022

2.6 为安装用户设置资源限制

 

 

2.6.1 修改/etc/security/limits.conf

 

以 root 用户身份,在每个 Oracle RAC 节点上,在 /etc/security/limits.conf 文件中添加如下内容,或者执行执行如下命令:

[root@rac1 ~]# cat >> /etc/security/limits.conf <<EOFgrid soft nproc 2047grid hard nproc 16384grid soft nofile 1024grid hard nofile 65536oracle soft nproc 2047oracle hard nproc 16384oracle soft nofile 1024oracle hard nofile 65536EOF

2.6.2 修改/etc/pam.d/login

在每个 OracleRAC 节点上,在 /etc/pam.d/login 文件中添加或编辑下面一行内容:

[root@rac1 ~]# cat >> /etc/pam.d/login <<EOFsession required pam_limits.soEOF

 

2.6.3 shell 的限制

对默认的 shell 启动文件进行以下更改,以便更改所有 Oracle 安装所有者的 ulimit 设置:

[root@rac1 ~]# cat >> /etc/profile <<EOFif [ /$USER ="oracle" ] || [ /$USER = "grid" ]; thenif[ /$SHELL = "/bin/ksh" ]; thenulimit-p 16384ulimit-n 65536elseulimit-u 16384 -n 65536fiumask022fiEOF

注:红色部分一起执行

 

2.6.4 修改/etc/sysctl.conf

#vi /etc/sysctl.confkernel.shmmax = 4294967295kernel.shmall = 2097152kernel.shmmni = 4096kernel.sem = 250 32000 100 128fs.file-max = 6815744net.ipv4.ip_local_port_range = 9000 65500net.core.rmem_default=262144net.core.rmem_max=4194304net.core.wmem_default=262144net.core.wmem_max=1048576fs.aio-max-nr=1048576

使修改的参数生效:

[root@rac1 ~]# sysctl -p

 

 

2.6.5 修改/etc/hosts文件(所有节点)

[root@rac1 ~]# cat/etc/hosts127.0.0.1 localhost192.168.56.5 rac1192.168.57.5 rac1-priv192.168.56.7 rac1-vip192.168.56.6 rac2192.168.57.6 rac2-priv192.168.56.8 rac2-vip192.168.56.9 rac-scan

3 安装Grid

 

在节点1,用grid用户运行runInstaller。

 

\

\

\

\

 

\

\

\

\

\

\

\

\

\

\

\

\

\

\

\

\

\

\

\

\

\

 

[root@rac1 /]# /u01/oraInventory/orainstRoot.shChanging permissions of /u01/oraInventory.Adding read,write permissions for group.Removing read,write,execute permissions forworld.Changing groupname of /u01/oraInventory tooinstall.The execution of the script is complete.[root@rac2 /]#/u01/oraInventory/orainstRoot.shChanging permissions of /u01/oraInventory.Adding read,write permissions for group.Removing read,write,execute permissions forworld.Changing groupname of /u01/oraInventory tooinstall.The execution of the script is complete.[root@rac2 /]#--节点1执行root.sh, 过程很长: 17分钟:[root@rac1 /]# /u01/gridsoft/12.1.0/root.shPerforming root user operation for Oracle12cThe following environment variables are setas:ORACLE_OWNER= gridORACLE_HOME= /u01/gridsoft/12.1.0Enter the full pathname of the local bindirectory: [/usr/local/bin]:Copying dbhome to /usr/local/bin ...Copying oraenv to /usr/local/bin ...Copying coraenv to /usr/local/bin ...Creating /etc/oratab file...Entries will be added to the /etc/oratabfile as needed byDatabase Configuration Assistant when adatabase is createdFinished running generic part of rootscript.Now product-specific root actions will beperformed.Using configuration parameter file: /u01/gridsoft/12.1.0/crs/install/crsconfig_params2014/08/07 02:42:37 CLSRSC-363: Userignored prerequisites during installationOLR initialization - successfulroot walletroot wallet certroot cert exportpeer walletprofile reader walletpawalletpeer wallet keyspawallet keyspeer cert requestpacert requestpeer certpacertpeer root cert TPprofile reader root cert TPparoot cert TPpeer pa cert TPpapeer cert TPprofile reader pa cert TPprofile reader peer cert TPpeer user certpauser cert2014/08/07 02:43:33 CLSRSC-330: AddingClusterware entries to file 'oracle-ohasd.conf'CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac1'CRS-2677: Stop of 'ora.drivers.acfs' on'rac1' succeededCRS-2672: Attempting to start 'ora.evmd' on'rac1'CRS-2672: Attempting to start 'ora.mdnsd'on 'rac1'CRS-2676: Start of 'ora.mdnsd' on 'rac1'succeededCRS-2676: Start of 'ora.evmd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac1'CRS-2676: Start of 'ora.gpnpd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cssdmonitor' on 'rac1'CRS-2672: Attempting to start 'ora.gipcd'on 'rac1'CRS-2676: Start of 'ora.cssdmonitor' on'rac1' succeededCRS-2676: Start of 'ora.gipcd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.cssd' on'rac1'CRS-2672: Attempting to start 'ora.diskmon'on 'rac1'CRS-2676: Start of 'ora.diskmon' on 'rac1'succeededCRS-2676: Start of 'ora.cssd' on 'rac1'succeededASM created and started successfully.Disk Group OCR_VOTING created successfully.CRS-2672: Attempting to start 'ora.crf' on'rac1'CRS-2672: Attempting to start 'ora.storage'on 'rac1'CRS-2676: Start of 'ora.storage' on 'rac1'succeededCRS-2676: Start of 'ora.crf' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crsd' on'rac1'CRS-2676: Start of 'ora.crsd' on 'rac1'succeededCRS-4256: Updating the profileSuccessful addition of voting diskf56b0e0be76b4f03bf4782230c783e67.Successfully replaced voting disk groupwith +OCR_VOTING.CRS-4256: Updating the profileCRS-4266: Voting file(s) successfullyreplaced## STATE File Universal Id File Name Disk group-- ----- ----------------- --------- ---------1.ONLINE f56b0e0be76b4f03bf4782230c783e67(/dev/asm-diske) [OCR_VOTING]Located 1 voting disk(s).CRS-2791: Starting shutdown of Oracle HighAvailability Services-managed resources on 'rac1'CRS-2673: Attempting to stop 'ora.crsd' on'rac1'CRS-2677: Stop of 'ora.crsd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.ctssd' on'rac1'CRS-2673: Attempting to stop 'ora.evmd' on'rac1'CRS-2673: Attempting to stop 'ora.storage'on 'rac1'CRS-2673: Attempting to stop 'ora.gpnpd' on'rac1'CRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac1'CRS-2673: Attempting to stop 'ora.mdnsd' on'rac1'CRS-2677: Stop of 'ora.storage' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.asm' on'rac1'CRS-2677: Stop of 'ora.drivers.acfs' on'rac1' succeededCRS-2677: Stop of 'ora.gpnpd' on 'rac1'succeededCRS-2677: Stop of 'ora.mdnsd' on 'rac1'succeededCRS-2677: Stop of 'ora.evmd' on 'rac1'succeededCRS-2677: Stop of 'ora.asm' on 'rac1'succeededCRS-2673: Attempting to stop'ora.cluster_interconnect.haip' on 'rac1'CRS-2677: Stop of 'ora.cluster_interconnect.haip'on 'rac1' succeededCRS-2677: Stop of 'ora.ctssd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.cssd' on'rac1'CRS-2677: Stop of 'ora.cssd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.crf' on'rac1'CRS-2677: Stop of 'ora.crf' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.gipcd' on'rac1'CRS-2677: Stop of 'ora.gipcd' on 'rac1'succeededCRS-2793: Shutdown of Oracle HighAvailability Services-managed resources on 'rac1' has completedCRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Starting Oracle High AvailabilityServices-managed resourcesCRS-2672: Attempting to start 'ora.mdnsd'on 'rac1'CRS-2672: Attempting to start 'ora.evmd' on'rac1'CRS-2676: Start of 'ora.mdnsd' on 'rac1'succeededCRS-2676: Start of 'ora.evmd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac1'CRS-2676: Start of 'ora.gpnpd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gipcd'on 'rac1'CRS-2676: Start of 'ora.gipcd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cssdmonitor' on 'rac1'CRS-2676: Start of 'ora.cssdmonitor' on'rac1' succeededCRS-2672: Attempting to start 'ora.cssd' on'rac1'CRS-2672: Attempting to start 'ora.diskmon'on 'rac1'CRS-2676: Start of 'ora.diskmon' on 'rac1'succeededCRS-2789: Cannot stop resource'ora.diskmon' as it is not running on server 'rac1'CRS-2676: Start of 'ora.cssd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cluster_interconnect.haip' on 'rac1'CRS-2672: Attempting to start 'ora.ctssd'on 'rac1'CRS-2676: Start of 'ora.ctssd' on 'rac1'succeededCRS-2676: Start of'ora.cluster_interconnect.haip' on 'rac1' succeededCRS-2672: Attempting to start 'ora.asm' on'rac1'CRS-2676: Start of 'ora.asm' on 'rac1'succeededCRS-2672: Attempting to start 'ora.storage'on 'rac1'CRS-2676: Start of 'ora.storage' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crf' on'rac1'CRS-2676: Start of 'ora.crf' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crsd' on'rac1'CRS-2676: Start of 'ora.crsd' on 'rac1'succeededCRS-6023: Starting Oracle Cluster ReadyServices-managed resourcesCRS-6017: Processing resource auto-startfor servers: rac1CRS-6016: Resource auto-start has completedfor server rac1CRS-6024: Completed start of Oracle ClusterReady Services-managed resourcesCRS-4123: Oracle High Availability Serviceshas been started.2014/08/07 02:52:25 CLSRSC-343:Successfully started Oracle clusterware stackCRS-2672: Attempting to start'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1'CRS-2676: Start of'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1' succeededCRS-2672: Attempting to start 'ora.asm' on'rac1'CRS-2676: Start of 'ora.asm' on 'rac1'succeededCRS-2672: Attempting to start'ora.OCR_VOTING.dg' on 'rac1'CRS-2676: Start of 'ora.OCR_VOTING.dg' on'rac1' succeededCRS-2791: Starting shutdown of Oracle HighAvailability Services-managed resources on 'rac1'CRS-2673: Attempting to stop 'ora.crsd' on'rac1'CRS-2790: Starting shutdown of ClusterReady Services-managed resources on 'rac1'CRS-2673: Attempting to stop'ora.LISTENER_SCAN1.lsnr' on 'rac1'CRS-2673: Attempting to stop'ora.OCR_VOTING.dg' on 'rac1'CRS-2673: Attempting to stop 'ora.rac1.vip'on 'rac1'CRS-2673: Attempting to stop 'ora.cvu' on'rac1'CRS-2673: Attempting to stop 'ora.oc4j' on'rac1'CRS-2677: Stop of 'ora.LISTENER_SCAN1.lsnr'on 'rac1' succeededCRS-2673: Attempting to stop'ora.scan1.vip' on 'rac1'CRS-2677: Stop of 'ora.cvu' on 'rac1'succeededCRS-2677: Stop of 'ora.rac1.vip' on 'rac1'succeededCRS-2677: Stop of 'ora.OCR_VOTING.dg' on'rac1' succeededCRS-2673: Attempting to stop 'ora.asm' on'rac1'CRS-2677: Stop of 'ora.scan1.vip' on 'rac1'succeededCRS-2677: Stop of 'ora.asm' on 'rac1'succeededCRS-2673: Attempting to stop'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1'CRS-2677: Stop of'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1' succeededCRS-2677: Stop of 'ora.oc4j' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.ons' on'rac1'CRS-2677: Stop of 'ora.ons' on 'rac1'succeededCRS-2673: Attempting to stop'ora.net1.network' on 'rac1'CRS-2677: Stop of 'ora.net1.network' on'rac1' succeededCRS-2792: Shutdown of Cluster ReadyServices-managed resources on 'rac1' has completedCRS-2677: Stop of 'ora.crsd' on 'rac1'succeededCRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac1'CRS-2673: Attempting to stop 'ora.ctssd' on'rac1'CRS-2673: Attempting to stop 'ora.evmd' on'rac1'CRS-2673: Attempting to stop 'ora.storage'on 'rac1'CRS-2673: Attempting to stop 'ora.gpnpd' on'rac1'CRS-2673: Attempting to stop 'ora.crf' on 'rac1'CRS-2673: Attempting to stop 'ora.mdnsd' on'rac1'CRS-2677: Stop of 'ora.drivers.acfs' on'rac1' succeededCRS-2677: Stop of 'ora.storage' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.asm' on'rac1'CRS-2677: Stop of 'ora.gpnpd' on 'rac1' succeededCRS-2677: Stop of 'ora.crf' on 'rac1'succeededCRS-2677: Stop of 'ora.mdnsd' on 'rac1'succeededCRS-2677: Stop of 'ora.evmd' on 'rac1'succeededCRS-2677: Stop of 'ora.ctssd' on 'rac1'succeededCRS-2677: Stop of 'ora.asm' on 'rac1'succeededCRS-2673: Attempting to stop'ora.cluster_interconnect.haip' on 'rac1'CRS-2677: Stop of'ora.cluster_interconnect.haip' on 'rac1' succeededCRS-2673: Attempting to stop 'ora.cssd' on'rac1'CRS-2677: Stop of 'ora.cssd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.gipcd' on'rac1'CRS-2677: Stop of 'ora.gipcd' on 'rac1'succeededCRS-2793: Shutdown of Oracle HighAvailability Services-managed resources on 'rac1' has completedCRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Starting Oracle High AvailabilityServices-managed resourcesCRS-2672: Attempting to start 'ora.mdnsd'on 'rac1'CRS-2672: Attempting to start 'ora.evmd' on'rac1'CRS-2676: Start of 'ora.mdnsd' on 'rac1'succeededCRS-2676: Start of 'ora.evmd' on 'rac1' succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac1'CRS-2676: Start of 'ora.gpnpd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gipcd'on 'rac1'CRS-2676: Start of 'ora.gipcd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.cssdmonitor'on 'rac1'CRS-2676: Start of 'ora.cssdmonitor' on'rac1' succeededCRS-2672: Attempting to start 'ora.cssd' on'rac1'CRS-2672: Attempting to start 'ora.diskmon'on 'rac1'CRS-2676: Start of 'ora.diskmon' on 'rac1'succeededCRS-2789: Cannot stop resource'ora.diskmon' as it is not running on server 'rac1'CRS-2676: Start of 'ora.cssd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cluster_interconnect.haip' on 'rac1'CRS-2672: Attempting to start 'ora.ctssd'on 'rac1'CRS-2676: Start of 'ora.ctssd' on 'rac1'succeededCRS-2676: Start of'ora.cluster_interconnect.haip' on 'rac1' succeededCRS-2672: Attempting to start 'ora.asm' on'rac1'CRS-2676: Start of 'ora.asm' on 'rac1'succeededCRS-2672: Attempting to start 'ora.storage'on 'rac1'CRS-2676: Start of 'ora.storage' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crf' on'rac1'CRS-2676: Start of 'ora.crf' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crsd' on'rac1'CRS-2676: Start of 'ora.crsd' on 'rac1'succeededCRS-6023: Starting Oracle Cluster ReadyServices-managed resourcesCRS-6017: Processing resource auto-startfor servers: rac1CRS-2672: Attempting to start'ora.scan1.vip' on 'rac1'CRS-2672: Attempting to start 'ora.oc4j' on'rac1'CRS-2672: Attempting to start 'ora.ons' on'rac1'CRS-2672: Attempting to start'ora.rac1.vip' on 'rac1'CRS-2672: Attempting to start 'ora.cvu' on'rac1'CRS-2676: Start of 'ora.cvu' on 'rac1'succeededCRS-2676: Start of 'ora.scan1.vip' on'rac1' succeededCRS-2672: Attempting to start'ora.LISTENER_SCAN1.lsnr' on 'rac1'CRS-2676: Start of 'ora.rac1.vip' on 'rac1'succeededCRS-2676: Start of 'ora.ons' on 'rac1'succeededCRS-2676: Start of'ora.LISTENER_SCAN1.lsnr' on 'rac1' succeededCRS-2676: Start of 'ora.oc4j' on 'rac1' succeededCRS-6016: Resource auto-start has completedfor server rac1CRS-6024: Completed start of Oracle ClusterReady Services-managed resourcesCRS-4123: Oracle High Availability Serviceshas been started.2014/08/07 02:59:19 CLSRSC-325: ConfigureOracle Grid Infrastructure for a Cluster ... succeeded[root@rac1 /]#节点2执行:[root@rac2 /]# /u01/gridsoft/12.1.0/root.shPerforming root user operation for Oracle12cThe following environment variables are setas:ORACLE_OWNER= gridORACLE_HOME= /u01/gridsoft/12.1.0Enter the full pathname of the local bindirectory: [/usr/local/bin]:Copying dbhome to /usr/local/bin ...Copying oraenv to /usr/local/bin ...Copying coraenv to /usr/local/bin ...Creating /etc/oratab file...Entries will be added to the /etc/oratabfile as needed byDatabase Configuration Assistant when adatabase is createdFinished running generic part of rootscript.Now product-specific root actions will beperformed.Using configuration parameter file:/u01/gridsoft/12.1.0/crs/install/crsconfig_params2014/08/07 03:03:51 CLSRSC-363: Userignored prerequisites during installationOLR initialization - successful2014/08/07 03:04:15 CLSRSC-330: AddingClusterware entries to file 'oracle-ohasd.conf'CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-2791: Starting shutdown of Oracle HighAvailability Services-managed resources on 'rac2'CRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac2'CRS-2677: Stop of 'ora.drivers.acfs' on'rac2' succeededCRS-2793: Shutdown of Oracle HighAvailability Services-managed resources on 'rac2' has completedCRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Starting Oracle High AvailabilityServices-managed resourcesCRS-2672: Attempting to start 'ora.mdnsd'on 'rac2'CRS-2672: Attempting to start 'ora.evmd' on'rac2'CRS-2676: Start of 'ora.mdnsd' on 'rac2'succeededCRS-2676: Start of 'ora.evmd' on 'rac2'succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac2'CRS-2676: Start of 'ora.gpnpd' on 'rac2'succeededCRS-2672: Attempting to start 'ora.gipcd'on 'rac2'CRS-2676: Start of 'ora.gipcd' on 'rac2'succeededCRS-2672: Attempting to start'ora.cssdmonitor' on 'rac2'CRS-2676: Start of 'ora.cssdmonitor' on'rac2' succeededCRS-2672: Attempting to start 'ora.cssd' on'rac2'CRS-2672: Attempting to start 'ora.diskmon'on 'rac2'CRS-2676: Start of 'ora.diskmon' on 'rac2'succeededCRS-2789: Cannot stop resource'ora.diskmon' as it is not running on server 'rac2'CRS-2676: Start of 'ora.cssd' on 'rac2'succeededCRS-2672: Attempting to start 'ora.cluster_interconnect.haip'on 'rac2'CRS-2672: Attempting to start 'ora.ctssd'on 'rac2'CRS-2676: Start of 'ora.ctssd' on 'rac2'succeededCRS-2676: Start of'ora.cluster_interconnect.haip' on 'rac2' succeededCRS-2672: Attempting to start 'ora.asm' on'rac2'CRS-2676: Start of 'ora.asm' on 'rac2'succeededCRS-2672: Attempting to start 'ora.storage'on 'rac2'CRS-2676: Start of 'ora.storage' on 'rac2'succeededCRS-2672: Attempting to start 'ora.crf' on'rac2'CRS-2676: Start of 'ora.crf' on 'rac2' succeededCRS-2672: Attempting to start 'ora.crsd' on'rac2'CRS-2676: Start of 'ora.crsd' on 'rac2'succeededCRS-6017: Processing resource auto-startfor servers: rac2CRS-2672: Attempting to start'ora.ASMNET1LSNR_ASM.lsnr' on 'rac2'CRS-2672: Attempting to start 'ora.ons' on'rac2'CRS-2676: Start of 'ora.ons' on 'rac2'succeededCRS-2676: Start of'ora.ASMNET1LSNR_ASM.lsnr' on 'rac2' succeededCRS-2672: Attempting to start 'ora.asm' on'rac2'CRS-2676: Start of 'ora.asm' on 'rac2'succeededCRS-2672: Attempting to start'ora.proxy_advm' on 'rac2'CRS-2676: Start of 'ora.proxy_advm' on'rac2' succeededCRS-6016: Resource auto-start has completedfor server rac2CRS-6024: Completed start of Oracle ClusterReady Services-managed resourcesCRS-4123: Oracle High Availability Serviceshas been started.2014/08/07 03:07:42 CLSRSC-343:Successfully started Oracle clusterware stack2014/08/07 03:08:02 CLSRSC-325: ConfigureOracle Grid Infrastructure for a Cluster ... succeeded[root@rac2 /]#

\

\

\

\

 

至此,GRID 安装完成。

[grid@rac1 ~]$ crs_stat -tName Type Target State Host------------------------------------------------------------ora....SM.lsnr ora....er.type ONLINE ONLINE rac1ora....ER.lsnr ora....er.type ONLINE ONLINE rac1ora....N1.lsnr ora....er.type ONLINE ONLINE rac1ora.MGMTLSNR ora....nr.type ONLINE ONLINE rac1ora....TING.dg ora....up.type ONLINE ONLINE rac1ora.asm ora.asm.type ONLINE ONLINE rac1ora.cvu ora.cvu.type ONLINE ONLINE rac1ora.mgmtdb ora....db.type ONLINE ONLINE rac1ora....network ora....rk.type ONLINE ONLINE rac1ora.oc4j ora.oc4j.type ONLINE ONLINE rac1ora.ons ora.ons.type ONLINE ONLINE rac1ora.proxy_advm ora....vm.type ONLINE ONLINE rac1ora....C1.lsnr application ONLINE ONLINE rac1ora.rac1.ons application ONLINE ONLINE rac1ora.rac1.vip ora....t1.type ONLINE ONLINE rac1ora....C2.lsnr application ONLINE ONLINE rac2ora.rac2.ons application ONLINE ONLINE rac2ora.rac2.vip ora....t1.type ONLINE ONLINE rac2ora.scan1.vip ora....ip.type ONLINE ONLINE rac1[grid@rac1 ~]$[grid@rac1 ~]$ crsctl stat res -t--------------------------------------------------------------------------------Name Target State Server Statedetails--------------------------------------------------------------------------------Local Resources--------------------------------------------------------------------------------ora.ASMNET1LSNR_ASM.lsnrONLINE ONLINE rac1 STABLEONLINE ONLINE rac2 STABLEora.LISTENER.lsnrONLINE ONLINE rac1 STABLEONLINE ONLINE rac2 STABLEora.OCR_VOTING.dgONLINE ONLINE rac1 STABLEONLINE ONLINE rac2 STABLEora.net1.networkONLINE ONLINE rac1 STABLEONLINE ONLINE rac2 STABLEora.onsONLINE ONLINE rac1 STABLEONLINE ONLINE rac2 STABLEora.proxy_advmONLINE ONLINE rac1 STABLEONLINE ONLINE rac2 STABLE--------------------------------------------------------------------------------Cluster Resources--------------------------------------------------------------------------------ora.LISTENER_SCAN1.lsnr1 ONLINE ONLINE rac1 STABLEora.MGMTLSNR1 ONLINE ONLINE rac1 169.254.203.88192.168.57.5,STABLEora.asm1 ONLINE ONLINE rac1 STABLE2 ONLINE ONLINE rac2 STABLE3 OFFLINE OFFLINE STABLEora.cvu1 ONLINE ONLINE rac1 STABLEora.mgmtdb1 ONLINE ONLINE rac1 Open,STABLEora.oc4j1 ONLINE ONLINE rac1 STABLEora.rac1.vip1 ONLINE ONLINE rac1 STABLEora.rac2.vip1 ONLINE ONLINE rac2 STABLEora.scan1.vip1 ONLINE ONLINE rac1 STABLE--------------------------------------------------------------------------------[grid@rac1 ~]$

4 安装DB软件

 

在节点1,用oracle 用户运行runInstaller程序。

 

 

\

\

\

\

\

\

\

\

加载中...

\

\

[root@rac1 /]# /u01/oraInventory/orainstRoot.shChanging permissions of /u01/oraInventory.Adding read,write permissions for group.Removing read,write,execute permissions forworld.Changing groupname of /u01/oraInventory tooinstall.The execution of the script is complete.[root@rac2 /]#/u01/oraInventory/orainstRoot.shChanging permissions of /u01/oraInventory.Adding read,write permissions for group.Removing read,write,execute permissions forworld.Changing groupname of /u01/oraInventory tooinstall.The execution of the script is complete.[root@rac2 /]#--节点1执行root.sh, 过程很长: 17分钟:[root@rac1 /]# /u01/gridsoft/12.1.0/root.shPerforming root user operation for Oracle12cThe following environment variables are setas:ORACLE_OWNER= gridORACLE_HOME= /u01/gridsoft/12.1.0Enter the full pathname of the local bindirectory: [/usr/local/bin]:Copying dbhome to /usr/local/bin ...Copying oraenv to /usr/local/bin ...Copying coraenv to /usr/local/bin ...Creating /etc/oratab file...Entries will be added to the /etc/oratabfile as needed byDatabase Configuration Assistant when adatabase is createdFinished running generic part of rootscript.Now product-specific root actions will beperformed.Using configuration parameter file: /u01/gridsoft/12.1.0/crs/install/crsconfig_params2014/08/07 02:42:37 CLSRSC-363: Userignored prerequisites during installationOLR initialization - successfulroot walletroot wallet certroot cert exportpeer walletprofile reader walletpawalletpeer wallet keyspawallet keyspeer cert requestpacert requestpeer certpacertpeer root cert TPprofile reader root cert TPparoot cert TPpeer pa cert TPpapeer cert TPprofile reader pa cert TPprofile reader peer cert TPpeer user certpauser cert2014/08/07 02:43:33 CLSRSC-330: AddingClusterware entries to file 'oracle-ohasd.conf'CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac1'CRS-2677: Stop of 'ora.drivers.acfs' on'rac1' succeededCRS-2672: Attempting to start 'ora.evmd' on'rac1'CRS-2672: Attempting to start 'ora.mdnsd'on 'rac1'CRS-2676: Start of 'ora.mdnsd' on 'rac1'succeededCRS-2676: Start of 'ora.evmd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac1'CRS-2676: Start of 'ora.gpnpd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cssdmonitor' on 'rac1'CRS-2672: Attempting to start 'ora.gipcd'on 'rac1'CRS-2676: Start of 'ora.cssdmonitor' on'rac1' succeededCRS-2676: Start of 'ora.gipcd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.cssd' on'rac1'CRS-2672: Attempting to start 'ora.diskmon'on 'rac1'CRS-2676: Start of 'ora.diskmon' on 'rac1'succeededCRS-2676: Start of 'ora.cssd' on 'rac1'succeededASM created and started successfully.Disk Group OCR_VOTING created successfully.CRS-2672: Attempting to start 'ora.crf' on'rac1'CRS-2672: Attempting to start 'ora.storage'on 'rac1'CRS-2676: Start of 'ora.storage' on 'rac1'succeededCRS-2676: Start of 'ora.crf' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crsd' on'rac1'CRS-2676: Start of 'ora.crsd' on 'rac1'succeededCRS-4256: Updating the profileSuccessful addition of voting diskf56b0e0be76b4f03bf4782230c783e67.Successfully replaced voting disk groupwith +OCR_VOTING.CRS-4256: Updating the profileCRS-4266: Voting file(s) successfullyreplaced## STATE File Universal Id File Name Disk group-- ----- ----------------- --------- ---------1.ONLINE f56b0e0be76b4f03bf4782230c783e67(/dev/asm-diske) [OCR_VOTING]Located 1 voting disk(s).CRS-2791: Starting shutdown of Oracle HighAvailability Services-managed resources on 'rac1'CRS-2673: Attempting to stop 'ora.crsd' on'rac1'CRS-2677: Stop of 'ora.crsd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.ctssd' on'rac1'CRS-2673: Attempting to stop 'ora.evmd' on'rac1'CRS-2673: Attempting to stop 'ora.storage'on 'rac1'CRS-2673: Attempting to stop 'ora.gpnpd' on'rac1'CRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac1'CRS-2673: Attempting to stop 'ora.mdnsd' on'rac1'CRS-2677: Stop of 'ora.storage' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.asm' on'rac1'CRS-2677: Stop of 'ora.drivers.acfs' on'rac1' succeededCRS-2677: Stop of 'ora.gpnpd' on 'rac1'succeededCRS-2677: Stop of 'ora.mdnsd' on 'rac1'succeededCRS-2677: Stop of 'ora.evmd' on 'rac1'succeededCRS-2677: Stop of 'ora.asm' on 'rac1'succeededCRS-2673: Attempting to stop'ora.cluster_interconnect.haip' on 'rac1'CRS-2677: Stop of 'ora.cluster_interconnect.haip'on 'rac1' succeededCRS-2677: Stop of 'ora.ctssd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.cssd' on'rac1'CRS-2677: Stop of 'ora.cssd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.crf' on'rac1'CRS-2677: Stop of 'ora.crf' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.gipcd' on'rac1'CRS-2677: Stop of 'ora.gipcd' on 'rac1'succeededCRS-2793: Shutdown of Oracle HighAvailability Services-managed resources on 'rac1' has completedCRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Starting Oracle High AvailabilityServices-managed resourcesCRS-2672: Attempting to start 'ora.mdnsd'on 'rac1'CRS-2672: Attempting to start 'ora.evmd' on'rac1'CRS-2676: Start of 'ora.mdnsd' on 'rac1'succeededCRS-2676: Start of 'ora.evmd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac1'CRS-2676: Start of 'ora.gpnpd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gipcd'on 'rac1'CRS-2676: Start of 'ora.gipcd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cssdmonitor' on 'rac1'CRS-2676: Start of 'ora.cssdmonitor' on'rac1' succeededCRS-2672: Attempting to start 'ora.cssd' on'rac1'CRS-2672: Attempting to start 'ora.diskmon'on 'rac1'CRS-2676: Start of 'ora.diskmon' on 'rac1'succeededCRS-2789: Cannot stop resource'ora.diskmon' as it is not running on server 'rac1'CRS-2676: Start of 'ora.cssd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cluster_interconnect.haip' on 'rac1'CRS-2672: Attempting to start 'ora.ctssd'on 'rac1'CRS-2676: Start of 'ora.ctssd' on 'rac1'succeededCRS-2676: Start of'ora.cluster_interconnect.haip' on 'rac1' succeededCRS-2672: Attempting to start 'ora.asm' on'rac1'CRS-2676: Start of 'ora.asm' on 'rac1'succeededCRS-2672: Attempting to start 'ora.storage'on 'rac1'CRS-2676: Start of 'ora.storage' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crf' on'rac1'CRS-2676: Start of 'ora.crf' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crsd' on'rac1'CRS-2676: Start of 'ora.crsd' on 'rac1'succeededCRS-6023: Starting Oracle Cluster ReadyServices-managed resourcesCRS-6017: Processing resource auto-startfor servers: rac1CRS-6016: Resource auto-start has completedfor server rac1CRS-6024: Completed start of Oracle ClusterReady Services-managed resourcesCRS-4123: Oracle High Availability Serviceshas been started.2014/08/07 02:52:25 CLSRSC-343:Successfully started Oracle clusterware stackCRS-2672: Attempting to start'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1'CRS-2676: Start of'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1' succeededCRS-2672: Attempting to start 'ora.asm' on'rac1'CRS-2676: Start of 'ora.asm' on 'rac1'succeededCRS-2672: Attempting to start'ora.OCR_VOTING.dg' on 'rac1'CRS-2676: Start of 'ora.OCR_VOTING.dg' on'rac1' succeededCRS-2791: Starting shutdown of Oracle HighAvailability Services-managed resources on 'rac1'CRS-2673: Attempting to stop 'ora.crsd' on'rac1'CRS-2790: Starting shutdown of ClusterReady Services-managed resources on 'rac1'CRS-2673: Attempting to stop'ora.LISTENER_SCAN1.lsnr' on 'rac1'CRS-2673: Attempting to stop'ora.OCR_VOTING.dg' on 'rac1'CRS-2673: Attempting to stop 'ora.rac1.vip'on 'rac1'CRS-2673: Attempting to stop 'ora.cvu' on'rac1'CRS-2673: Attempting to stop 'ora.oc4j' on'rac1'CRS-2677: Stop of 'ora.LISTENER_SCAN1.lsnr'on 'rac1' succeededCRS-2673: Attempting to stop'ora.scan1.vip' on 'rac1'CRS-2677: Stop of 'ora.cvu' on 'rac1'succeededCRS-2677: Stop of 'ora.rac1.vip' on 'rac1'succeededCRS-2677: Stop of 'ora.OCR_VOTING.dg' on'rac1' succeededCRS-2673: Attempting to stop 'ora.asm' on'rac1'CRS-2677: Stop of 'ora.scan1.vip' on 'rac1'succeededCRS-2677: Stop of 'ora.asm' on 'rac1'succeededCRS-2673: Attempting to stop'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1'CRS-2677: Stop of'ora.ASMNET1LSNR_ASM.lsnr' on 'rac1' succeededCRS-2677: Stop of 'ora.oc4j' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.ons' on'rac1'CRS-2677: Stop of 'ora.ons' on 'rac1'succeededCRS-2673: Attempting to stop'ora.net1.network' on 'rac1'CRS-2677: Stop of 'ora.net1.network' on'rac1' succeededCRS-2792: Shutdown of Cluster ReadyServices-managed resources on 'rac1' has completedCRS-2677: Stop of 'ora.crsd' on 'rac1'succeededCRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac1'CRS-2673: Attempting to stop 'ora.ctssd' on'rac1'CRS-2673: Attempting to stop 'ora.evmd' on'rac1'CRS-2673: Attempting to stop 'ora.storage'on 'rac1'CRS-2673: Attempting to stop 'ora.gpnpd' on'rac1'CRS-2673: Attempting to stop 'ora.crf' on 'rac1'CRS-2673: Attempting to stop 'ora.mdnsd' on'rac1'CRS-2677: Stop of 'ora.drivers.acfs' on'rac1' succeededCRS-2677: Stop of 'ora.storage' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.asm' on'rac1'CRS-2677: Stop of 'ora.gpnpd' on 'rac1' succeededCRS-2677: Stop of 'ora.crf' on 'rac1'succeededCRS-2677: Stop of 'ora.mdnsd' on 'rac1'succeededCRS-2677: Stop of 'ora.evmd' on 'rac1'succeededCRS-2677: Stop of 'ora.ctssd' on 'rac1'succeededCRS-2677: Stop of 'ora.asm' on 'rac1'succeededCRS-2673: Attempting to stop'ora.cluster_interconnect.haip' on 'rac1'CRS-2677: Stop of'ora.cluster_interconnect.haip' on 'rac1' succeededCRS-2673: Attempting to stop 'ora.cssd' on'rac1'CRS-2677: Stop of 'ora.cssd' on 'rac1'succeededCRS-2673: Attempting to stop 'ora.gipcd' on'rac1'CRS-2677: Stop of 'ora.gipcd' on 'rac1'succeededCRS-2793: Shutdown of Oracle HighAvailability Services-managed resources on 'rac1' has completedCRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Starting Oracle High AvailabilityServices-managed resourcesCRS-2672: Attempting to start 'ora.mdnsd'on 'rac1'CRS-2672: Attempting to start 'ora.evmd' on'rac1'CRS-2676: Start of 'ora.mdnsd' on 'rac1'succeededCRS-2676: Start of 'ora.evmd' on 'rac1' succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac1'CRS-2676: Start of 'ora.gpnpd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.gipcd'on 'rac1'CRS-2676: Start of 'ora.gipcd' on 'rac1'succeededCRS-2672: Attempting to start 'ora.cssdmonitor'on 'rac1'CRS-2676: Start of 'ora.cssdmonitor' on'rac1' succeededCRS-2672: Attempting to start 'ora.cssd' on'rac1'CRS-2672: Attempting to start 'ora.diskmon'on 'rac1'CRS-2676: Start of 'ora.diskmon' on 'rac1'succeededCRS-2789: Cannot stop resource'ora.diskmon' as it is not running on server 'rac1'CRS-2676: Start of 'ora.cssd' on 'rac1'succeededCRS-2672: Attempting to start'ora.cluster_interconnect.haip' on 'rac1'CRS-2672: Attempting to start 'ora.ctssd'on 'rac1'CRS-2676: Start of 'ora.ctssd' on 'rac1'succeededCRS-2676: Start of'ora.cluster_interconnect.haip' on 'rac1' succeededCRS-2672: Attempting to start 'ora.asm' on'rac1'CRS-2676: Start of 'ora.asm' on 'rac1'succeededCRS-2672: Attempting to start 'ora.storage'on 'rac1'CRS-2676: Start of 'ora.storage' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crf' on'rac1'CRS-2676: Start of 'ora.crf' on 'rac1'succeededCRS-2672: Attempting to start 'ora.crsd' on'rac1'CRS-2676: Start of 'ora.crsd' on 'rac1'succeededCRS-6023: Starting Oracle Cluster ReadyServices-managed resourcesCRS-6017: Processing resource auto-startfor servers: rac1CRS-2672: Attempting to start'ora.scan1.vip' on 'rac1'CRS-2672: Attempting to start 'ora.oc4j' on'rac1'CRS-2672: Attempting to start 'ora.ons' on'rac1'CRS-2672: Attempting to start'ora.rac1.vip' on 'rac1'CRS-2672: Attempting to start 'ora.cvu' on'rac1'CRS-2676: Start of 'ora.cvu' on 'rac1'succeededCRS-2676: Start of 'ora.scan1.vip' on'rac1' succeededCRS-2672: Attempting to start'ora.LISTENER_SCAN1.lsnr' on 'rac1'CRS-2676: Start of 'ora.rac1.vip' on 'rac1'succeededCRS-2676: Start of 'ora.ons' on 'rac1'succeededCRS-2676: Start of'ora.LISTENER_SCAN1.lsnr' on 'rac1' succeededCRS-2676: Start of 'ora.oc4j' on 'rac1' succeededCRS-6016: Resource auto-start has completedfor server rac1CRS-6024: Completed start of Oracle ClusterReady Services-managed resourcesCRS-4123: Oracle High Availability Serviceshas been started.2014/08/07 02:59:19 CLSRSC-325: ConfigureOracle Grid Infrastructure for a Cluster ... succeeded[root@rac1 /]#节点2执行:[root@rac2 /]# /u01/gridsoft/12.1.0/root.shPerforming root user operation for Oracle12cThe following environment variables are setas:ORACLE_OWNER= gridORACLE_HOME= /u01/gridsoft/12.1.0Enter the full pathname of the local bindirectory: [/usr/local/bin]:Copying dbhome to /usr/local/bin ...Copying oraenv to /usr/local/bin ...Copying coraenv to /usr/local/bin ...Creating /etc/oratab file...Entries will be added to the /etc/oratabfile as needed byDatabase Configuration Assistant when adatabase is createdFinished running generic part of rootscript.Now product-specific root actions will beperformed.Using configuration parameter file:/u01/gridsoft/12.1.0/crs/install/crsconfig_params2014/08/07 03:03:51 CLSRSC-363: Userignored prerequisites during installationOLR initialization - successful2014/08/07 03:04:15 CLSRSC-330: AddingClusterware entries to file 'oracle-ohasd.conf'CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Oracle High Availability Serviceshas been started.CRS-2791: Starting shutdown of Oracle HighAvailability Services-managed resources on 'rac2'CRS-2673: Attempting to stop'ora.drivers.acfs' on 'rac2'CRS-2677: Stop of 'ora.drivers.acfs' on'rac2' succeededCRS-2793: Shutdown of Oracle HighAvailability Services-managed resources on 'rac2' has completedCRS-4133: Oracle High Availability Serviceshas been stopped.CRS-4123: Starting Oracle High AvailabilityServices-managed resourcesCRS-2672: Attempting to start 'ora.mdnsd'on 'rac2'CRS-2672: Attempting to start 'ora.evmd' on'rac2'CRS-2676: Start of 'ora.mdnsd' on 'rac2'succeededCRS-2676: Start of 'ora.evmd' on 'rac2'succeededCRS-2672: Attempting to start 'ora.gpnpd'on 'rac2'CRS-2676: Start of 'ora.gpnpd' on 'rac2'succeededCRS-2672: Attempting to start 'ora.gipcd'on 'rac2'CRS-2676: Start of 'ora.gipcd' on 'rac2'succeededCRS-2672: Attempting to start'ora.cssdmonitor' on 'rac2'CRS-2676: Start of 'ora.cssdmonitor' on'rac2' succeededCRS-2672: Attempting to start 'ora.cssd' on'rac2'CRS-2672: Attempting to start 'ora.diskmon'on 'rac2'CRS-2676: Start of 'ora.diskmon' on 'rac2'succeededCRS-2789: Cannot stop resource'ora.diskmon' as it is not running on server 'rac2'CRS-2676: Start of 'ora.cssd' on 'rac2'succeededCRS-2672: Attempting to start 'ora.cluster_interconnect.haip'on 'rac2'CRS-2672: Attempting to start 'ora.ctssd'on 'rac2'CRS-2676: Start of 'ora.ctssd' on 'rac2'succeededCRS-2676: Start of'ora.cluster_interconnect.haip' on 'rac2' succeededCRS-2672: Attempting to start 'ora.asm' on'rac2'CRS-2676: Start of 'ora.asm' on 'rac2'succeededCRS-2672: Attempting to start 'ora.storage'on 'rac2'CRS-2676: Start of 'ora.storage' on 'rac2'succeededCRS-2672: Attempting to start 'ora.crf' on'rac2'CRS-2676: Start of 'ora.crf' on 'rac2' succeededCRS-2672: Attempting to start 'ora.crsd' on'rac2'CRS-2676: Start of 'ora.crsd' on 'rac2'succeededCRS-6017: Processing resource auto-startfor servers: rac2CRS-2672: Attempting to start'ora.ASMNET1LSNR_ASM.lsnr' on 'rac2'CRS-2672: Attempting to start 'ora.ons' on'rac2'CRS-2676: Start of 'ora.ons' on 'rac2'succeededCRS-2676: Start of'ora.ASMNET1LSNR_ASM.lsnr' on 'rac2' succeededCRS-2672: Attempting to start 'ora.asm' on'rac2'CRS-2676: Start of 'ora.asm' on 'rac2'succeededCRS-2672: Attempting to start'ora.proxy_advm' on 'rac2'CRS-2676: Start of 'ora.proxy_advm' on'rac2' succeededCRS-6016: Resource auto-start has completedfor server rac2CRS-6024: Completed start of Oracle ClusterReady Services-managed resourcesCRS-4123: Oracle High Availability Serviceshas been started.2014/08/07 03:07:42 CLSRSC-343:Successfully started Oracle clusterware stack2014/08/07 03:08:02 CLSRSC-325: ConfigureOracle Grid Infrastructure for a Cluster ... succeeded[root@rac2 /]#[root@rac1 software]#/u01/oracle/12.1.0/db_1/root.shPerforming root user operation for Oracle12cThe following environment variables are setas:ORACLE_OWNER= oracleORACLE_HOME= /u01/oracle/12.1.0/db_1Enter the full pathname of the local bindirectory: [/usr/local/bin]:The contents of "dbhome" have notchanged. No need to overwrite.The contents of "oraenv" have notchanged. No need to overwrite.The contents of "coraenv" havenot changed. No need to overwrite.Entries will be added to the /etc/oratabfile as needed byDatabase Configuration Assistant when adatabase is createdFinished running generic part of rootscript.Now product-specific root actions will beperformed.[root@rac2 /]#/u01/oracle/12.1.0/db_1/root.shPerforming root user operation for Oracle12cThe following environment variables are setas:ORACLE_OWNER= oracleORACLE_HOME= /u01/oracle/12.1.0/db_1Enter the full pathname of the local bindirectory: [/usr/local/bin]:The contents of "dbhome" have notchanged. No need to overwrite.The contents of "oraenv" have notchanged. No need to overwrite.The contents of "coraenv" havenot changed. No need to overwrite.Entries will be added to the /etc/oratabfile as needed byDatabase Configuration Assistant when adatabase is createdFinished running generic part of rootscript.Now product-specific root actions will beperformed.[root@rac2 /]#

\

 

5 创建ASM 磁盘组

 

在节点1上用grid用户执行asmca命令。

 

\

\

\

6 创建实例

 

在节点1用oracle 用户执行dbca:

 

\

\

\

\

\

\

 

[grid@rac1 ~]$ crs_stat -tName Type Target State Host------------------------------------------------------------ora....SM.lsnr ora....er.type ONLINE ONLINE rac1ora.DATA.dg ora....up.type ONLINE ONLINE rac1ora....ER.lsnr ora....er.type ONLINE ONLINE rac1ora....N1.lsnr ora....er.type ONLINE ONLINE rac1ora.MGMTLSNR ora....nr.type ONLINE ONLINE rac1ora....TING.dg ora....up.type ONLINE ONLINE rac1ora.asm ora.asm.type ONLINE ONLINE rac1ora.cndba.db ora....se.type ONLINE ONLINE rac1ora.cvu ora.cvu.type ONLINE ONLINE rac1ora.mgmtdb ora....db.type ONLINE ONLINE rac1ora....network ora....rk.type ONLINE ONLINE rac1ora.oc4j ora.oc4j.type ONLINE ONLINE rac1ora.ons ora.ons.type ONLINE ONLINE rac1ora.proxy_advm ora....vm.type ONLINE ONLINE rac1ora....C1.lsnr application ONLINE ONLINE rac1ora.rac1.ons application ONLINE ONLINE rac1ora.rac1.vip ora....t1.type ONLINE ONLINE rac1ora....C2.lsnr application ONLINE ONLINE rac2ora.rac2.ons application ONLINE ONLINE rac2ora.rac2.vip ora....t1.type ONLINE ONLINE rac2ora.scan1.vip ora....ip.type ONLINE ONLINE rac1[oracle@rac1 ~]$ sqlplus / as sysdbaSQL*Plus: Release 12.1.0.1.0 Production onThu Aug 7 06:27:23 2014Copyright (c) 1982, 2013, Oracle. All rights reserved.Connected to:Oracle Database 12c Enterprise EditionRelease 12.1.0.1.0 - 64bit ProductionWith the Partitioning, Real ApplicationClusters, Automatic Storage Management, OLAP,Advanced Analytics and Real ApplicationTesting optionsSQL>SQL> show pdbsCON_ID CON_NAME OPEN MODE RESTRICTED---------- ---------------------------------------- ----------2 PDB$SEED READ ONLY NO3 DAVE READ WRITE NOSQL> select instance_name,status from gv$instance;INSTANCE_NAME STATUS---------------- ------------cndba1 OPENcndba2 OPEN