Happy to announce that my second book as Co-Author is releasing soon.
Books can be pre-ordered at below.
Amazon
BarnesandNoble
Happy to announce that my second book as Co-Author is releasing soon.
Books can be pre-ordered at below.
Amazon
BarnesandNoble
In this post we will see how we can we DML Redirection feature in Oracle 19c Active Data Guard Standby.
Primary Source Environment setup
RAC Database : RENODBPR ( renodbpr1 & renodbpr2)
PDB : ONEPDB
GRID Home : /u01/app/19.3.0.0/grid
RDBMS Home : /u01/app/oracle/product/19.3.0.0/db_1
Version : Oracle Database 19c EE - Production Version 19.17.0.0.0
hosts : labhost01
labhost02
Standby database environment setup
RAC Database : RENODBDR ( renodbdr1 & renodbdr2)
GRID Home : /u01/app/19.3.0.0/grid
RDBMS Home : /u01/app/oracle/product/19.3.0.0/dbhome_1
Version : Oracle Database 19c EE - Production Version 19.17.0.0.0
hosts : labdrhost01
labdrhost02
What is DML redirection feature ?
DML Redirection is new feature in Oracle 19c which allows DML operations to be executed on an Active Data Guard standby database.
How it works : When a user performs a DML operation in the Active Standby database, the DML operation is actually passed to the Primary database where it is executed and the redo generated from that particular DML operation will be shipped and applied in the Standby database and after that the control is returned to the user who ran the command.
Lets see how it works.
We have this schema, appuser in the pluggable database, onepdb.
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 ONEPDB READ WRITE YES
SQL>
Recently we started observing this issue where when we try to connect OUD integrated Oracle database and got the below exception..
"dbhost01:/u01/app/oracle->sqlplus globaluser1@TESTDB
SQL*Plus: Release 12.1.0.2.0 Production on Fri Mar 3 18:31:16 2023
Copyright (c) 1982, 2014, Oracle. All rights reserved.
Enter password:
ERROR:
ORA-28030: Server encountered problems accessing LDAP directory service"
First we need to identify the exact cause that's forcing the connection to give this particular error.
Enable the tracing as shown below in the oracle database and then try the connection.
1) Enable 28033 event tracing using below SQL.
SQL> alter system set events '28033 trace name context forever, level 9';
2) Run the sqlplus connection again.
sqlplus globaluser1@TESTDB
3) Disable the tracing using below SQL.
SQL> alter system set events '28033 trace name context off';
4) Check the dump directory for the trace it generated
In my case, it generated below trace.
/oracle/app/diag/rdbms/testdb1/TESTDB/trace/TESTDB1_ora_142721.trc
As you can see from the 2nd line that its not able to get the correct credentials from the wallet.
kzld_discover received ldaptype: OID
KZLD_ERR: failed to get cred from wallet <--------------------------------------------
KZLD_ERR: Failed to bind to LDAP server. Err=28032
KZLD_ERR: 28032
KZLD is doing LDAP unbind
KZLD_ERR: found err from kzldini.
I ran into below error when performed a switchover operation in my dataguard configuration which has one primary and two standby databases.
"ORA-16597: Oracle Data Guard broker detects two or more primary databases"
Please see below
[oracle@dbhost01 ]$ dgmgrl /
DGMGRL for Linux: Release 19.0.0.0.0 - Production on Wed Apr 19 15:13:05 2023
Version 19.19.0.0.0
Copyright (c) 1982, 2019, Oracle and/or its affiliates. All rights reserved.
Welcome to DGMGRL, type "help" for information.
Connected to "tureepr"
Connected as SYSDG.
DGMGRL> connect sys/ringrose;
Connected to "tureepr"
Connected as SYSDBA.
DGMGRL> show configuration;
Configuration - tureepr_cfg
Protection Mode: MaxPerformance
Members:
tureepr - Primary database
tureedr - Physical standby database
tureetr - Physical standby database
Fast-Start Failover: Disabled
Configuration Status:
SUCCESS (status updated 35 seconds ago)
Performing the swithcover operation.
DGMGRL> switchover to tureetr;
Performing switchover NOW, please wait...
Operation requires a connection to database "tureetr"
Connecting ...
Connected to "tureetr"
Connected as SYSDBA.
New primary database "tureetr" is opening...
Oracle Clusterware is restarting database "tureepr" ...
Connected to "tureepr"
Switchover succeeded, new primary is "tureetr"
DGMGRL>
DGMGRL> show configuration;
Configuration - tureepr_cfg
Protection Mode: MaxPerformance
Members:
tureetr - Primary database
tureepr - Physical standby database
tureedr - Physical standby database (disabled)
ORA-16597: Oracle Data Guard broker detects two or more primary databases
Fast-Start Failover: Disabled
Configuration Status:
SUCCESS (status updated 60 seconds ago)
DGMGRL>
Even though the switchover was completed successfully, for some reason, I see one of the second standby database in disabled state and I also see below error.
ORA-16597: Oracle Data Guard broker detects two or more primary databases
First, I went ahead and enabled the second standby database which got disabled during the switchover operation
DGMGRL> enable database tureedr
Enabled.
DGMGRL>
Surprisingly When I checked the configuration, I saw that the configuration came back to normal, wondering how and why ...
DGMGRL> show configuration;
Configuration - tureepr_cfg
Protection Mode: MaxPerformance
Members:
tureetr - Primary database
tureepr - Physical standby database
tureedr - Physical standby database
Fast-Start Failover: Disabled
Configuration Status:
SUCCESS (status updated 52 seconds ago)
DGMGRL>
Today I was apply the 19.19 RU to my LAB RAC environment and after applying the patch for database home, the opatchauto failed with the 'checkSystemspace' error while applying the patch to grid home.
I did ran the 'CheckSystemSpace' check before applying the patch and it completed successfully and it didnt raised any flag with space.
May the space got filled in the cfgtools during the patching which resulted in the space issue.
Anyhow, I cleaned up space the space and resumed the opatchauto as below and this time it went through.
Oracle had released the April,2023 Release update for the available versions. Below are the details of patches for 19c versions.
Patch - Description
----------- -----------------------------------------------------
35037840 - GI Release Update 19.19.0.0.230418
35042068 - Database Release Update 19.19.0.0.230418
35050331 - OCW Release Update 19.19.0.0.230418
35050325 - ACFS Release Update 19.19.0.0.230418
35107512 - Tomcat Release Update 19.0.0.0.0
33575402 - DBWLM Release Update 19.0.0.0.0
In the next blog post, we will see how to apply the 19.19 RU to the 19c RAC environment.
Thanks
Sambaiah Sammeta