Thursday, January 15, 2015

How to check OCR details.

How to check OCR details.

Need to use the below tools for checking the OCR details

oracle@testserver1i /u01/app/11.2.0.4/grid/bin +ASM1 > ocrcheck
Status of Oracle Cluster Registry is as follows :
         Version                  :          3
         Total space (kbytes)     :     262120
         Used space (kbytes)      :       3860
         Available space (kbytes) :     258260
         ID                       :  710588188
         Device/File Name         : +OCRVOTEDG
                                    Device/File integrity check succeeded

                                    Device/File not configured

                                    Device/File not configured

                                    Device/File not configured

                                    Device/File not configured

         Cluster registry integrity check succeeded

         Logical corruption check bypassed due to non-privileged user

oracle@testserver1i /u01/app/11.2.0.4/grid/bin +ASM1 >

Go inside the asm location to check the phisical file

oracle@testserver1i /u01/app/11.2.0.4/grid/bin +ASM1 > asmcmd
ASMCMD> cd OCRVOTEDG
ASMCMD> ls
testingdbiscan/
ASMCMD> cd testingdbiscan/
ASMCMD> ls
ASMPARAMETERFILE/
OCRFILE/
ASMCMD> cd ASMPARAMETERFILE/
ASMCMD> ls
REGISTRY.253.807918545
ASMCMD>


To fine the OLR or the local registry for the Cluster node go to the root user and run the below command.

[root@testserver1i app]# . oraenv
ORACLE_SID = [root] ? +ASM1
The Oracle base has been set to /u01/app/oracle
[root@testserver1i app]# echo $ORACLE_HOME
/u01/app/11.2.0.4/grid
[root@testserver1i app]# ocrcheck -local
Status of Oracle Local Registry is as follows :
         Version                  :          3
         Total space (kbytes)     :     262120
         Used space (kbytes)      :       2696
         Available space (kbytes) :     259424
         ID                       : 1047978051
         Device/File Name         : /u01/app/11.2.0.4/grid/cdata/testserver1i.olr
                                    Device/File integrity check succeeded

         Local registry integrity check succeeded

         Logical corruption check succeeded

[root@testserver1i app]#

How to check CRS (Cluster ready services ) status in Oracle

How to check CRS (Cluster ready services ) status in Oracle 

Go to the Grid home and bin direcotry.

oracle@testingserver1i /u01/app/11.2.0.4/grid/bin +ASM1 > crsctl check crs
CRS-4638: Oracle High Availability Services is online
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online

oracle@testingserver1i /u01/app/11.2.0.4/grid/bin +ASM1 > srvctl status nodeapps
VIP testingserver1i-vip is enabled
VIP testingserver1i-vip is running on node: testingserver1i
VIP testingserver2i-vip is enabled
VIP testingserver2i-vip is running on node: testingserver2i
Network is enabled
Network is running on node: testingserver1i
Network is running on node: testingserver2i
GSD is disabled
GSD is not running on node: testingserver1i
GSD is not running on node: testingserver2i
ONS is enabled
ONS daemon is running on node: testingserver1i
ONS daemon is running on node: testingserver2i


oracle@testingserver1i /u01/app/11.2.0.4/grid/bin +ASM1 > crsctl stat res -t
--------------------------------------------------------------------------------
NAME           TARGET  STATE        SERVER                   STATE_DETAILS
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.testDB.dg
               ONLINE  ONLINE       testingserver1i
               ONLINE  ONLINE       testingserver2i
ora.DBA_BANK.dg
               ONLINE  ONLINE       testingserver1i
               ONLINE  ONLINE       testingserver2i
ora.LISTENER.lsnr
               ONLINE  ONLINE       testingserver1i
               ONLINE  ONLINE       testingserver2i
ora.OCRVOTEDG.dg
               ONLINE  ONLINE       testingserver1i
               ONLINE  ONLINE       testingserver2i
ora.asm
               ONLINE  ONLINE       testingserver1i            Started
               ONLINE  ONLINE       testingserver2i            Started
ora.gsd
               OFFLINE OFFLINE      testingserver1i
               OFFLINE OFFLINE      testingserver2i
ora.net1.network
               ONLINE  ONLINE       testingserver1i
               ONLINE  ONLINE       testingserver2i
ora.ons
               ONLINE  ONLINE       testingserver1i
               ONLINE  ONLINE       testingserver2i
ora.registry.acfs
               ONLINE  ONLINE       testingserver1i
               ONLINE  ONLINE       testingserver2i
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
      1        ONLINE  ONLINE       testingserver1i
ora.LISTENER_SCAN2.lsnr
      1        ONLINE  ONLINE       testingserver2i
ora.LISTENER_SCAN3.lsnr
      1        ONLINE  ONLINE       testingserver2i

ora.testingserver1i.vip
      1        ONLINE  ONLINE       testingserver1i
ora.testingserver2i.vip
      1        ONLINE  ONLINE       testingserver2i
ora.cvu
      1        ONLINE  ONLINE       testingserver2i
ora.oc4j
      1        ONLINE  ONLINE       testingserver2i
ora.scan1.vip
      1        ONLINE  ONLINE       testingserver1i
ora.scan2.vip
      1        ONLINE  ONLINE       testingserver2i
ora.scan3.vip
      1        ONLINE  ONLINE       testingserver2i
oracle@testingserver1i /u01/app/11.2.0.4/grid/bin +ASM1 >

Command to do active duplicate for Oracle Database

1. First login to target server 2. Validate tns connectivity between Source DB and Target DB 3. Prepare and validate space availability 4. S...