linux7静默安装11GR2 RAC的方法是什么

发布时间:2021-11-09 11:23:09 作者:iii
来源:亿速云 阅读:142

这篇文章主要介绍“linux7静默安装11GR2 RAC的方法是什么”,在日常操作中,相信很多人在linux7静默安装11GR2 RAC的方法是什么问题上存在疑惑,小编查阅了各式资料,整理出简单好用的操作方法,希望对大家解答”linux7静默安装11GR2 RAC的方法是什么”的疑惑有所帮助!接下来,请跟着小编一起来学习吧!

vi /etc/hosts
#public ip
192.168.56.71 ora71
192.168.56.72 ora72
#private ip
192.168.221.71 ora71-priv
192.168.221.72 ora72-priv
#vip
192.168.56.73 ora71-vip
192.168.56.74 ora72-vip
#scan ip
192.168.56.75 orascan
[root@ora71 ~]# systemctl stop firewalld
[root@ora71 ~]# systemctl disable firewalld
Removed symlink /etc/systemd/system/multi-user.target.wants/firewalld.service.
Removed symlink /etc/systemd/system/dbus-org.fedoraproject.FirewallD1.service.
[root@ora71 ~]# setenforce 0
[root@ora71 ~]# sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
[root@ora71 ~]# getenforce
Permissive
[root@ora72 ~]# egrep -v "^#|^$" /etc/selinux/config
SELINUX=disabled
SELINUXTYPE=targeted
[root@ora71 ~]# vi /etc/sysctl.conf
fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmmni = 4096
kernel.shmall =18446744073692774399
kernel.shmmax =18446744073692774399
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576
[root@ora71 ~]# vi /etc/security/limits.conf
grid soft nproc 2047
grid hard nproc 16384
grid soft nofile 1024
grid hard nofile 65536
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
[root@ora71 ~]# vi /etc/pam.d/login
session required /lib64/security/pam_limits.so
session required pam_limits.so
groupadd -g 1000 oinstall
groupadd -g 1001 dba
groupadd -g 1002 oper
groupadd -g 1003 asmadmin
groupadd -g 1004 asmoper
groupadd -g 1005 asmdba
useradd -u 1000 -g oinstall -G dba,asmdba,oper oracle
useradd -u 1001 -g oinstall -G asmadmin,asmdba,asmoper,oper,dba grid
mkdir -p /u01/app/grid
mkdir -p /u01/app/gridhome
mkdir -p /u01/app/oracle
chown -R grid:oinstall /u01/app/grid
chmod -R 755 /u01/app/grid
chown -R grid:oinstall /u01/app/gridhome
chmod -R 755 /u01/app/gridhome
chown -R oracle:oinstall /u01/app/oracle
chmod -R 755 /u01/app/oracle

#编辑参数文件

grid:
vi ~/.bash_profile
export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/gridhome/product/11.2.0/grid_1
export ORACLE_SID=+ASM1
PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/usr/local/bin
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/gridhome/product/11.2.0/grid_1
export ORACLE_SID=+ASM2
PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/usr/local/bin
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
oracle
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1
export ORACLE_SID=RACDB1
PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/usr/local/bin
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1
export ORACLE_SID=RACDB2
PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/usr/local/bin
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib

#配置ssh信任

grid:
cd /home/grid
mkdir ~/.ssh
chmod 700 ~/.ssh
ssh-keygen -t rsa
ssh-keygen -t dsa
cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
ssh ora72 cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
ssh ora72 cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
scp ~/.ssh/authorized_keys ora72:~/.ssh/authorized_keys
#验证
ssh ora72 date;ssh ora71 date;ssh ora72-priv date;ssh ora71-priv date
oracle
cd /home/grid
mkdir ~/.ssh
chmod 700 ~/.ssh
ssh-keygen -t rsa
ssh-keygen -t dsa
cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
ssh ora72 cat ~/.ssh/id_rsa.pub >>~/.ssh/authorized_keys
ssh ora72 cat ~/.ssh/id_dsa.pub >>~/.ssh/authorized_keys
scp ~/.ssh/authorized_keys ora72:~/.ssh/authorized_keys
#验证
ssh ora72 date;ssh ora71 date;ssh ora72-priv date;ssh ora71-priv date
yum -y install binutils compat-libstdc++-33* compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel elfutils-libelf-devel-static gcc gcc-c++ glibc* kernel-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libgomp libstdc++* libstdc++.i686 make sysstat unixODBC.i686 unixODBC.x86_64 unixODBC-devel.i686 unixODBC-devel.x86_64
rpm -q compat-libstdc++-33 elfutils-libelf-devel  binutils compat-libcap1 gcc gcc-c++ glibc glibc.i686 glibc-devel glibc-devel.i686 ksh libaio.i686 libaio libaio-devel.i686 libaio-devel libgcc.i686 libgcc libstdc++.i686 libstdc++ libstdc++-devel.i686 libstdc++-devel libXi.i686 libXi libXtst.i686 libXtst make sysstat unixODBC.i686 unixODBC unixODBC-devel unzip --qf '%{name}.%{arch}\n'
VBoxManage.exe createhd --filename "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm1.vdi" --size 2048 --format VDI --variant Fixed
VBoxManage.exe createhd --filename "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm2.vdi" --size 30720 --format VDI --variant Fixed
VBoxManage.exe storageattach CentOS_7-4_64bit_IP71 --storagectl "SATA" --port 1 --device 0 --type hdd --medium "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm1.vdi" --mtype shareable
VBoxManage.exe storageattach CentOS_7-4_64bit_IP71 --storagectl "SATA" --port 2 --device 0 --type hdd --medium "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm2.vdi" --mtype shareable
VBoxManage.exe modifyhd "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm1.vdi" --type shareable
VBoxManage.exe modifyhd "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm2.vdi" --type shareable
VBoxManage.exe storageattach CentOS_7-4_64bit_IP72 --storagectl "SATA" --port 1 --device 0 --type hdd --medium "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm1.vdi" --mtype shareable
VBoxManage.exe storageattach CentOS_7-4_64bit_IP72 --storagectl "SATA" --port 2 --device 0 --type hdd --medium "E:\Vbox\Vmechine\workspace\share_disk between71and72\asm2.vdi" --mtype shareable
udevadm info --query=all --name=/dev/sdb
    DEVPATH=/devices/pci0000:00/0000:00:0d.0/ata4/host3/target3:0:0/3:0:0:0/block/sdb
udevadm info --query=all --name=/dev/sdc
    DEVPATH=/devices/pci0000:00/0000:00:0d.0/ata5/host4/target4:0:0/4:0:0:0/block/sdc
vi /etc/udev/rules.d/99-oracle-asmdevices.rules
KERNEL=="sdb",ENV{DEVPATH}=="/devices/pci0000:00/0000:00:0d.0/ata4/host3/target3:0:0/3:0:0:0/block/sdb",SYMLINK+="oraasm-$env{DM_NAME}",OWNER="grid",GROUP="asmadmin",MODE="0660"
KERNEL=="sdc",ENV{DEVPATH}=="/devices/pci0000:00/0000:00:0d.0/ata5/host4/target4:0:0/4:0:0:0/block/sdc",SYMLINK+="oraasm-$env{DM_NAME}",OWNER="grid",GROUP="asmadmin",MODE="0660"
##验证权限和属组
ls -Ll /dev/mapper/*
ls -Ll /dev/oraasm-*
ls -Ll /dev/dm-*
#多路径
#/etc/multipath.conf
multipaths {
        multipath {
                wwid 36006048cd70c3e37a4a85c04d0c79c6d
                alias data1
        }
        multipath {
                wwid 36006048cb82e28ed3701a9e1eecb820a
                alias crs1
         }
         multipath {
                 wwid 3600601606a003a001eebdf56d80e0b2f
                 alias data2
         }
         multipath {
                 wwid 3600601606a003a004aebdf56fce34966
                 alias data3
         }
}
#配置udev
cd /dev/mapper
for i in `ls mpath*`; do printf "%s %s\n" "$i" "$(udevadm info --query=all --name=/dev/mapper/$i |grep -i dm_uuid)"; done
data1 E: DM_UUID=mpath-36006048cd70c3e37a4a85c04d0c79c6d
crs1 E: DM_UUID=mpath-36006048cb82e28ed3701a9e1eecb820a
data2 E: DM_UUID=mpath-3600601606a003a001eebdf56d80e0b2f
data3 E: DM_UUID=mpath-3600601606a003a004aebdf56fce34966
[root@rac1 ~]# vi /etc/udev/rules.d/99-oracle-asmdevices.rules
KERNEL=="dm-*",ENV{DM_UUID}=="mpath-36006048cd70c3e37a4a85c04d0c79c6d",SYMLINK+="oraasm-$env{DM_NAME}",OWNER="grid",GROUP="asmadmin",MODE="0660"
KERNEL=="dm-*",ENV{DM_UUID}=="mpath-36006048cb82e28ed3701a9e1eecb820a",SYMLINK+="oraasm-$env{DM_NAME}",OWNER="grid",GROUP="asmadmin",MODE="0660"
KERNEL=="dm-*",ENV{DM_UUID}=="mpath-3600601606a003a001eebdf56d80e0b2f",SYMLINK+="oraasm-$env{DM_NAME}",OWNER="grid",GROUP="asmadmin",MODE="0660"
KERNEL=="dm-*",ENV{DM_UUID}=="mpath-3600601606a003a004aebdf56fce34966",SYMLINK+="oraasm-$env{DM_NAME}",OWNER="grid",GROUP="asmadmin",MODE="0660"
#重启udev服务
systemctl restart systemd-udev-trigger.service
##验证权限和属组
ls -Ll /dev/mapper/*
ls -Ll /dev/oraasm-*
ls -Ll /dev/dm-*
[root@ora71 ~]# rpm -ivh /home/grid/grid/rpm/cvuqdisk-1.0.9-1.rpm
Preparing...                          ################################# [100%]
ls: cannot access /usr/sbin/smartctl: No such file or directory
/usr/sbin/smartctl not found.
error: %pre(cvuqdisk-1.0.9-1.x86_64) scriptlet failed, exit status 1
error: cvuqdisk-1.0.9-1.x86_64: install failed
[root@ora71 ~]# yum install smartmontools
./runcluvfy.sh stage -pre crsinst -n ora71,ora72 -fixup -verbose >> check.txt

#安装响应文件解释:

oracle.install.responseFileVersion=/oracle/install/rspfmt_crsinstall_response_schema_v11_2_0
# 修改1:当前安装节点的计算机名称----------------------------------------------(重点注意1)
ORACLE_HOSTNAME=rac1
# 修改2:版本信息路径(路径相关可以不修改)
INVENTORY_LOCATION=/u01/app/oraInventory
# 修改3:语言,多选用,隔开(正常来说保持默认即可)
SELECTED_LANGUAGES=en,zh_CN
#4个选项提供,表示要做的操作
#   - CRS_CONFIG : To configure Grid Infrastructure for cluster
#   - HA_CONFIG  : To configure Grid Infrastructure for stand alone server
#   - UPGRADE    : To upgrade clusterware software of earlier release
#   - CRS_SWONLY : To install clusterware files only (can be configured for cluster
#                or stand alone server later)
oracle.install.option=CRS_CONFIG
# 修改4:grid 的 BASE 和 HOME 目录(路径相关可以不修改)
ORACLE_BASE=/u01/app/grid
ORACLE_HOME=/u01/app/11.2.0/grid
oracle.install.asm.OSDBA=asmdba
oracle.install.asm.OSOPER=asmoper
oracle.install.asm.OSASM=asmadmin
# 修改5:scan名称,和hosts对应--------------------------------------------------(重点注意2)
oracle.install.crs.config.gpnp.scanName=rac-scan
# 修改6:集群监听端口号---------------------------------------------------------(重点注意3)
oracle.install.crs.config.gpnp.scanPort=1521
# 修改7:cluster名称,可以保持默认
oracle.install.crs.config.clusterName=rac-cluster
#configureGNS为false,表示不配置GNS
#autoConfigureClusterNodeVIP这个参数为配置GNS后续参数之一,如果不开启GNS,这里指定false
oracle.install.crs.config.gpnp.configureGNS=false
oracle.install.crs.config.gpnp.gnsSubDomain=
oracle.install.crs.config.gpnp.gnsVIPAddress=
oracle.install.crs.config.autoConfigureClusterNodeVIP=false
# 修改8:节点信息,跟hosts对应---------------------------------------------------(重点注意4)
oracle.install.crs.config.clusterNodes=rac1:rac1-vip,rac2:rac2-vip
# 修改9:网卡信息和网段,对应ifconfig结果(两个节点的网卡名称需要一致)----------(重点注意5),1代表public,2代表private,3代表在群集中不使用该网卡
oracle.install.crs.config.networkInterfaceList=eth0:10.0.1.0:1,eth2:11.11.11.0:2
# 存储形式,使用ASM的话保持默认即可(可以不修改),2个值提供
#   - ASM_STORAGE
#   - FILE_SYSTEM_STORAGE
oracle.install.crs.config.storageOption=ASM_STORAGE
#这项只和windows有关,空着吧
oracle.install.crs.config.sharedFileSystemStorage.diskDriveMapping=
oracle.install.crs.config.sharedFileSystemStorage.votingDiskLocations=
oracle.install.crs.config.sharedFileSystemStorage.votingDiskRedundancy=NORMAL
oracle.install.crs.config.sharedFileSystemStorage.ocrLocations=
oracle.install.crs.config.sharedFileSystemStorage.ocrRedundancy=NORMAL
oracle.install.crs.config.useIPMI=false
oracle.install.crs.config.ipmi.bmcUsername=
oracle.install.crs.config.ipmi.bmcPassword=
# SYS密码
oracle.install.asm.SYSASMPassword=asmadmin
# 修改10:表决盘名称(可以不修改)
oracle.install.asm.diskGroup.name=OCR
# 修改11:表决盘冗余选项(接受以下3个选项)-----------------------------------------(重点注意6)
# HIGH            高冗余:最少5块磁盘,Oracle ASM默认提供三重镜像。可以容忍在不同故障组中丢失两个Oracle ASM磁盘。
# NORMAL        正常冗余:最少3块磁盘,Oracle ASM默认提供双向镜像,这意味着镜像所有文件,以便每个范围有两个副本。容许丢失一个磁盘。
# EXTERNAL        外部冗余:最少1块盘,由外部RAID提供冗余。
oracle.install.asm.diskGroup.redundancy=NORMAL
oracle.install.asm.diskGroup.AUSize=1
# 修改12:表决盘所使用的裸盘,根据需要修改------------------------------------------(重点注意7)
oracle.install.asm.diskGroup.disks=/dev/raw/raw1,/dev/raw/raw2,/dev/raw/raw5
oracle.install.asm.diskGroup.diskDiscoveryString=
# ASMSNMP密码
oracle.install.asm.monitorPassword=asmadmin
oracle.install.crs.upgrade.clusterNodes=
oracle.install.asm.upgradeASM=false
oracle.installer.autoupdates.option=SKIP_UPDATES
oracle.installer.autoupdates.downloadUpdatesLoc=
AUTOUPDATES_MYORACLESUPPORT_USERNAME=
AUTOUPDATES_MYORACLESUPPORT_PASSWORD=
PROXY_HOST=
PROXY_PORT=0
PROXY_USER=
PROXY_PWD=
PROXY_REALM=
oracle.install.responseFileVersion=/oracle/install/rspfmt_crsinstall_response_schema_v11_2_0
ORACLE_HOSTNAME=ora71
INVENTORY_LOCATION=/u01/app/grid/oraInventory
SELECTED_LANGUAGES=en
oracle.install.option=CRS_CONFIG
ORACLE_BASE=/u01/app/grid
ORACLE_HOME=/u01/app/gridhome/product/11.2.0/grid_1
oracle.install.asm.OSDBA=asmdba
oracle.install.asm.OSOPER=asmoper
oracle.install.asm.OSASM=asmadmin
oracle.install.crs.config.gpnp.scanName=orascan
oracle.install.crs.config.gpnp.scanPort=1521
oracle.install.crs.config.clusterName=oracluster
oracle.install.crs.config.gpnp.configureGNS=false
oracle.install.crs.config.gpnp.gnsSubDomain=
oracle.install.crs.config.gpnp.gnsVIPAddress=
oracle.install.crs.config.autoConfigureClusterNodeVIP=false
oracle.install.crs.config.clusterNodes=ora71:ora71-vip,ora72:ora72-vip
oracle.install.crs.config.networkInterfaceList=enp0s3:10.0.2.0:3,enp0s8:192.168.56.0:1,enp0s9:192.168.221.0:2,virbr0:192.168.122.0:3
oracle.install.crs.config.storageOption=ASM_STORAGE
oracle.install.crs.config.sharedFileSystemStorage.diskDriveMapping=
oracle.install.crs.config.sharedFileSystemStorage.votingDiskLocations=
oracle.install.crs.config.sharedFileSystemStorage.votingDiskRedundancy=NORMAL
oracle.install.crs.config.sharedFileSystemStorage.ocrLocations=
oracle.install.crs.config.sharedFileSystemStorage.ocrRedundancy=NORMAL
oracle.install.crs.config.useIPMI=false
oracle.install.crs.config.ipmi.bmcUsername=
oracle.install.crs.config.ipmi.bmcPassword=
oracle.install.asm.SYSASMPassword=oracle
oracle.install.asm.diskGroup.name=OCR
oracle.install.asm.diskGroup.redundancy=EXTERNAL
oracle.install.asm.diskGroup.AUSize=1
oracle.install.asm.diskGroup.disks=/dev/sdb
oracle.install.asm.diskGroup.diskDiscoveryString=/dev/sd*
oracle.install.asm.monitorPassword=oracle
oracle.install.crs.upgrade.clusterNodes=
oracle.install.asm.upgradeASM=false
oracle.installer.autoupdates.option=SKIP_UPDATES
oracle.installer.autoupdates.downloadUpdatesLoc=
AUTOUPDATES_MYORACLESUPPORT_USERNAME=
AUTOUPDATES_MYORACLESUPPORT_PASSWORD=
PROXY_HOST=
PROXY_PORT=0
PROXY_USER=
PROXY_PWD=
PROXY_REALM=
##开始安装grid
[grid@ora71 grid]$ ./runInstaller -ignorePrereq -force -silent -responseFile /home/grid/grid_rac11G.rsp -showProgress
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB.   Actual 39555 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 3967 MB    Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2019-06-14_03-34-01AM. Please wait ...[grid@ora71 grid]$ [WARNING] [INS-30011] The SYS password entered does not conform to the Oracle recommended standards.
   CAUSE: Oracle recommends that the password entered should be at least 8 characters in length, contain at least 1 uppercase character, 1 lower case character and 1 digit [0-9].
   ACTION: Provide a password that conforms to the Oracle recommended standards.
[WARNING] [INS-30011] The ASMSNMP password entered does not conform to the Oracle recommended standards.
   CAUSE: Oracle recommends that the password entered should be at least 8 characters in length, contain at least 1 uppercase character, 1 lower case character and 1 digit [0-9].
   ACTION: Provide a password that conforms to the Oracle recommended standards.
[WARNING] [INS-32055] The Central Inventory is located in the Oracle base.
   CAUSE: The Central Inventory is located in the Oracle base.
   ACTION: Oracle recommends placing this Central Inventory in a location outside the Oracle base directory.
You can find the log of this install session at:
/u01/app/grid/oraInventory/logs/installActions2019-06-14_03-34-01AM.log
Prepare in progress.
..................................................   9% Done.
Prepare successful.
Copy files in progress.
..................................................   15% Done.
..................................................   20% Done.
..................................................   25% Done.
..................................................   30% Done.
..................................................   35% Done.
..................................................   40% Done.
..................................................   45% Done.
........................................
Copy files successful.
Link binaries in progress.
Link binaries successful.
..................................................   62% Done.
Setup files in progress.
Setup files successful.
..................................................   76% Done.
Perform remote operations in progress.
..................................................   89% Done.
Perform remote operations successful.
The installation of Oracle Grid Infrastructure 11g was successful.
Please check '/u01/app/grid/oraInventory/logs/silentInstall2019-06-14_03-34-01AM.log' for more details.
..................................................   94% Done.
Execute Root Scripts in progress.
As a root user, execute the following script(s):
        1. /u01/app/grid/oraInventory/orainstRoot.sh
        2. /u01/app/gridhome/product/11.2.0/grid_1/root.sh
Execute /u01/app/grid/oraInventory/orainstRoot.sh on the following nodes:
[ora71, ora72]
Execute /u01/app/gridhome/product/11.2.0/grid_1/root.sh on the following nodes:
[ora71, ora72]
..................................................   100% Done.
Execute Root Scripts successful.
As install user, execute the following script to complete the configuration.
        1. /u01/app/gridhome/product/11.2.0/grid_1/cfgtoollogs/configToolAllCommands RESPONSE_FILE=<response_file>
        Note:
        1. This script must be run on the same host from where installer was run.
        2. This script needs a small password properties file for configuration assistants that require passwords (refer to install guide documentation).
Successfully Setup Software.
#在执行root脚本前需要执行下面的内容
vi /usr/lib/systemd/system/ohas.service
[Unit]
Description=Oracle High Availability Services
After=syslog.target
[Service]
ExecStart=/etc/init.d/init.ohasd run >/dev/null 2>&1 Type=simple
Restart=always
[Install]
WantedBy=multi-user.target
#启动服务
systemctl daemon-reload
systemctl enable ohas.service
systemctl start ohas.service
systemctl status ohas.service
##编辑脚本start_ohas.sh
vi start_ohas.sh
/bin/bash
while true
do
    if [ -f /etc/init.d/init.ohasd ];then
        systemctl start ohas.service
        systemctl status ohas.service
        break
    fi
done
[root@rhel7ora11 ~]# bash start_ohas.sh
#执行脚本
#节点一
[root@ora71 ~]# /u01/app/grid/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/grid/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.
Changing groupname of /u01/app/grid/oraInventory to oinstall.
The execution of the script is complete.
[root@ora71 ~]# /u01/app/gridhome/product/11.2.0/grid_1/root.sh
Check /u01/app/gridhome/product/11.2.0/grid_1/install/root_ora71_2019-06-14_03-44-22.log for the output of root script 
##再开窗口查看日志内容
[root@ora71 ~]# tail -f /u01/app/gridhome/product/11.2.0/grid_1/install/root_ora71_2019-06-14_03-44-22.log
Adding Clusterware entries to inittab
CRS-2672: Attempting to start 'ora.mdnsd' on 'ora71'
CRS-2676: Start of 'ora.mdnsd' on 'ora71' succeeded
CRS-2672: Attempting to start 'ora.gpnpd' on 'ora71'
CRS-2676: Start of 'ora.gpnpd' on 'ora71' succeeded
CRS-2672: Attempting to start 'ora.cssdmonitor' on 'ora71'
CRS-2672: Attempting to start 'ora.gipcd' on 'ora71'
CRS-2676: Start of 'ora.cssdmonitor' on 'ora71' succeeded
CRS-2676: Start of 'ora.gipcd' on 'ora71' succeeded
CRS-2672: Attempting to start 'ora.cssd' on 'ora71'
CRS-2672: Attempting to start 'ora.diskmon' on 'ora71'
CRS-2676: Start of 'ora.diskmon' on 'ora71' succeeded
CRS-2676: Start of 'ora.cssd' on 'ora71' succeeded
ASM created and started successfully.
Disk Group OCR created successfully.
clscfg: -install mode specified
Successfully accumulated necessary OCR keys.
Creating OCR keys for user 'root', privgrp 'root'..
Operation successful.
CRS-4256: Updating the profile
Successful addition of voting disk 546ae35122834f43bf6432b61368f647.
Successfully replaced voting disk group with +OCR.
CRS-4256: Updating the profile
CRS-4266: Voting file(s) successfully replaced
##  STATE    File Universal Id                File Name Disk group
--  -----    -----------------                --------- ---------
1. ONLINE   546ae35122834f43bf6432b61368f647 (/dev/sdb) [OCR]
Located 1 voting disk(s).
CRS-2672: Attempting to start 'ora.asm' on 'ora71'
CRS-2676: Start of 'ora.asm' on 'ora71' succeeded
CRS-2672: Attempting to start 'ora.OCR.dg' on 'ora71'
CRS-2676: Start of 'ora.OCR.dg' on 'ora71' succeeded
Configure Oracle Grid Infrastructure for a Cluster ... succeeded
#节点二
[root@ora72 ~]# /u01/app/grid/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/grid/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.
Changing groupname of /u01/app/grid/oraInventory to oinstall.
The execution of the script is complete.
[root@ora72 ~]# /u01/app/gridhome/product/11.2.0/grid_1/root.sh
Check /u01/app/gridhome/product/11.2.0/grid_1/install/root_ora72_2019-06-14_03-57-52.log for the output of root script
##再开窗口查看脚本执行详细内容
[root@ora72 ~]# tail -f /u01/app/gridhome/product/11.2.0/grid_1/install/root_ora72_2019-06-14_03-57-52.log
Creating /etc/oratab file...
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /u01/app/gridhome/product/11.2.0/grid_1/crs/install/crsconfig_params
Creating trace directory
User ignored Prerequisites during installation
Installing Trace File Analyzer
OLR initialization - successful
Adding Clusterware entries to inittab
CRS-4402: The CSS daemon was started in exclusive mode but found an active CSS daemon on node ora71, number 1, and is terminating
An active cluster was found during exclusive startup, restarting to join the cluster
Configure Oracle Grid Infrastructure for a Cluster ... succeeded
#在安装节点(节点一)的grid用户执行配置脚本
[grid@ora71 grid]$ /u01/app/gridhome/product/11.2.0/grid_1/cfgtoollogs/configToolAllCommands RESPONSE_FILE=/home/grid/grid_rac11G.rsp
Setting the invPtrLoc to /u01/app/gridhome/product/11.2.0/grid_1/oraInst.loc
perform - mode is starting for action: configure
perform - mode finished for action: configure
You can see the log file: /u01/app/gridhome/product/11.2.0/grid_1/cfgtoollogs/oui/configActions2019-06-14_04-13-15-AM.log
#查看集群状态
[grid@ora71 grid]$ crsctl stat res -t
--------------------------------------------------------------------------------
NAME           TARGET  STATE        SERVER                   STATE_DETAILS       
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.LISTENER.lsnr
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.OCR.dg
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.asm
               ONLINE  ONLINE       ora71                    Started             
               ONLINE  ONLINE       ora72                    Started             
ora.gsd
               OFFLINE OFFLINE      ora71                                        
               OFFLINE OFFLINE      ora72                                        
ora.net1.network
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.ons
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
      1        ONLINE  ONLINE       ora71                                        
ora.cvu
      1        ONLINE  ONLINE       ora71                                        
ora.oc4j
      1        ONLINE  ONLINE       ora71                                        
ora.ora71.vip
      1        ONLINE  ONLINE       ora71                                        
ora.ora72.vip
      1        ONLINE  ONLINE       ora72                                        
ora.scan1.vip
      1        ONLINE  ONLINE       ora71
#创建磁盘组
[grid@ora71 grid]$ sqlplus /nolog
SQL*Plus: Release 11.2.0.4.0 Production on Fri Jun 14 04:16:59 2019
Copyright (c) 1982, 2013, Oracle.  All rights reserved.
SQL> conn / as sysasm
Connected.
SQL> create diskgroup DATA01 external redundancy disk '/dev/sdc';
Diskgroup created.
SQL> set linesize 300
SQL> select NAME,TOTAL_MB/1024 "TOTAL/G",FREE_MB/1024 "FREE/G",round(FREE_MB/TOTAL_MB*100)||'%' Per_Free,state from v$asm_diskgroup;
NAME                              TOTAL/G     FREE/G PER_FREE                                  STATE
------------------------------ ---------- ---------- ----------------------------------------- -----------
OCR                                     2 1.61328125 81%                                       MOUNTED
DATA01                                 30 29.9511719 100%                                      MOUNTED
SQL> !crsctl stat res -t
--------------------------------------------------------------------------------
NAME           TARGET  STATE        SERVER                   STATE_DETAILS       
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA01.dg
               ONLINE  ONLINE       ora71                                        
               OFFLINE OFFLINE      ora72                                        
ora.LISTENER.lsnr
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.OCR.dg
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.asm
               ONLINE  ONLINE       ora71                    Started             
               ONLINE  ONLINE       ora72                    Started             
ora.gsd
               OFFLINE OFFLINE      ora71                                        
               OFFLINE OFFLINE      ora72                                        
ora.net1.network
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.ons
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
      1        ONLINE  ONLINE       ora71                                        
ora.cvu
      1        ONLINE  ONLINE       ora71                                        
ora.oc4j
      1        ONLINE  ONLINE       ora71                                        
ora.ora71.vip
      1        ONLINE  ONLINE       ora71                                        
ora.ora72.vip
      1        ONLINE  ONLINE       ora72                                        
ora.scan1.vip
      1        ONLINE  ONLINE       ora71   
#在节点二挂载磁盘组
root@ora71 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/srvctl start diskgroup -g DATA01 -n ora72
[root@ora71 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/crsctl stat res -t
--------------------------------------------------------------------------------
NAME           TARGET  STATE        SERVER                   STATE_DETAILS       
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA01.dg
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.LISTENER.lsnr
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.OCR.dg
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.asm
               ONLINE  ONLINE       ora71                    Started             
               ONLINE  ONLINE       ora72                    Started             
ora.gsd
               OFFLINE OFFLINE      ora71                                        
               OFFLINE OFFLINE      ora72                                        
ora.net1.network
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.ons
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
      1        ONLINE  ONLINE       ora71                                        
ora.cvu
      1        ONLINE  ONLINE       ora71                                        
ora.oc4j
      1        ONLINE  ONLINE       ora71                                        
ora.ora71.vip
      1        ONLINE  ONLINE       ora71                                        
ora.ora72.vip
      1        ONLINE  ONLINE       ora72                                        
ora.scan1.vip
      1        ONLINE  ONLINE       ora71
#安装rdbms
#编辑rsp文件
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0
#安装选项,3个值可选
#   - INSTALL_DB_SWONLY   #只安装rdbms
#   - INSTALL_DB_AND_CONFIG  #安装rdbms和instance
#   - UPGRADE_DB           #升级安装
oracle.install.option=INSTALL_DB_SWONLY
#指定当前安装节点的主机名
ORACLE_HOSTNAME=ora71
UNIX_GROUP_NAME=oinstall
#指定日志路径
INVENTORY_LOCATION=/u01/app/oracle/oraInventory
#指定语言,en   : English,zh_CN: Simplified Chinese。多个语言用逗号分隔
SELECTED_LANGUAGES=en
ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1
ORACLE_BASE=/u01/app/oracle
#指定安装的版本,4个值可选
#   - EE     : Enterprise Edition                                
#   - SE     : Standard Edition                                  
#   - SEONE  : Standard Edition One
#   - PE     : Personal Edition (WINDOWS ONLY)
oracle.install.db.InstallEdition=EE
oracle.install.db.EEOptionsSelection=false
oracle.install.db.optionalComponents=
#指定组权限
oracle.install.db.DBA_GROUP=dba
oracle.install.db.OPER_GROUP=oper
#指定节点名称,一般使用主机名
oracle.install.db.CLUSTER_NODES=ora71,ora72
#是否安装rac一个节点
#   - true  : Value of RAC One Node service name is used.
#   - false : Value of RAC One Node service name is not used.
oracle.install.db.isRACOneInstall=false
oracle.install.db.racOneServiceName=
#指定创建的数据库的类型
#   - GENERAL_PURPOSE/TRANSACTION_PROCESSING             
#   - DATA_WAREHOUSE   
oracle.install.db.config.starterdb.type=GENERAL_PURPOSE
#指定实例的参数,但是我们只安装rdbms,这里不指定
oracle.install.db.config.starterdb.globalDBName=
oracle.install.db.config.starterdb.SID=
oracle.install.db.config.starterdb.characterSet=
oracle.install.db.config.starterdb.memoryOption=false
oracle.install.db.config.starterdb.memoryLimit=
oracle.install.db.config.starterdb.installExampleSchemas=false
oracle.install.db.config.starterdb.enableSecuritySettings=true
oracle.install.db.config.starterdb.password.ALL=
oracle.install.db.config.starterdb.password.SYS=
oracle.install.db.config.starterdb.password.SYSTEM=
oracle.install.db.config.starterdb.password.SYSMAN=
oracle.install.db.config.starterdb.password.DBSNMP=
oracle.install.db.config.starterdb.control=DB_CONTROL
oracle.install.db.config.starterdb.gridcontrol.gridControlServiceURL=
oracle.install.db.config.starterdb.automatedBackup.enable=false
oracle.install.db.config.starterdb.automatedBackup.osuid=
oracle.install.db.config.starterdb.automatedBackup.ospwd=
oracle.install.db.config.starterdb.storageType=
oracle.install.db.config.starterdb.fileSystemStorage.dataLocation=
oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation=
oracle.install.db.config.asm.diskGroup=
oracle.install.db.config.asm.ASMSNMPPassword=
#指定oracle support的用户名和密码
MYORACLESUPPORT_USERNAME=
MYORACLESUPPORT_PASSWORD=
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
#指定是否不配置安装更新
DECLINE_SECURITY_UPDATES=true
PROXY_HOST=
PROXY_PORT=
PROXY_USER=
PROXY_PWD=
PROXY_REALM=
COLLECTOR_SUPPORTHUB_URL=
oracle.installer.autoupdates.option=SKIP_UPDATES
oracle.installer.autoupdates.downloadUpdatesLoc=
AUTOUPDATES_MYORACLESUPPORT_USERNAME=
AUTOUPDATES_MYORACLESUPPORT_PASSWORD=
#编译好的文件
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0
oracle.install.option=INSTALL_DB_SWONLY
ORACLE_HOSTNAME=ora71
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/u01/app/oracle/oraInventory
SELECTED_LANGUAGES=en
ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1
ORACLE_BASE=/u01/app/oracle
oracle.install.db.InstallEdition=EE
oracle.install.db.EEOptionsSelection=false
oracle.install.db.optionalComponents=
oracle.install.db.DBA_GROUP=dba
oracle.install.db.OPER_GROUP=oper
oracle.install.db.CLUSTER_NODES=ora71,ora72
oracle.install.db.isRACOneInstall=false
oracle.install.db.racOneServiceName=
oracle.install.db.config.starterdb.type=GENERAL_PURPOSE
oracle.install.db.config.starterdb.globalDBName=
oracle.install.db.config.starterdb.SID=
oracle.install.db.config.starterdb.characterSet=
oracle.install.db.config.starterdb.memoryOption=false
oracle.install.db.config.starterdb.memoryLimit=
oracle.install.db.config.starterdb.installExampleSchemas=false
oracle.install.db.config.starterdb.enableSecuritySettings=true
oracle.install.db.config.starterdb.password.ALL=
oracle.install.db.config.starterdb.password.SYS=
oracle.install.db.config.starterdb.password.SYSTEM=
oracle.install.db.config.starterdb.password.SYSMAN=
oracle.install.db.config.starterdb.password.DBSNMP=
oracle.install.db.config.starterdb.control=DB_CONTROL
oracle.install.db.config.starterdb.gridcontrol.gridControlServiceURL=
oracle.install.db.config.starterdb.automatedBackup.enable=false
oracle.install.db.config.starterdb.automatedBackup.osuid=
oracle.install.db.config.starterdb.automatedBackup.ospwd=
oracle.install.db.config.starterdb.storageType=
oracle.install.db.config.starterdb.fileSystemStorage.dataLocation=
oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation=
oracle.install.db.config.asm.diskGroup=
oracle.install.db.config.asm.ASMSNMPPassword=
MYORACLESUPPORT_USERNAME=
MYORACLESUPPORT_PASSWORD=
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
DECLINE_SECURITY_UPDATES=true
PROXY_HOST=
PROXY_PORT=
PROXY_USER=
PROXY_PWD=
PROXY_REALM=
COLLECTOR_SUPPORTHUB_URL=
oracle.installer.autoupdates.option=SKIP_UPDATES
oracle.installer.autoupdates.downloadUpdatesLoc=
AUTOUPDATES_MYORACLESUPPORT_USERNAME=
AUTOUPDATES_MYORACLESUPPORT_PASSWORD=
#在安装rdbms前,需要编辑一个脚本,因为oracle11G在linux7上面安装有bug
vi edit_emagent.sh
#/bin/bash
[ -f ~/.bash_profile ]&& . ~/.bash_profile
while true
do
    if [ -f $ORACLE_HOME/sysman/lib/ins_emagent.mk ];then
        sed -i 's/$(MK_EMAGENT_NMECTL)/$(MK_EMAGENT_NMECTL)-lnnz11/g' $ORACLE_HOME/sysman/lib/ins_emagent.mk
        break
    fi
done
bash edit_emagent.sh
#开始安装rdbms
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB.   Actual 30631 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 3965 MB    Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2019-06-14_05-06-03AM. Please wait ...[oracle@ora71 database]$ You can find the log of this install session at:
/u01/app/grid/oraInventory/logs/installActions2019-06-14_05-06-03AM.log
Prepare in progress.
..................................................   9% Done.
Prepare successful.
Copy files in progress.
..................................................   15% Done.
..................................................   20% Done.
..................................................   25% Done.
..................................................   30% Done.
..................................................   36% Done.
..................................................   41% Done.
..................................................   46% Done.
..................................................   51% Done.
..................................................   56% Done.
Copy files successful.
..........
Link binaries in progress.
Link binaries successful.
..................................................   77% Done.
Setup files in progress.
..................................................   94% Done.
Setup files successful.
The installation of Oracle Database 11g was successful.
Please check '/u01/app/grid/oraInventory/logs/silentInstall2019-06-14_05-06-03AM.log' for more details.
Execute Root Scripts in progress.
As a root user, execute the following script(s):
1. /u01/app/oracle/product/11.2.0/db_1/root.sh
Execute /u01/app/oracle/product/11.2.0/db_1/root.sh on the following nodes:
[ora71, ora72]
..................................................   100% Done.
Execute Root Scripts successful.
Successfully Setup Software.
#root执行脚本
#节点一
[root@ora71 ~]# /u01/app/oracle/product/11.2.0/db_1/root.sh
Check /u01/app/oracle/product/11.2.0/db_1/install/root_ora71_2019-06-14_05-20-51.log for the output of root script
[root@ora71 ~]# cat /u01/app/oracle/product/11.2.0/db_1/install/root_ora71_2019-06-14_05-20-51.log
Performing root user operation for Oracle 11g
The following environment variables are set as:
    ORACLE_OWNER= oracle
    ORACLE_HOME=  /u01/app/oracle/product/11.2.0/db_1
   Copying dbhome to /usr/local/bin ...
   Copying oraenv to /usr/local/bin ...
   Copying coraenv to /usr/local/bin ...
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Finished product-specific root actions.
Finished product-specific root actions.
#节点二
[root@ora72 ~]# /u01/app/oracle/product/11.2.0/db_1/root.sh
Check /u01/app/oracle/product/11.2.0/db_1/install/root_ora72_2019-06-14_05-21-34.log for the output of root script
[root@ora72 ~]# cat /u01/app/oracle/product/11.2.0/db_1/install/root_ora72_2019-06-14_05-21-34.log
Performing root user operation for Oracle 11g
The following environment variables are set as:
    ORACLE_OWNER= oracle
    ORACLE_HOME=  /u01/app/oracle/product/11.2.0/db_1
   Copying dbhome to /usr/local/bin ...
   Copying oraenv to /usr/local/bin ...
   Copying coraenv to /usr/local/bin ...
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Finished product-specific root actions.
Finished product-specific root actions.
#创建实例
#编辑rsp文件
[GENERAL]
RESPONSEFILE_VERSION = "11.2.0"
#Valid values  : "createDatabase" \ "createTemplateFromDB" \ "createCloneTemplate" \ "deleteDatabase" \ "configureDatabase" \ "addInstance" (RAC-only) \ "deleteInstance" (RAC-only)
OPERATION_TYPE = "createDatabase"
[CREATEDATABASE]
#Description   : Global database name of the database
GDBNAME = "orcl11g.us.oracle.com"
SID = "orcl11g"
#指定安装节点的主机名,多个节点用逗号分隔
NODELIST=
TEMPLATENAME = "General_Purpose.dbc"
#指定sys和system用户的密码
SYSPASSWORD = "password"
SYSTEMPASSWORD = "password"
#指定数据文件的路径
DATAFILEDESTINATION =
#指定数据库存储的类型
# Valid values  : FS (CFS for RAC), ASM
STORAGETYPE=FS
#指定磁盘组名称
DISKGROUPNAME=DATA
#指定字符集,国际字符集的默认是"AL16UTF16"
CHARACTERSET = "AL32UTF8"
NATIONALCHARACTERSET= "UTF8" 
#-----------------------------------------------------------------------------
# Name          : MEMORYPERCENTAGE
# Datatype      : String
# Description   : percentage of physical memory for Oracle
# Default value : None
# Mandatory     : NO
#-----------------------------------------------------------------------------
#MEMORYPERCENTAGE = "40"
#指定使用的内存
# Description   : total memory in MB to allocate to Oracle
TOTALMEMORY = "1700"
#编译好的rsp文件
[GENERAL]
RESPONSEFILE_VERSION = "11.2.0"
OPERATION_TYPE = "createDatabase"
[CREATEDATABASE]
GDBNAME = "RACDB"
SID = "RACDB"
NODELIST=ora71,ora72
TEMPLATENAME = "General_Purpose.dbc"
SYSPASSWORD = "oracle"
SYSTEMPASSWORD = "oracle"
DATAFILEDESTINATION = "+data01"
STORAGETYPE=ASM
DISKGROUPNAME=DATA01
CHARACTERSET = "AL32UTF8"
NATIONALCHARACTERSET= "UTF8"
TOTALMEMORY = "1700"
#创建实例
[oracle@ora71 ~]$ $ORACLE_HOME/bin/dbca -silent -responseFile /home/oracle/dbca_rac.rsp
Copying database files
1% complete
3% complete
30% complete
Creating and starting Oracle instance
32% complete
36% complete
40% complete
44% complete
45% complete
48% complete
50% complete
Creating cluster database views
52% complete
70% complete
Completing Database Creation
73% complete
76% complete
85% complete
94% complete
100% complete
Look at the log file "/u01/app/oracle/cfgtoollogs/dbca/RACDB/RACDB.log" for further details
#验证实例
[grid@ora71 grid]$ crsctl stat res -t
--------------------------------------------------------------------------------
NAME           TARGET  STATE        SERVER                   STATE_DETAILS       
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA01.dg
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.LISTENER.lsnr
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.OCR.dg
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.asm
               ONLINE  ONLINE       ora71                    Started             
               ONLINE  ONLINE       ora72                    Started             
ora.gsd
               OFFLINE OFFLINE      ora71                                        
               OFFLINE OFFLINE      ora72                                        
ora.net1.network
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
ora.ons
               ONLINE  ONLINE       ora71                                        
               ONLINE  ONLINE       ora72                                        
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
      1        ONLINE  ONLINE       ora71                                        
ora.cvu
      1        ONLINE  ONLINE       ora71                                        
ora.oc4j
      1        ONLINE  ONLINE       ora71                                        
ora.ora71.vip
      1        ONLINE  ONLINE       ora71                                        
ora.ora72.vip
      1        ONLINE  ONLINE       ora72                                        
ora.racdb.db
      1        ONLINE  ONLINE       ora71                    Open                
      2        ONLINE  ONLINE       ora72                    Open                
ora.scan1.vip
      1        ONLINE  ONLINE       ora71                         
#sqlplus验证
SQL> set linesize 300
SQL> select instance_number,instance_name,host_name,status from gv$instance;
INSTANCE_NUMBER INSTANCE_NAME    HOST_NAME                    STATUS
--------------- ---------------- ---------------------------------------------------------------- ------------
       1 RACDB1   ora71                   OPEN
       2 RACDB2   ora72                   OPEN
SQL>

到此,关于“linux7静默安装11GR2 RAC的方法是什么”的学习就结束了,希望能够解决大家的疑惑。理论与实践的搭配能更好的帮助大家学习,快去试试吧!若想继续学习更多相关知识,请继续关注亿速云网站,小编会继续努力为大家带来更多实用的文章!

推荐阅读:
  1. oracle 11gr2 RAC virtualbox 安装
  2. Oracle 11gR2 RAC搭建(虚拟机搭建)

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

linux rac

上一篇:system表空间怎么解决ORA-00604报错

下一篇:如何修改oracle数据库的db_name,instace_name,sid_name

相关阅读

您好,登录后才能下订单哦!

密码登录
登录注册
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》