Thursday 8 April 2021

ASM - Online OCR and Voting Adding on ASM Diskgroup using Normal Redundancy

 ASM -   Online OCR and Voting disk SAN LUN Migration on ASM Diskgroup Normal Redundancy

Once 3 ASM disks are created at OS level using oracleasm utility. We will add to CRS ASM diskgroup online as OCR and voting disk is stored on it.

See also  blog link for details in alert log: ASM - Online OCR and Voting disk SAN LUN Migration on ASM Diskgroup

Redundancy Level: Normal

Grid Version: 12.1.0.2.0

  • Create ASM disk of same size using oracleasm utility

[root@srv1 ~]# oracleasm createdisk CRSNEW1 /dev/sdc1

Writing disk header: done

Instantiating disk: done

[root@srv1 ~]# oracleasm createdisk CRSNEW2 /dev/sdd1

Writing disk header: done

Instantiating disk: done

[root@srv1 ~]# oracleasm createdisk CRSNEW3 /dev/sdk1

Writing disk header: done

Instantiating disk: done

[root@srv1 ~]# oracleasm listdisks

CRS1

CRS2

CRS3

CRSNEW

CRSNEW1

CRSNEW2

CRSNEW3

DATANEW

FRANEW


  • Login to the ASM instance using grid user and check the current diskgroup status.

[root@srv1 ~]# su grid

[grid@srv1 root]$ cd

[grid@srv1 ~]$ . oraenv

ORACLE_SID = [+ASM1] ?

The Oracle base remains unchanged with value /u01/app/grid

[grid@srv1 ~]$ sqlplus / as sysasm


SQL*Plus: Release 12.1.0.2.0 Production on Fri Apr 2 17:45:51 2021


Copyright (c) 1982, 2014, Oracle.  All rights reserved.



Connected to:

Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production

With the Real Application Clusters and Automatic Storage Management options


SQL> 

set lines 999;

col diskgroup for a10

col diskname for a12

col path for a30

select a.name DiskGroup,b.name DiskName, b.total_mb, (b.total_mb-b.free_mb) Used_MB, b.free_mb,b.path,b.header_status from v$asm_disk b, v$asm_diskgroup a where a.group_number (+) =b.group_number order by b.group_number,b.name;


DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU

---------- ------------ ---------- ---------- ---------- ------------------------------ ------------

                                 0          0          0 /dev/oracleasm/disks/CRSNEW    FORMER

                                 0          0          0 /dev/oracleasm/disks/CRSNEW1   PROVISIONED

                                 0          0          0 /dev/oracleasm/disks/CRSNEW3   PROVISIONED

                                 0          0          0 /dev/oracleasm/disks/CRSNEW2   PROVISIONED

CRS        CRS1              12284       1519      10765 /dev/oracleasm/disks/CRS1      MEMBER

CRS        CRS2              12284       1484      10800 /dev/oracleasm/disks/CRS2      MEMBER

CRS        CRS3              12284       1485      10799 /dev/oracleasm/disks/CRS3      MEMBER

DATA       DATA_0001         20473       2476      17997 /dev/oracleasm/disks/DATANEW   MEMBER

FRA        FRA_0001          20473       1075      19398 /dev/oracleasm/disks/FRANEW    MEMBER


9 rows selected.


SQL>  set pages 40000 lines 120

col PATH for a30

select DISK_NUMBER,MOUNT_STATUS,HEADER_STATUS,MODE_STATUS,STATE,PATH FROM V$ASM_DISK;


DISK_NUMBER MOUNT_S HEADER_STATU MODE_ST STATE    PATH

----------- ------- ------------ ------- -------- ------------------------------

          0 CLOSED  FORMER       ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW

          1 CLOSED  PROVISIONED  ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW1

          2 CLOSED  PROVISIONED  ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW3

          3 CLOSED  PROVISIONED  ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW2

          1 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/FRANEW

          3 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRS3

          1 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/DATANEW

          2 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRS2

          0 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRS1


9 rows selected.

  • Add these provisioned disks in CRS diskgroup 

SQL> ALTER DISKGROUP CRS ADD DISK '/dev/oracleasm/disks/CRSNEW1' NAME CRSNEW1,'/dev/oracleasm/disks/CRSNEW2' NAME CRSNEW2,'/dev/oracleasm/disks/CRSNEW3' NAME CRSNEW3;


Diskgroup altered.

  • Check Rebalance operation to complete using below query.

SQL> Select operation, state, est_work, est_minutes from v$asm_operation;


OPERA STAT   EST_WORK EST_MINUTES

----- ---- ---------- -----------

REBAL RUN        2218           3

REBAL WAIT          0           0


SQL> /


OPERA STAT   EST_WORK EST_MINUTES

----- ---- ---------- -----------

REBAL RUN        2218           1

REBAL WAIT          0           0


SQL> /


OPERA STAT   EST_WORK EST_MINUTES

----- ---- ---------- -----------

REBAL DONE       2218           0

REBAL RUN           0           0


SQL> Select operation, state, est_work, est_minutes from v$asm_operation;


OPERA STAT   EST_WORK EST_MINUTES

----- ---- ---------- -----------

REBAL DONE       2218           0

REBAL RUN           0           0


SQL> /


no rows selected


  • Check the status of Diskgroup

SQL> 

set pages 40000 lines 120

col PATH for a30

select DISK_NUMBER,MOUNT_STATUS,HEADER_STATUS,MODE_STATUS,STATE,PATH FROM V$ASM_DISK;


DISK_NUMBER MOUNT_S HEADER_STATU MODE_ST STATE    PATH

----------- ------- ------------ ------- -------- ------------------------------

          0 CLOSED  FORMER       ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW

          1 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/FRANEW

          3 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRS3

          1 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/DATANEW

          2 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRS2

          5 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW3

          0 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRS1

          4 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW2

          1 CACHED  MEMBER       ONLINE  NORMAL   /dev/oracleasm/disks/CRSNEW1


9 rows selected.


SQL> 

set lines 999;

col diskgroup for a10

col diskname for a12

 col path for a30

select a.name DiskGroup,b.name DiskName, b.total_mb, (b.total_mb-b.free_mb) Used_MB, b.free_mb,b.path,b.header_status from v$asm_disk b, v$asm_diskgroup a where a.group_number (+) =b.group_number order by b.group_number,b.name;SQL>


DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU

---------- ------------ ---------- ---------- ---------- ------------------------------ ------------

                                 0          0          0 /dev/oracleasm/disks/CRSNEW    FORMER

CRS        CRS1              12284        778      11506 /dev/oracleasm/disks/CRS1      MEMBER

CRS        CRS2              12284        746      11538 /dev/oracleasm/disks/CRS2      MEMBER

CRS        CRS3              12284        746      11538 /dev/oracleasm/disks/CRS3      MEMBER

CRS        CRSNEW1           12284        743      11541 /dev/oracleasm/disks/CRSNEW1   MEMBER

CRS        CRSNEW2           12284        742      11542 /dev/oracleasm/disks/CRSNEW2   MEMBER

CRS        CRSNEW3           12284        742      11542 /dev/oracleasm/disks/CRSNEW3   MEMBER

DATA       DATA_0001         20473       2476      17997 /dev/oracleasm/disks/DATANEW   MEMBER

FRA        FRA_0001          20473       1075      19398 /dev/oracleasm/disks/FRANEW    MEMBER


9 rows selected.

  • Drop old Diskgroup of CRS with disk CRS1,CRS2,CRS3

SQL> alter diskgroup CRS drop disk 'CRS1';


Diskgroup altered.


SQL> alter diskgroup CRS drop disk 'CRS2';


Diskgroup altered.


SQL> alter diskgroup CRS drop disk 'CRS3';


Diskgroup altered.

  • Check query to complete rebalance operations.

SQL> Select operation, state, est_work, est_minutes from v$asm_operation;


OPERA STAT   EST_WORK EST_MINUTES

----- ---- ---------- -----------

REBAL RUN        2177           2

REBAL WAIT          0           0


SQL> Select operation, state, est_work, est_minutes from v$asm_operation;


OPERA STAT   EST_WORK EST_MINUTES

----- ---- ---------- -----------

REBAL RUN        2177           2

REBAL WAIT          0           0


SQL> /


OPERA STAT   EST_WORK EST_MINUTES

----- ---- ---------- -----------

REBAL RUN        2177           1

REBAL WAIT          0           0


SQL> /


no rows selected

  • Check the current status of disk CRS1, CRS2,CRS3

SQL>

 set lines 999;

col diskgroup for a10

col diskname for a12

col path for a30

select a.name DiskGroup,b.name DiskName, b.total_mb, (b.total_mb-b.free_mb) Used_MB, b.free_mb,b.path,b.header_status from v$asm_disk b, v$asm_diskgroup a where a.group_number (+) =b.group_number order by b.group_number,b.name;




DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU

---------- ------------ ---------- ---------- ---------- ------------------------------ ------------

                                 0          0          0 /dev/oracleasm/disks/CRSNEW    FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS1      FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS3      FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS2      FORMER

CRS        CRSNEW1           12284       1517      10767 /dev/oracleasm/disks/CRSNEW1   MEMBER

CRS        CRSNEW2           12284       1485      10799 /dev/oracleasm/disks/CRSNEW2   MEMBER

CRS        CRSNEW3           12284       1486      10798 /dev/oracleasm/disks/CRSNEW3   MEMBER

DATA       DATA_0001         20473       2476      17997 /dev/oracleasm/disks/DATANEW   MEMBER

FRA        FRA_0001          20473       1075      19398 /dev/oracleasm/disks/FRANEW    MEMBER


9 rows selected.


SQL> /


DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU

---------- ------------ ---------- ---------- ---------- ------------------------------ ------------

                                 0          0          0 /dev/oracleasm/disks/CRSNEW    FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS1      FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS3      FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS2      FORMER

CRS        CRSNEW1           12284       1517      10767 /dev/oracleasm/disks/CRSNEW1   MEMBER

CRS        CRSNEW2           12284       1485      10799 /dev/oracleasm/disks/CRSNEW2   MEMBER

CRS        CRSNEW3           12284       1486      10798 /dev/oracleasm/disks/CRSNEW3   MEMBER

DATA       DATA_0001         20473       2476      17997 /dev/oracleasm/disks/DATANEW   MEMBER

FRA        FRA_0001          20473       1075      19398 /dev/oracleasm/disks/FRANEW    MEMBER


9 rows selected.


SQL> /


DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU

---------- ------------ ---------- ---------- ---------- ------------------------------ ------------

                                 0          0          0 /dev/oracleasm/disks/CRSNEW    FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS1      FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS3      FORMER

                                 0          0          0 /dev/oracleasm/disks/CRS2      FORMER

CRS        CRSNEW1           12284       1517      10767 /dev/oracleasm/disks/CRSNEW1   MEMBER

CRS        CRSNEW2           12284       1485      10799 /dev/oracleasm/disks/CRSNEW2   MEMBER

CRS        CRSNEW3           12284       1486      10798 /dev/oracleasm/disks/CRSNEW3   MEMBER

DATA       DATA_0001         20473       2476      17997 /dev/oracleasm/disks/DATANEW   MEMBER

FRA        FRA_0001          20473       1075      19398 /dev/oracleasm/disks/FRANEW    MEMBER


9 rows selected.


  • Delete Disk at OS level using oracleasm utility


srv1:/home/grid # oracleasm deletedisk CRS1
Disk "CRS1" defines an unmarked device
Dropping disk: done
srv1:/home/grid # oracleasm deletedisk CRS2
Clearing disk header: done
Dropping disk: done
srv1:/home/grid # oracleasm deletedisk CRS3
Clearing disk header: done
Dropping disk: done

SQL> /

  • Check query for current status of ASM Disk group

SQL>

 set lines 999;

col diskgroup for a10

col diskname for a12

col path for a30

select a.name DiskGroup,b.name DiskName, b.total_mb, (b.total_mb-b.free_mb) Used_MB, b.free_mb,b.path,b.header_status from v$asm_disk b, v$asm_diskgroup a where a.group_number (+) =b.group_number order by b.group_number,b.name;

DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU

---------- ------------ ---------- ---------- ---------- ------------------------------ ------------

                                 0          0          0 /dev/oracleasm/disks/CRSNEW    FORMER

CRS        CRSNEW1           12284       1517      10767 /dev/oracleasm/disks/CRSNEW1   MEMBER

CRS        CRSNEW2           12284       1485      10799 /dev/oracleasm/disks/CRSNEW2   MEMBER

CRS        CRSNEW3           12284       1486      10798 /dev/oracleasm/disks/CRSNEW3   MEMBER

DATA       DATA_0001         20473       2476      17997 /dev/oracleasm/disks/DATANEW   MEMBER

FRA        FRA_0001          20473       1075      19398 /dev/oracleasm/disks/FRANEW    MEMBER


6 rows selected.



############## Another Example of Online ASM disk group migration ###############

SQL> set lines 999;

SQL> col diskgroup for a10

SQL> col diskname for a12

SQL> col path for a30
SQL> select a.name DiskGroup,b.name DiskName, b.total_mb, (b.total_mb-b.free_mb) Used_MB, b.free_mb,b.path,b.header_status from v$asm_disk b, v$asm_diskgroup a where a.group_number (+) =b.group_number order by b.group_number,b.name;

DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU
---------- ------------ ---------- ---------- ---------- ------------------------------ ------------
                                 0          0          0 ORCL:CRSNEW1                   PROVISIONED
                                 0          0          0 ORCL:CRSNEW2                   PROVISIONED
                                 0          0          0 ORCL:CRSNEW3                   PROVISIONED
BACKUP     BACKUP            15359         96      15263 ORCL:BACKUP                    MEMBER
CRS        CRS1              12287       3047       9240 ORCL:CRS1                      MEMBER
CRS        CRS2              12287       3046       9241 ORCL:CRS2                      MEMBER
CRS        CRS3              12287       3043       9244 ORCL:CRS3                      MEMBER
DATA       DATA              20479       4249      16230 ORCL:DATA                      MEMBER
FRA        FRA               20479        937      19542 ORCL:FRA                       MEMBER

9 rows selected.



SQL> ALTER DISKGROUP CRS ADD DISK 'ORCL:CRSNEW1' NAME CRSNEW1,'ORCL:CRSNEW2' NAME CRSNEW2,'ORCL:CRSNEW3' NAME CRSNEW3;

Diskgroup altered.

SQL> set lines 999;

col diskgroup for a10

SQL> SQL> SQL> SQL> col diskname for a12

col path for a30

SQL> SQL> SQL> SQL> select a.name DiskGroup,b.name DiskName, b.total_mb, (b.total_mb-b.free_mb) Used_MB, b.free_mb,b.path,b.header_status from v$asm_disk b, v$asm_diskgroup a where a.group_number (+) =b.group_number order by b.group_number,b.name;

DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU
---------- ------------ ---------- ---------- ---------- ------------------------------ ------------
BACKUP     BACKUP            15359         96      15263 ORCL:BACKUP                    MEMBER
CRS        CRS1              12287       3017       9270 ORCL:CRS1                      MEMBER
CRS        CRS2              12287       3014       9273 ORCL:CRS2                      MEMBER
CRS        CRS3              12287       3011       9276 ORCL:CRS3                      MEMBER
CRS        CRSNEW1           12287         34      12253 ORCL:CRSNEW1                   MEMBER
CRS        CRSNEW2           12287         34      12253 ORCL:CRSNEW2                   MEMBER
CRS        CRSNEW3           12287         35      12252 ORCL:CRSNEW3                   MEMBER
DATA       DATA              20479       4249      16230 ORCL:DATA                      MEMBER
FRA        FRA               20479        937      19542 ORCL:FRA                       MEMBER

9 rows selected.





srv1:/home/grid # oracleasm deletedisk CRS1
Disk "CRS1" defines an unmarked device
Dropping disk: done
srv1:/home/grid # oracleasm deletedisk CRS2
Clearing disk header: done
Dropping disk: done
srv1:/home/grid # oracleasm deletedisk CRS3
Clearing disk header: done
Dropping disk: done
srv1:/home/grid # su grid
grid@srv1:~> sqlplus / as sysasm

SQL*Plus: Release 12.1.0.2.0 Production on Thu Apr 8 13:16:53 2021

Copyright (c) 1982, 2014, Oracle.  All rights reserved.


Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Real Application Clusters and Automatic Storage Management options

SQL> set lines 999;

SQL> SQL> col diskgroup for a10

col diskname for a12

SQL> SQL> SQL> SQL> col path for a30

select a.name DiskGroup,b.name DiskName, b.total_mb, (b.total_mb-b.free_mb) Used_MB, b.free_mb,b.path,b.header_status from v$asm_disk b, v$asm_diskgroup a where a.group_number (+) =b.group_number order by b.group_number,b.name;
SQL> SQL>
DISKGROUP  DISKNAME       TOTAL_MB    USED_MB    FREE_MB PATH                           HEADER_STATU
---------- ------------ ---------- ---------- ---------- ------------------------------ ------------
BACKUP     BACKUP            15359         96      15263 ORCL:BACKUP                    MEMBER
CRS        CRSNEW1           12287       3045       9242 ORCL:CRSNEW1                   MEMBER
CRS        CRSNEW2           12287       3046       9241 ORCL:CRSNEW2                   MEMBER
CRS        CRSNEW3           12287       3045       9242 ORCL:CRSNEW3                   MEMBER
DATA       DATA              20479       4249      16230 ORCL:DATA                      MEMBER
FRA        FRA               20479        937      19542 ORCL:FRA                       MEMBER

6 rows selected.


SQL>


srv2:~ # oracleasm scandisks
Reloading disk partitions: done
Cleaning any stale ASM disks...
Cleaning disk "CRS1"
Cleaning disk "CRS2"
Cleaning disk "CRS3"
Scanning system for ASM disks...

srv2:~ # oracleasm listdisks
BACKUP
CRSNEW1
CRSNEW2
CRSNEW3
DATA
FRA
srv2:~ #

Wednesday 7 April 2021

RAC - Rebuild node for surviving node 12.2.0.1.0

 

 Rebuild node for surviving node 12.2.0.1.0

This is lab scenario , OS recreated after making passwordless oracle and grid connection. we proceed further for adding failed node. Here addenode.sh command are almost same but in 12.2.0.1.0 adding HUB or LEAF  "CLUSTER_NEW_NODE_ROLES={HUB}" . In our case it is 2 node RAC grid so we use HUB depends upon option provided earlier.

  • Operating System : OEL 6.7 X 64 bit
  • Oracle Grid version : 12.1.0.2.0
  • Please follow these steps before executing commands Web blog link : Add failed node 12.1.0.2.0 grid
  • Below we add node from srv2 to srv1 server.

[grid@srv2 addnode]$ ./addnode.sh -ignoreSysPrereqs -ignorePrereq -silent "CLUSTER_NEW_NODES={srv1}" "CLUSTER_NEW_VIRTUAL_HOSTNAMES={srv1-vip}" "CLUSTER_NEW_NODE_ROLES={HUB}"


Prepare Configuration in progress.


Prepare Configuration successful.

..................................................   7% Done.


Copy Files to Remote Nodes in progress.

..................................................   12% Done.

..................................................   17% Done.

..............................

Copy Files to Remote Nodes successful.

You can find the log of this install session at:

 /u01/app/oraInventory/logs/addNodeActions2021-04-06_05-34-07-PM.log


Instantiate files in progress.


Instantiate files successful.

..................................................   49% Done.


Saving cluster inventory in progress.

..................................................   83% Done.


Saving cluster inventory successful.

The Cluster Node Addition of /u01/app/12.2.0/grid was successful.

Please check '/u01/app/12.2.0/grid/inventory/silentInstall2021-04-06_5-33-57-PM.log' for more details.


Setup Oracle Base in progress.


Setup Oracle Base successful.

..................................................   90% Done.


Update Inventory in progress.


Update Inventory successful.

..................................................   97% Done.


As a root user, execute the following script(s):

        1. /u01/app/12.2.0/grid/root.sh


Execute /u01/app/12.2.0/grid/root.sh on the following nodes:

[srv1]


The scripts can be executed in parallel on all the nodes.


..................................................   100% Done.

Successfully Setup Software.

[root@srv1 ~]# tail -1000f /u01/app/12.2.0/grid/install/root_srv1.example.com_2021-04-06_18-05-43-573011212.log
Performing root user operation.

The following environment variables are set as:
    ORACLE_OWNER= grid
    ORACLE_HOME=  /u01/app/12.2.0/grid
   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.
Relinking oracle with rac_on option
Using configuration parameter file: /u01/app/12.2.0/grid/crs/install/crsconfig_params
The log of current session can be found at:
  /u01/app/grid/crsdata/srv1/crsconfig/rootcrs_srv1_2021-04-06_06-08-10PM.log
2021/04/06 18:08:20 CLSRSC-594: Executing installation step 1 of 19: 'SetupTFA'.
2021/04/06 18:08:20 CLSRSC-4001: Installing Oracle Trace File Analyzer (TFA) Collector.
2021/04/06 18:10:14 CLSRSC-4002: Successfully installed Oracle Trace File Analyzer (TFA) Collector.
2021/04/06 18:10:14 CLSRSC-594: Executing installation step 2 of 19: 'ValidateEnv'.
2021/04/06 18:10:34 CLSRSC-363: User ignored prerequisites during installation
2021/04/06 18:10:34 CLSRSC-594: Executing installation step 3 of 19: 'CheckFirstNode'.
2021/04/06 18:10:41 CLSRSC-594: Executing installation step 4 of 19: 'GenSiteGUIDs'.
2021/04/06 18:10:44 CLSRSC-594: Executing installation step 5 of 19: 'SaveParamFile'.
2021/04/06 18:11:07 CLSRSC-594: Executing installation step 6 of 19: 'SetupOSD'.
2021/04/06 18:11:09 CLSRSC-594: Executing installation step 7 of 19: 'CheckCRSConfig'.
2021/04/06 18:11:13 CLSRSC-594: Executing installation step 8 of 19: 'SetupLocalGPNP'.
2021/04/06 18:11:27 CLSRSC-594: Executing installation step 9 of 19: 'ConfigOLR'.
2021/04/06 18:11:52 CLSRSC-594: Executing installation step 10 of 19: 'ConfigCHMOS'.
2021/04/06 18:11:52 CLSRSC-594: Executing installation step 11 of 19: 'CreateOHASD'.
2021/04/06 18:12:06 CLSRSC-594: Executing installation step 12 of 19: 'ConfigOHASD'.
2021/04/06 18:12:24 CLSRSC-330: Adding Clusterware entries to file 'oracle-ohasd.conf'
2021/04/06 18:13:24 CLSRSC-594: Executing installation step 13 of 19: 'InstallAFD'.
2021/04/06 18:13:38 CLSRSC-594: Executing installation step 14 of 19: 'InstallACFS'.
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'srv1'
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'srv1' has completed
CRS-4133: Oracle High Availability Services has been stopped.
CRS-4123: Oracle High Availability Services has been started.
2021/04/06 18:15:31 CLSRSC-594: Executing installation step 15 of 19: 'InstallKA'.
2021/04/06 18:15:45 CLSRSC-594: Executing installation step 16 of 19: 'InitConfig'.
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'srv1'
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'srv1' has completed
CRS-4133: Oracle High Availability Services has been stopped.
CRS-4123: Oracle High Availability Services has been started.
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'srv1'
CRS-2673: Attempting to stop 'ora.drivers.acfs' on 'srv1'
CRS-2677: Stop of 'ora.drivers.acfs' on 'srv1' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'srv1' has completed
CRS-4133: Oracle High Availability Services has been stopped.
2021/04/06 18:16:24 CLSRSC-594: Executing installation step 17 of 19: 'StartCluster'.
CRS-4123: Starting Oracle High Availability Services-managed resources
CRS-2672: Attempting to start 'ora.mdnsd' on 'srv1'
CRS-2672: Attempting to start 'ora.evmd' on 'srv1'
CRS-2676: Start of 'ora.mdnsd' on 'srv1' succeeded
CRS-2676: Start of 'ora.evmd' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.gpnpd' on 'srv1'
CRS-2676: Start of 'ora.gpnpd' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.gipcd' on 'srv1'
CRS-2676: Start of 'ora.gipcd' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.cssdmonitor' on 'srv1'
CRS-2676: Start of 'ora.cssdmonitor' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.cssd' on 'srv1'
CRS-2672: Attempting to start 'ora.diskmon' on 'srv1'
CRS-2676: Start of 'ora.diskmon' on 'srv1' succeeded
CRS-2676: Start of 'ora.cssd' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.cluster_interconnect.haip' on 'srv1'
CRS-2672: Attempting to start 'ora.ctssd' on 'srv1'
CRS-2676: Start of 'ora.ctssd' on 'srv1' succeeded
CRS-2676: Start of 'ora.cluster_interconnect.haip' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.asm' on 'srv1'
CRS-2676: Start of 'ora.asm' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.storage' on 'srv1'
CRS-2676: Start of 'ora.storage' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.crf' on 'srv1'
CRS-2676: Start of 'ora.crf' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.crsd' on 'srv1'
CRS-2676: Start of 'ora.crsd' on 'srv1' succeeded
CRS-6017: Processing resource auto-start for servers: srv1
CRS-2672: Attempting to start 'ora.ASMIBNETLSNR_ASM.lsnr' on 'srv1'
CRS-2673: Attempting to stop 'ora.LISTENER_SCAN1.lsnr' on 'srv2'
CRS-2672: Attempting to start 'ora.net1.network' on 'srv1'
CRS-2676: Start of 'ora.net1.network' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.qosmserver' on 'srv1'
CRS-2677: Stop of 'ora.LISTENER_SCAN1.lsnr' on 'srv2' succeeded
CRS-2673: Attempting to stop 'ora.scan1.vip' on 'srv2'
CRS-2672: Attempting to start 'ora.ons' on 'srv1'
CRS-2677: Stop of 'ora.scan1.vip' on 'srv2' succeeded
CRS-2672: Attempting to start 'ora.scan1.vip' on 'srv1'
CRS-2676: Start of 'ora.scan1.vip' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.LISTENER_SCAN1.lsnr' on 'srv1'
CRS-2676: Start of 'ora.ASMIBNETLSNR_ASM.lsnr' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.asm' on 'srv1'
CRS-2676: Start of 'ora.ons' on 'srv1' succeeded
CRS-2676: Start of 'ora.LISTENER_SCAN1.lsnr' on 'srv1' succeeded
CRS-2676: Start of 'ora.asm' on 'srv1' succeeded
CRS-2672: Attempting to start 'ora.DATA.dg' on 'srv1'
CRS-2672: Attempting to start 'ora.FRA.dg' on 'srv1'
CRS-2676: Start of 'ora.DATA.dg' on 'srv1' succeeded
CRS-2676: Start of 'ora.FRA.dg' on 'srv1' succeeded
CRS-2676: Start of 'ora.qosmserver' on 'srv1' succeeded
CRS-6016: Resource auto-start has completed for server srv1
CRS-6024: Completed start of Oracle Cluster Ready Services-managed resources
CRS-4123: Oracle High Availability Services has been started.
2021/04/06 18:18:25 CLSRSC-343: Successfully started Oracle Clusterware stack
2021/04/06 18:18:25 CLSRSC-594: Executing installation step 18 of 19: 'ConfigNode'.
clscfg: EXISTING configuration version 5 detected.
clscfg: version 5 is 12c Release 2.
Successfully accumulated necessary OCR keys.
Creating OCR keys for user 'root', privgrp 'root'..
Operation successful.

2021/04/06 18:20:26 CLSRSC-594: Executing installation step 19 of 19: 'PostConfig'.
PRCR-1013 : Failed to start resource ora.LISTENER.lsnr

PRCR-1064 : Failed to start resource ora.LISTENER.lsnr on node srv1

CRS-5016: Process "/u01/app/12.2.0/grid/bin/lsnrctl" spawned by agent "ORAAGENT" for action "start" failed: details at "(:CLSN00010:)" in "/u01/app/grid/diag/crs/srv1/crs/trace/crsd_oraagent_grid.trc"

CRS-5016: Process "/u01/app/12.2.0/grid/bin/lsnrctl" spawned by agent "ORAAGENT" for action "start" failed: details at "(:CLSN00010:)" in "/u01/app/grid/diag/crs/srv1/crs/trace/crsd_oraagent_grid.trc"

CRS-2674: Start of 'ora.LISTENER.lsnr' on 'srv1' failed

2021/04/06 18:20:44 CLSRSC-180: An error occurred while executing the command '/u01/app/12.2.0/grid/bin/srvctl start listener -n srv1'
2021/04/06 18:21:02 CLSRSC-325: Configure Oracle Grid Infrastructure for a Cluster ... succeeded


^C
[root@srv1 ~]#

Monday 5 April 2021

SLES 12 SP4 DNS configuration for RAC setup 12 R1

 SLES 12 SP4 DNS configuration for RAC setup 12 c


Operating System: SLES 12 SP4 64 bit

  •  zypper -n install bind-chrootenv
  • resolv.conf
  • forward.zone
  • named.rfc1912.zones
  • service named status
  • nslookup srv-scan
  • /etc/hosts



  • resolv.conf
srv1:/var/lib/named/etc # cat /etc/resolv.conf
### /etc/resolv.conf file autogenerated by netconfig!
#
# Before you change this file manually, consider to define the
# static DNS configuration using the following variables in the
# /etc/sysconfig/network/config file:
#     NETCONFIG_DNS_STATIC_SEARCHLIST
#     NETCONFIG_DNS_STATIC_SERVERS
#     NETCONFIG_DNS_FORWARDER
# or disable DNS configuration updates via netconfig by setting:
#     NETCONFIG_DNS_POLICY=''
#
# See also the netconfig(8) manual page and other documentation.
#
# Note: Manual change of this file disables netconfig too, but
# may get lost when this file contains comments or empty lines
# only, the netconfig settings are same with settings in this
# file and in case of a "netconfig update -f" call.
#
### Please remove (at least) this line when you modify the file!
search suse
search example.com
nameserver srv-scan.example.com
domain example.com

srv1:/var/lib/named/etc #

:~# chattr +i /etc/resolv.conf (to make permanent entry on resolv.conf entry)
  • forward.zone

srv1:/var/lib/named/etc # vi  forward.zone

; /var/lib/named/etc/forward.zone

$TTL 86400

@ IN SOA srv-scan.example.com. root.srv-scan.example.com. (

     0 ; serial

     1D ; refresh

     1H ; retry

     1W ; expire

     3H ) ; minimum

     IN NS srv-scan.example.com.

srv-scan A 192.168.56.91

srv-scan A 192.168.56.92

srv-scan A 192.168.56.93


  • named.rfc1912.zones

srv1:/var/lib/named/etc #vi named.rfc1912.zones

// See /usr/share/doc/bind*/sample/ for example named configuration files.

//

zone "." IN {

type hint;

file "named.ca";

};

zone "example.com" IN {

type master;

file "forward.zone";

allow-update { none; };

};

zone "localhost" IN {

type master;

file "localhost.zone";

allow-update { none; };

};

zone "56.168.192.in-addr.arpa" IN {

type master;

file "reverse.zone";

allow-update { none; };

};

#zone "0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa" IN {

#type master;

#file "named.ip6.local";

#allow-update { none; };

#};

zone "255.in-addr.arpa" IN {

type master;

file "named.broadcast";

allow-update { none; };

};

#zone "0.in-addr.arpa" IN {

#type master;Oracle 11gR2 RAC On VM - INSTALLATION

#www.reachdba.com | www.dbalounge.com | info@dbalounge.com | 011-40581394

#file "named.zero";

#allow-update { none; };

#};

  • reverse.zone

srv1:/var/lib/named/etc # vi  reverse.zone

;  /var/lib/named/etc/reverse.zone

$TTL 86400

@ IN SOA srv-scan.example.com. root.srv-scan.example.com. (

    0 ; serial

    1D ; refresh

    1H ; retry

    1W ; expire

    3H ) ; minimum

    NS srv-scan.example.com.

91 PTR srv-scan.example.com.

92 PTR srv-scan.example.com.

93 PTR srv-scan.example.com.

srv1:/var/lib/named/etc #


  • service named status
  • service named stop
  • service named start

srv1:/var/lib/named/etc # service named status

● named.service - LSB: Domain Name System (DNS) server, named

   Loaded: loaded (/etc/init.d/named; bad; vendor preset: disabled)

   Active: active (running) since Wed 2021-04-07 12:41:50 IST; 10min ago

     Docs: man:systemd-sysv-generator(8)

  Process: 11711 ExecStop=/etc/init.d/named stop (code=exited, status=0/SUCCESS)

  Process: 11738 ExecStart=/etc/init.d/named start (code=exited, status=0/SUCCESS)

    Tasks: 4 (limit: 512)

   CGroup: /system.slice/named.service

           └─11787 /usr/sbin/named -t /var/lib/named -u named


Apr 07 12:41:50 srv1 named[11787]: managed-keys-zone: loaded serial 0

Apr 07 12:41:50 srv1 named[11787]: zone example.com/IN: loaded serial 0

Apr 07 12:41:50 srv1 named[11787]: zone 0.0.127.in-addr.arpa/IN: loaded serial 42

Apr 07 12:41:50 srv1 named[11787]: zone 56.168.192.in-addr.arpa/IN: loaded serial 0

Apr 07 12:41:50 srv1 named[11787]: zone localhost/IN: loaded serial 42

Apr 07 12:41:50 srv1 named[11787]: zone 0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa/IN: loaded serial 42

Apr 07 12:41:50 srv1 named[11787]: all zones loaded

Apr 07 12:41:50 srv1 named[11738]: Starting name server BIND ..done

Apr 07 12:41:50 srv1 systemd[1]: Started LSB: Domain Name System (DNS) server, named.

Apr 07 12:41:50 srv1 named[11787]: running

srv1:/var/lib/named/etc #


  • /etc/named.conf
srv1:/var/lib/named/etc # vi  /etc/named.conf

# Copyright (c) 2001-2004 SuSE Linux AG, Nuernberg, Germany.

# All rights reserved.

#

# Author: Frank Bodammer, Lars Mueller <lmuelle@suse.de>

#

# /etc/named.conf

#

# This is a sample configuration file for the name server BIND 9.  It works as

# a caching only name server without modification.

#

# A sample configuration for setting up your own domain can be found in

# /usr/share/doc/packages/bind/sample-config.

#

# A description of all available options can be found in

# /usr/share/doc/packages/bind/misc/options.


options {


        # The directory statement defines the name server's working directory


        directory "/var/lib/named";


        # enable DNSSEC validation

        #

        # If BIND logs error messages about the root key being expired, you

        # will need to update your keys. See https://www.isc.org/bind-keys

        #

        # dnssec-enable yes (default), indicates that a secure DNS service

        # is being used which may be one, or more, of TSIG

        # (for securing zone transfers or DDNS updates), SIG(0)

        # (for securing DDNS updates) or DNSSEC.


        #dnssec-enable yes;


        # dnssec-validation yes (default), indicates that a resolver

        # (a caching or caching-only name server) will attempt to validate

        # replies from DNSSEC enabled (signed) zones. To perform this task

        # the server also needs either a valid trusted-keys clause

        # (containing one or more trusted-anchors or a managed-keys clause.


        #dnssec-validation auto;

        managed-keys-directory "/var/lib/named/dyn/";


        # Write dump and statistics file to the log subdirectory.  The

        # pathenames are relative to the chroot jail.


        dump-file "/var/log/named_dump.db";

        statistics-file "/var/log/named.stats";


        # The forwarders record contains a list of servers to which queries

        # should be forwarded.  Enable this line and modify the IP address to

        # your provider's name server.  Up to three servers may be listed.


        #forwarders { 192.0.2.1; 192.0.2.2; };


        # Enable the next entry to prefer usage of the name server declared in

        # the forwarders section.


        #forward first;


        # The listen-on record contains a list of local network interfaces to

        # listen on.  Optionally the port can be specified.  Default is to

        # listen on all interfaces found on your system.  The default port is

        # 53.


        #listen-on port 53 { 127.0.0.1; };


        # The listen-on-v6 record enables or disables listening on IPv6

        # interfaces.  Allowed values are 'any' and 'none' or a list of

        # addresses.


        listen-on-v6 { any; };


        # The next three statements may be needed if a firewall stands between

        # the local server and the internet.


        #query-source address * port 53;

        #transfer-source * port 53;

        #notify-source * port 53;


        # The allow-query record contains a list of networks or IP addresses

        # to accept and deny queries from. The default is to allow queries

        # from all hosts.


        #allow-query { 127.0.0.1; };


        # If notify is set to yes (default), notify messages are sent to other

        # name servers when the the zone data is changed.  Instead of setting

        # a global 'notify' statement in the 'options' section, a separate

        # 'notify' can be added to each zone definition.


        notify no;


    disable-empty-zone "1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA";

};


# To configure named's logging remove the leading '#' characters of the

# following examples.

#logging {

#       # Log queries to a file limited to a size of 100 MB.

#       channel query_logging {

#               file "/var/log/named_querylog"

#                       versions 3 size 100M;

#               print-time yes;                 // timestamp log entries

#       };

#       category queries {

#               query_logging;

#       };

#

#       # Or log this kind alternatively to syslog.

#       channel syslog_queries {

#               syslog user;

#               severity info;

#       };

#       category queries { syslog_queries; };

#

#       # Log general name server errors to syslog.

#       channel syslog_errors {

#               syslog user;

#               severity error;

#       };

#       category default { syslog_errors;  };

#

#       # Don't log lame server messages.

#       category lame-servers { null; };

#};


# The following zone definitions don't need any modification.  The first one

# is the definition of the root name servers.  The second one defines

# localhost while the third defines the reverse lookup for localhost.


zone "." in {

        type hint;

        file "root.hint";

};


zone "localhost" in {

        type master;

        file "localhost.zone";

};


zone "0.0.127.in-addr.arpa" in {

        type master;

        file "127.0.0.zone";

};


zone "0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa" IN {

    type master;

    file "127.0.0.zone";

};

zone "example.com" IN {

type master;

file "forward.zone";

allow-update { none; };

};

zone "56.168.192.in-addr.arpa" IN {

type master;

file "reverse.zone";

allow-update { none; };

};


# Include the meta include file generated by createNamedConfInclude.  This

# includes all files as configured in NAMED_CONF_INCLUDE_FILES from

# /etc/sysconfig/named


include "/etc/named.conf.include";


# You can insert further zone records for your own domains below or create

# single files in /etc/named.d/ and add the file names to

# NAMED_CONF_INCLUDE_FILES.

# See /usr/share/doc/packages/bind/README.SUSE for more details.

srv1:/var/lib/named/etc #


  • Check using nslookup 

srv1:/var/lib/named/etc # nslookup srv-scan

Server:         127.0.0.1

Address:        127.0.0.1#53


Name:   srv-scan.example.com

Address: 192.168.56.93

Name:   srv-scan.example.com

Address: 192.168.56.91

Name:   srv-scan.example.com

Address: 192.168.56.92


srv1:/var/lib/named/etc # nslookup srv-scan

Server:         127.0.0.1

Address:        127.0.0.1#53


Name:   srv-scan.example.com

Address: 192.168.56.92

Name:   srv-scan.example.com

Address: 192.168.56.93

Name:   srv-scan.example.com

Address: 192.168.56.91


srv1:/var/lib/named/etc # nslookup srv-scan

Server:         127.0.0.1

Address:        127.0.0.1#53


Name:   srv-scan.example.com

Address: 192.168.56.93

Name:   srv-scan.example.com

Address: 192.168.56.91

Name:   srv-scan.example.com

Address: 192.168.56.92



  • cat /etc/hosts
127.0.0.1   localhost.localdomain localhost
# Public
192.168.56.71   srv1.example.com        srv1
192.168.56.72   srv2.example.com        srv2

# Private
192.168.10.1    srv1-priv.example.com   srv1-priv
192.168.10.2    srv2-priv.example.com   srv2-priv

# Virtual
192.168.56.81   srv1-vip.example.com    srv1-vip
192.168.56.82   srv2-vip.example.com    srv2-vip

# SCAN (in production this should be configured in DNS)
192.168.56.91   srv-scan.example.com    srv-scan
192.168.56.92   srv-scan.example.com    srv-scan
192.168.56.93   srv-scan.example.com    srv-scan