码迷,mamicode.com
首页 > 数据库 > 详细

oracle11g RAC之grid安装

时间:2020-04-29 18:33:52      阅读:68      评论:0      收藏:0      [点我收藏+]

标签:使用   scan   action   int   toc   services   root   copyright   points   

进入安装grid

1、解压grid安装包并授权

db1:~ # cd /software/
db1:/software # unzip p13390677_112040_Linux-x86-64_3of7.zip
db1:/software # chown -R grid:oinstall /software/

2、在db1上配置vnc

db1:~ # su - grid
grid@db1:~> vncserver

You will require a password to access your desktops.

Password:
Verify:
Would you like to enter a view-only password (y/n)? n
xauth:  creating new authority file /home/grid/.Xauthority

New X desktop is db1:1

Creating default startup script /home/grid/.vnc/xstartup
Starting applications specified in /home/grid/.vnc/xstartup
Log file is /home/grid/.vnc/db1:1.log

3、使用vnc工具安装grid

技术图片

 4、进入安装包路径,进行安装

db1:/software # cd
db1:~ # su - grid
grid@db1:~> cd /software/grid/
grid@db1:/software/grid> ./runInstaller

5、

技术图片

 

 

 6、

 技术图片

 

 

 7、

技术图片

 

 

 8、

技术图片

 

 

 9、

技术图片

 

 

 10、

 技术图片

 

 

 11、

技术图片

 

 

 12、

技术图片

 

 

 13、

查看AU size

select group_number,name,sector_size,block_size,allocation_unit_size/1024/1024 from v$asm_diskgroup;

 

 

 

 技术图片

 

 

 14、

技术图片

 

 

 15、

技术图片

 

 

 16、

技术图片

 

 17、

技术图片

 

 

18、

技术图片

 

 19、

db1:~ # /u01/app/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.

Changing groupname of /u01/app/oraInventory to oinstall.
The execution of the script is complete.


db2:/software # /u01/app/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.

Changing groupname of /u01/app/oraInventory to oinstall.
The execution of the script is complete.
db2:/software #
第2个脚本第一个节点:
db1:~ # /u01/app/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.

Changing groupname of /u01/app/oraInventory to oinstall.
The execution of the script is complete.
db1:~ # /u01/app/grid/product/11204/root.sh
Performing root user operation for Oracle 11g

The following environment variables are set as:
    ORACLE_OWNER= grid
    ORACLE_HOME=  /u01/app/grid/product/11204

Enter the full pathname of the local bin directory: [/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/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/grid/product/11204/crs/install/crsconfig_params
Creating trace directory
User ignored Prerequisites during installation
Installing Trace File Analyzer
OLR initialization - successful
  root wallet
  root wallet cert
  root cert export
  peer wallet
  profile reader wallet
  pa wallet
  peer wallet keys
  pa wallet keys
  peer cert request
  pa cert request
  peer cert
  pa cert
  peer root cert TP
  profile reader root cert TP
  pa root cert TP
  peer pa cert TP
  pa peer cert TP
  profile reader pa cert TP
  profile reader peer cert TP
  peer user cert
  pa user cert
Adding Clusterware entries to inittab
CRS-2672: Attempting to start ora.mdnsd on db1
CRS-2676: Start of ora.mdnsd on db1 succeeded
CRS-2672: Attempting to start ora.gpnpd on db1
CRS-2676: Start of ora.gpnpd on db1 succeeded
CRS-2672: Attempting to start ora.cssdmonitor on db1
CRS-2672: Attempting to start ora.gipcd on db1
CRS-2676: Start of ora.cssdmonitor on db1 succeeded
CRS-2676: Start of ora.gipcd on db1 succeeded
CRS-2672: Attempting to start ora.cssd on db1
CRS-2672: Attempting to start ora.diskmon on db1
CRS-2676: Start of ora.diskmon on db1 succeeded
CRS-2676: Start of ora.cssd on db1 succeeded

ASM created and started successfully.

Disk Group OCRVOT 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 030d6d33008d4f5ebfc2a67b6b2bdf1c.
Successful addition of voting disk 6ad52e0a4c5f4fbcbf7f4fb09137567b.
Successful addition of voting disk 22b65048787c4fe2bfe63c6c0dd06fe8.
Successfully replaced voting disk group with +OCRVOT.
CRS-4256: Updating the profile
CRS-4266: Voting file(s) successfully replaced
##  STATE    File Universal Id                File Name Disk group
--  -----    -----------------                --------- ---------
 1. ONLINE   030d6d33008d4f5ebfc2a67b6b2bdf1c (/dev/oracleasm/disks/OCRVOT1) [OCRVOT]
 2. ONLINE   6ad52e0a4c5f4fbcbf7f4fb09137567b (/dev/oracleasm/disks/OCRVOT2) [OCRVOT]
 3. ONLINE   22b65048787c4fe2bfe63c6c0dd06fe8 (/dev/oracleasm/disks/OCRVOT3) [OCRVOT]
Located 3 voting disk(s).
CRS-2672: Attempting to start ora.asm on db1
CRS-2676: Start of ora.asm on db1 succeeded
CRS-2672: Attempting to start ora.OCRVOT.dg on db1
CRS-2676: Start of ora.OCRVOT.dg on db1 succeeded
Configure Oracle Grid Infrastructure for a Cluster ... succeeded
db1:~ #

db1:/sof
第二个脚本第二个节点:
db2:/software # /u01/app/grid/product/11204/root.sh
Performing root user operation for Oracle 11g

The following environment variables are set as:
    ORACLE_OWNER= grid
    ORACLE_HOME=  /u01/app/grid/product/11204

Enter the full pathname of the local bin directory: [/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/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/grid/product/11204/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 db1, 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
db2:/software #

 20、

技术图片

 

 

 

21、检查监听状态

grid@db1:~> lsnrctl status

LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 14-NOV-2019 09:16:32

Copyright (c) 1991, 2013, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=LISTENER)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date                13-NOV-2019 12:06:51
Uptime                    0 days 21 hr. 9 min. 41 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /u01/app/grid/product/11204/network/admin/listener.ora
Listener Log File         /u01/app/oracrs/diag/tnslsnr/db1/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=LISTENER)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.10.10.10)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.10.10.30)(PORT=1521)))
Services Summary...
Service "+ASM" has 1 instance(s).
  Instance "+ASM1", status READY, has 1 handler(s) for this service...
The command completed successfully
grid@db1:~>

22、查看节点信息

使用crs_stat -t -v或者crsctl status res -t  或者crsctl stat res -t

grid@db1:~> crsctl status res -t
--------------------------------------------------------------------------------
NAME           TARGET  STATE        SERVER                   STATE_DETAILS
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.LISTENER.lsnr
               ONLINE  ONLINE       db1
               ONLINE  ONLINE       db2
ora.OCRVOT.dg
               ONLINE  ONLINE       db1
               ONLINE  ONLINE       db2
ora.asm
               ONLINE  ONLINE       db1                 Started
               ONLINE  ONLINE       db2                 Started
ora.gsd
               OFFLINE OFFLINE      db1
               OFFLINE OFFLINE      db2
ora.net1.network
               ONLINE  ONLINE       db1
               ONLINE  ONLINE       db2
ora.ons
               ONLINE  ONLINE       db1
               ONLINE  ONLINE       db2
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
      1        ONLINE  ONLINE       db1
ora.db1.vip
      1        ONLINE  ONLINE       db1
ora.db2.vip
      1        ONLINE  ONLINE       db2
ora.cvu
      1        ONLINE  ONLINE       db1
ora.oc4j
      1        ONLINE  ONLINE       db1
ora.scan1.vip
      1        ONLINE  ONLINE       db1

 

23、创建ASM磁盘组(asmca)

以grid用户运行asmca

grid@db1:~> asmca

技术图片

 

oracle11g RAC之grid安装

标签:使用   scan   action   int   toc   services   root   copyright   points   

原文地址:https://www.cnblogs.com/connected/p/11840268.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!