Sunday, November 4, 2018

ORA-12012: error on auto execute of job "SYS"."ORA$AT_OS_OPT_SY_16656"

Error

ORA-12012: error on auto execute of job "SYS"."ORA$AT_OS_OPT_SY_16656"
ORA-20001: Statistics Advisor: Invalid task name for the current user
ORA-06512: at "SYS.DBMS_STATS", line 47207
ORA-06512: at "SYS.DBMS_STATS_ADVISOR", line 882
ORA-06512: at "SYS.DBMS_STATS_INTERNAL", line 20059
ORA-06512: at "SYS.DBMS_STATS_INTERNAL", line 22201
ORA-06512: at "SYS.DBMS_STATS", line 47197

Cause Its an known BUG, Advisory packages were not created properly during database creation.

Solution

Verify advisory packages are exist or not, if you are getting these errors means you will not found these objects.

select name, ctime, how_created
from sys.wri$_adv_tasks
where owner_name = 'SYS'
and name in ('AUTO_STATS_ADVISOR_TASK','INDIVIDUAL_STATS_ADVISOR_TASK');

no rows selected

Create these objects using below command

SQL> EXEC dbms_stats.init_package();

PL/SQL procedure successfully completed.


Friday, October 19, 2018

Resource manager plan is not active or is not managing CPU usage


Error

SQL> EXECUTE dbms_stats.gather_table_stats(ownname=>'ROCFM',tabname=>'SUBSCRIBER',cascade=>true);
BEGIN dbms_stats.gather_table_stats(ownname=>'ROCFM',tabname=>'SUBSCRIBER',cascade=>true); END;

*
ERROR at line 1:
ORA-20000: Unable to gather statistics concurrently: Resource manager plan is not active or is not managing CPU usage
ORA-06512: at "SYS.DBMS_STATS", line 34757

ORA-06512: at line 1


Cause

Resource Manager must be enabled in 12c in order to use any value other than OFF for the CONCURRENT preference (which enables concurrent statistics gathering).

Solution

SQL> alter system set resource_manager_plan = 'DEFAULT_PLAN' ;

System altered.

SQL> EXECUTE dbms_stats.gather_table_stats(ownname=>'ROCFM',tabname=>'SUBSCRIBER',cascade=>true);


PL/SQL procedure successfully completed.


SQL> 

Saturday, October 13, 2018

How to Stop Oracle Audit Vault Services


Simple article on stopping Oracle Audit Vault Services.

Follow below  sequence of steps:

/usr/local/dbfw/bin/javafwk stop --> From root
/usr/local/dbfw/bin/dbfwdb stop --> From oracle
/usr/local/dbfw/bin/asmdb stop --> From root

[root@auditvault02 ~]# /usr/local/dbfw/bin/javafwk stop
Stopping Java framework...                                 [  OK  ]
[root@auditvault02 ~]#

[root@auditvault02 ~]# su - oracle
[oracle@auditvault02 ~]$
[oracle@auditvault02 ~]$ /usr/local/dbfw/bin/dbfwdb stop
Shutting down the database
Database shut down
[oracle@auditvault02 ~]$
[oracle@auditvault02 ~]$ lsnrctl stop

LSNRCTL for Linux: Version 12.1.0.2.0 - Production on 27-SEP-2018 10:51:53

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

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521)))
The command completed successfully
[oracle@auditvault02 ~]$
[oracle@auditvault02 ~]$

[root@auditvault02 ~]#
[root@auditvault02 ~]# /usr/local/dbfw/bin/asmdb stop
[root@auditvault02 ~]#

[root@auditvault02 ~]#
[root@auditvault02 ~]# su - grid
[grid@auditvault02 ~]$ lsnrctl stop LISTENER_ASM

LSNRCTL for Linux: Version 12.1.0.2.0 - Production on 27-SEP-2018 10:51:34

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

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1523)))
The command completed successfully
[grid@auditvault02 ~]$


Now follow the reverse to restart up avdf DB and APP services.

Friday, September 28, 2018

Output file was found but is zero sized - Deleted

Output file was found but is zero sized - Deleted

I go a call from our developer that request are completing in warning status.

On investigation i found blow errors in OPP logs.

Error

[092618_131735369][][EXCEPTION] [DEBUG]  [sun.cpu.isalist]:[]
[9/26/18 1:17:35 PM] [1648558:RT19832034] Output file was found but is zero sized - Deleted
[9/26/18 1:17:35 PM] [UNEXPECTED] [1648558:RT19832034] java.io.FileNotFoundException: /d01/Prod/temp_xml/xdo6QGDTbJCca092618_1317356982.fo (Permission denied)
        at java.io.FileOutputStream.open(Native Method)
        at java.io.FileOutputStream.<init>(FileOutputStream.java:194)
        at java.io.FileOutputStream.<init>(FileOutputStream.java:145)
        at oracle.apps.xdo.common.tmp.TmpFile.createTmpFileJDK118(TmpFile.java:146)
        at oracle.apps.xdo.common.tmp.TmpFile.createTmpFile(TmpFile.java:113)
        at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:987)
        at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:212)
        at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1647)
        at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:941)
        at oracle.apps.xdo.oa.schema.server.TemplateHelper.runProcessTemplate(TemplateHelper.java:5936)
        at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3459)
        at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3548)
        at oracle.apps.fnd.cp.opp.XMLPublisherProcessor.process(XMLPublisherProcessor.java:302)
        at oracle.apps.fnd.cp.opp.OPPRequestThread.run(OPPRequestThread.java:176)

[9/26/18 1:17:35 PM] [1648558:RT19832034] Completed post-processing actions for request 19832034.


Cause 

The Temporary directory for XML Publisher has not been modified after making the clone so it was pointing to non existing location and getting error out.

Solution

1. Create a new Temporary Directory on OS level for the cloned environment.
2. Make sure that the application owner (APPLMGR) has Read and Write permission this directory.
3. Setup this new directory for XML Publisher via : XML Publisher Administrator responsibility: Properties -> General -> Temporary Directory.
3. Restart the Server.
4. Test again with a XML Publisher Report.


Thursday, September 13, 2018

Disable BI Publisher Enterprise Manager 13c


Enterprise Manager 13c – Disable the BI Publisher

The BI Publisher will be started automatically during the startup process of the Enterprise Manager 13c. You don’t like the BI Publisher or you don’t use it? Save the resources, speed up your startup process, disable it. The password of the database repository owner SYSMAN is required.

Verify the Status – the BI Publisher is up and running

[oracle@vivaoem bin]$ ./emctl status oms
Oracle Enterprise Manager Cloud Control 13c Release 1
Copyright (c) 1996, 2015 Oracle Corporation.  All rights reserved.
WebTier is Up
Oracle Management Server is Up
JVMD Engine is Up
BI Publisher Server is Up
[oracle@vivaoem bin]$

Yes it was up, lets disable it.

[oracle@vivaoem bin]$ ./emctl config oms -disable_bip
Oracle Enterprise Manager Cloud Control 13c Release 1
Copyright (c) 1996, 2015 Oracle Corporation.  All rights reserved.
Enter Enterprise Manager Root (SYSMAN) Password :
Stopping BI Publisher Server...
BI Publisher Server Successfully Stopped
BI Publisher Server is Down
BI Publisher has been disabled on this host and will not be started with the 'emctl start oms' or 'emctl start oms -bip_only' commands.
Overall result of operations: SUCCESS
[oracle@vivaoem bin]$
[oracle@vivaoem bin]$ ./emctl status oms
Oracle Enterprise Manager Cloud Control 13c Release 1
Copyright (c) 1996, 2015 Oracle Corporation.  All rights reserved.
WebTier is Up
Oracle Management Server is Up
JVMD Engine is Up
BI Publisher Server is Down
BI Publisher is disabled, to enable BI Publisher on this host, use the 'emctl config oms -enable_bip' command
[oracle@vivaoem bin]$

Please note its just an temporary disable, on future restart of EM services BIP will be started again, you need to disable it again.


RMAN-06026: some targets not found - aborting restore

I was cloning one of our TEST and server and stuckup on "RMAN-06026 and RMAN-06023" while restoring database.

RMAN> run
{
SET NEWNAME FOR DATABASE   TO  '/u01/oracle/app/gbldrsdata/%b';
SET NEWNAME FOR tempfile  1 TO '/u01/oracle/app/gbldrsdata/%b';
restore database ;
switch datafile all;
switch tempfile all;
set until sequence 20686 thread 1;
recover database;
}2> 3> 4> 5> 6> 7> 8> 9> 10>

executing command: SET NEWNAME
executing command: SET NEWNAME

Starting restore at 10-AUG-18
using channel ORA_DISK_1
using channel ORA_DISK_2

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 08/10/2018 00:52:27
RMAN-06026: some targets not found - aborting restore
RMAN-06023: no backup or copy of datafile 4 found to restore
RMAN-06023: no backup or copy of datafile 3 found to restore
RMAN-06023: no backup or copy of datafile 2 found to restore
RMAN-06023: no backup or copy of datafile 1 found to restore

RMAN>

After drill-down i found that there are some backup files in FRA that belongs to OLD INCARNATION, as i was not interested in these files i have disabled FRA.

commented *.db_recovery_file_dest and *.db_recovery_file_dest_size in pfile and restarted restore and it went successful.


Function not available to this responsibility When Trying to Access Custom Form

When attempting to access custom forms, the following error occurs.

"Function not available to this responsibility. Change Responsibilities or contact your System Administrator".

Cause: Missing entry of CUSTOM_TOP under default.env file.

Solution:

Below procedure requrired to function cutom entry

1. Add  missing CUSTOM_TOP entry to $INST_TOP/ora/10.1.2/forms/server/default.env
XX_TOP=/d01/Prod/apps/apps_st/appl/xx_top/12.0.0

2. Add XX_TOP entry to CONTEXT_FILE

<XX_TOP oa_var="s_xxtop" oa_type="PROD_TOP" oa_enabled="FALSE">/d01/Prod/apps/apps_st/appl/xx_top/12.0.0</XX_TOP>

3. source APPSPROD_XXX.env

4. Restart Middle Tier services.

SQL Net client trace


1. Add following parameters in the sqlnet.ora file in CLIENT machine

TRACE_LEVEL_CLIENT = 16
TRACE_FILE_CLIENT = CLIENT
TRACE_DIRECTORY_CLIENT = D:\TRACE
TRACE_UNIQUE_CLIENT = ON
LOG_FILE_CLIENT = CLIENT
LOG_DIRECTORY_CLIENT = D:\TRACE\LOG
TNSPING.TRACE_DIRECTORY = D:\TRACE\TRACE
TNSPING.TRACE_LEVEL = ADMIN

2. Reproduce the issue to find error

3. Disable tracing by removing above entries from sqlnet.ora after generating trace.

DB_UNIQUE_NAME Conflict on Exadata


I was trying to restore one of our database on Supercluster M7 server and i came across error in controlfile file restore itself.

RMAN> run
{
allocate channel c1 type 'sbt_tape';
SEND 'NB_ORA_SERV=bkppdb01, NB_ORA_CLIENT=monetadb01-bkp';
restore controlfile from 'cntrl_FMREF_bnt98v1v_1_1';
RELEASE CHANNEL c1;
}2> 3> 4> 5> 6> 7>

using target database control file instead of recovery catalog
allocated channel: c1
channel c1: SID=1141 instance=fmref1 device type=SBT_TAPE
channel c1: Veritas NetBackup for Oracle - Release 7.7.3 (2016051915)

sent command to channel: c1

Starting restore at 05-AUG-18

channel c1: restoring control file
released channel: c1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 08/05/2018 14:55:47
ORA-19870: error while restoring backup piece cntrl_FMREF_bnt98v1v_1_1
ORA-19504: failed to create file "+TSTDATA1"
ORA-15045: ASM file name '+TSTDATA1' is not in reference form
ORA-17502: ksfdcre:5 Failed to create file +TSTDATA1

RMAN>

This backup piece was valid so errors surprised me, on investigation i met some informative errors in asm log as below.

Errors in file /u01/app/oratst/diag/rdbms/fmref/fmref1/trace/fmref1_ora_1268.trc:
ORA-15025: could not open disk "o/192.168.XX.XX;192.168.XX.XX/TSTDATA1_CD_06_vsc02celadm02"
Sun Aug 05 14:55:37 2018
WARNING: Write Failed. group:1 disk:18 AU:18379 offset:0 size:16384
path:Unknown disk
         incarnation:0x12 synchronous result:'I/O error'
         subsys:Unknown library krq:0xffffffff7942e520 bufp:0xffffffff7902b000 osderr1:0xf4 osderr2:0x0
         IO elapsed time: 0 usec Time waited on I/O: 0 usec
Sun Aug 05 14:55:37 2018
Errors in file /u01/app/oratst/diag/rdbms/fmref/fmref1/trace/fmref1_ora_1268.trc:
ORA-15025: could not open disk "o/192.168.XX.XX;192.168.XX.XX/TSTDATA1_CD_11_vsc02celadm03"
WARNING: Write Failed. group:1 disk:35 AU:18408 offset:0 size:16384
path:Unknown disk
         incarnation:0x12 synchronous result:'I/O error'
         subsys:Unknown library krq:0xffffffff786b8030 bufp:0xffffffff7902b000 osderr1:0xf4 osderr2:0x0
         IO elapsed time: 0 usec Time waited on I/O: 0 usec
Sun Aug 05 14:55:37 2018
Errors in file /u01/app/oratst/diag/rdbms/fmref/fmref1/trace/fmref1_ora_1268.trc:
ORA-15025: could not open disk "o/192.168.XX.XX;192.168.XX.XX/TSTDATA1_CD_00_vsc02celadm01"
WARNING: Write Failed. group:1 disk:0 AU:18389 offset:0 size:16384
path:Unknown disk
         incarnation:0x12 synchronous result:'I/O error'
         subsys:Unknown library krq:0xffffffff786b7ba8 bufp:0xffffffff7902b000 osderr1:0xf4 osderr2:0x0
         IO elapsed time: 0 usec Time waited on I/O: 0 usec
Sun Aug 05 14:55:37 2018
Errors in file /u01/app/oratst/diag/rdbms/fmref/fmref1/trace/fmref1_ora_1268.trc:
ORA-15080: synchronous I/O operation failed to write block 0 of disk 18 in disk group TSTDATA1
WARNING: failed to write mirror side 1 of virtual extent 0 logical extent 0 of file 332 in group 1 on disk 18 allocation unit 18379
Sun Aug 05 14:55:37 2018
Errors in file /u01/app/oratst/diag/rdbms/fmref/fmref1/trace/fmref1_ora_1268.trc:
ORA-15080: synchronous I/O operation failed to write block 0 of disk 35 in disk group TSTDATA1
WARNING: failed to write mirror side 2 of virtual extent 0 logical extent 1 of file 332 in group 1 on disk 35 allocation unit 18408
Sun Aug 05 14:55:37 2018
Errors in file /u01/app/oratst/diag/rdbms/fmref/fmref1/trace/fmref1_ora_1268.trc:
ORA-15080: synchronous I/O operation failed to write block 0 of disk 0 in disk group TSTDATA1
WARNING: failed to write mirror side 3 of virtual extent 0 logical extent 2 of file 332 in group 1 on disk 0 allocation unit 18389
WARNING: group 1 file 332 vxn 0 block 0 write I/O failed

Towards these errors i have examined and found that the cause of this issue is that, the same name of database was already created in our storage and creating DB with same name again was triggering error from CELL.

Cause: A code change was done in 12.1.2.1.2  that enforced Global DB_UNIQUE_NAME across all virtual hosts sharing cells.

Workaround:

Edit the cellint.ora on each storage cell to add in _cell_db_unique_name_check=false and then restart all cell services. This can be done rolling one cell at a time.

OR

Use different DB_UNIQUE_NAME to avoid modification on CELL level.

MGMTDB manual creation

GI Management Repository configuration tool

oragrid@tabsmed01:~/scripts$ srvctl status mgmtdb
PRCD-1120 : The resource for database _mgmtdb could not be found.
PRCR-1001 : Resource ora.mgmtdb does not exist
oragrid@tabsmed01:~/scripts$

oragrid@tabsmed01:~/scripts$ ./mdbutil.pl --status
mdbutil.pl version : 1.95
2018-08-13 11:31:51: I Checking CHM status...
2018-08-13 11:31:52: W MGMTLSNR is not configured
2018-08-13 11:31:53: W MGMTDB is not configured on tabsmed01!
2018-08-13 11:31:54: I Cluster Health Monitor (CHM) is configured and running
2018-08-13 11:41:54: E Fail to get CHM Repository Path, exiting...
oragrid@tabsmed01:~/scripts$

oragrid@tabsmed01:~/scripts$ ./mdbutil.pl --addmdb --target=+DATA_DG1
mdbutil.pl version : 1.95
2018-08-13 15:14:27: I Starting To Configure MGMTDB at +DATA_DG1...
2018-08-13 15:14:51: I Container database creation in progress...
2018-08-13 15:21:06: I Plugable database creation in progress...
2018-08-13 15:22:38: I Executing "/tmp/mdbutil.pl --addchm" on tabsmed01 as root to configure CHM.
Password:
2018-08-13 15:23:22: I Executing "/tmp/mdbutil.pl --addchm" on tabsmed02 as root to configure CHM.
Password:
2018-08-13 15:23:28: I MGMTDB & CHM configuration done!
oragrid@tabsmed01:~/scripts$

oragrid@tabsmed01:~/scripts$ ./mdbutil.pl --status
mdbutil.pl version : 1.95
2018-08-14 09:29:58: I Checking CHM status...
2018-08-14 09:29:59: I Listener MGMTLSNR is configured and running on tabsmed01
2018-08-14 09:30:01: I Database MGMTDB is configured and running on tabsmed01
2018-08-14 09:30:01: I Cluster Health Monitor (CHM) is configured and running
--------------------------------------------------------------------------------
CHM Repository Path = +DATA_DG1/_MGMTDB/FDB191CA900D2A2CE04400163E5BEA5F/DATAFILE/sysmgmtdata.264.984064885
MGMTDB space used on DG +DATA_DG1 = 4258 Mb
--------------------------------------------------------------------------------
oragrid@tabsmed01:~/scripts$

Sunday, August 5, 2018

Summary of ASM Disk Group Attributes


ASM Disk group attributes are parameters that are bound to a disk group, these attributes can be set when a disk group is created or altered.

Here is the list of attributes:

ACCESS_CONTROL.ENABLED
ACCESS_CONTROL.UMASK
AU_SIZE
CELL.SMART_SCAN_CAPABLE
CELL.SPARSE_DG
COMPATIBLE.ASM
COMPATIBLE.RDBMS
COMPATIBLE.ADVM
CONTENT.CHECK
CONTENT.TYPE
DISK_REPAIR_TIME
FAILGROUP_REPAIR_TIME
IDP.BOUNDARY and IDP.TYPE
PHYS_META_REPLICATED
SECTOR_SIZE
STORAGE.TYPE
THIN_PROVISIONED

Lets see an example:

oragrid@irafmdr01:~$ asmcmd lsattr -G DATA_USG -l
Name                        Value
access_control.enabled      FALSE
access_control.umask        066
appliance._partnering_type  EXADATA FIXED
appliance.mode              TRUE
au_size                     4194304
cell.smart_scan_capable     TRUE
cell.sparse_dg              allnonsparse
compatible.asm              12.1.0.2.0
compatible.rdbms            11.2.0.4.0
content.check               FALSE
content.type                data
disk_repair_time            3.6h
failgroup_repair_time       24.0h
idp.boundary                auto
idp.type                    dynamic
logical_sector_size         512
phys_meta_replicated        true
sector_size                 512
thin_provisioned            FALSE
oragrid@irafmdr01:~$

If you want to check from SQL then use the below SQL.

SQL> SELECT dg.name as diskgroup, SUBSTR(a.name,1,20) as name,
     SUBSTR(a.value,1,25) AS value FROM V$ASM_DISKGROUP dg, V$ASM_ATTRIBUTE a
     WHERE dg.group_number = a.group_number
     and a.name like '%smart%';  2    3    4

DISKGROUP                      NAME                     VALUE
------------------------------ ------------------------ ------------------------
DATA_DG1                       cell.smart_scan_capable  TRUE
DBFS_DG1                       cell.smart_scan_capable  TRUE
RECO_DG1                       cell.smart_scan_capable  TRUE

Cluster name


Sometime we might need to check our cluster name in our RAC, lets see how to check it.

login to server using grid user and go to $ORA_CRS_HOME/bin or in some servers we might have set ORA_CRS_HOME as ORACLE_HOME where cluster binaries were installed.

Which ever applicable to your environment switch it.

oragrid@vsc02zdbadm020102:cd $ORA_CRS_HOME/bin

Now simply type ./cemutlo and entry to see the available options.

oragrid@vsc02zdbadm020102:/u01/app/12.1.0.2/grid/bin$ ./cemutlo
Usage: ./cemutlo.bin [-n] [-w]
        where:
        -n prints the cluster name
        -w prints the clusterware version in the following format:
                 <major_version>:<minor_version>:<vendor_info>
oragrid@vsc02zdbadm020102:/u01/app/12.1.0.2/grid/bin$

As we need to know only the cluster name use ./cemutlo -n to see what's our cluster name.

oragrid@vsc02zdbadm020102:/u01/app/12.1.0.2/grid/bin$ ./cemutlo -n
tab-clu5
oragrid@vsc02zdbadm020102:/u01/app/12.1.0.2/grid/bin$

Conclusion:  Here is our cluster name "tab-clu5" by default cluster name is "crs".


Thursday, July 19, 2018

Recovery was unable to create the file

Error

WARNING: File being created with same name as in Primary
Existing file may be overwritten
Errors in file /ccbs/appl/oracle/orabase/diag/rdbms/prodtabs/TABS1/trace/TABS1_pr00_4213.trc:
ORA-01119: error in creating database file '+DATA_DG1/tabsdr/u14/prodtabs/tabsxl01_f09.dbf'
ORA-17502: ksfdcre:4 Failed to create file +DATA_DG1/tabsdr/u14/prodtabs/tabsxl01_f09.dbf
ORA-15001: diskgroup "DATA_DG1" does not exist or is not mounted
ORA-15077: could not locate ASM instance serving a required diskgroup
File #308 added to control file as 'UNNAMED00308'.
Originally created as:
'+DATA_DG1/tabsdr/u14/prodtabs/tabsxl01_f09.dbf'
Recovery was unable to create the file as:
'+DATA_DG1/tabsdr/u14/prodtabs/tabsxl01_f09.dbf'
MRP0: Background Media Recovery terminated with error 1274
Errors in file /ccbs/appl/oracle/orabase/diag/rdbms/prodtabs/TABS1/trace/TABS1_pr00_4213.trc:
ORA-01274: cannot add datafile '+DATA_DG1/tabsdr/u14/prodtabs/tabsxl01_f09.dbf' - file could not be created
Tue Jun 12 11:03:40 2018
Managed Standby Recovery not using Real Time Apply
Recovery interrupted!
Recovery stopped due to failure in applying recovery marker (opcode 17.30).

Cause

Our DR was prepared from filesystem to ASM, after switchover standby_file_management was set to 'AUTO' but DB_FILE_NAME_CONVERT wasn't (missed).

So, when we added datafile in new primary database as '+DATA_DG1/tabsdr/u14/prodtabs/tabsxl01_f09.dbf' it tries to create this file on Standby using the same path as of primary database, as this path is not exist it got failed.

Solution

Frist of all there are many ways to fix, what i followed is as below.

1. Stop recovery
recover managed standby database cancel;
2. Shutdown database
3. Update pfile with all subsequent location of datafiles in DB_FILE_NAME_CONVERT and LOG_FILE_NAME_CONVERT
4. Create spfile from pfile
5. Start database in standby mode.
6. Start recovery
Alter database recover managed standby database  using current logfile disconnect;

By the time i checked the system and applied all these changes huge archive gap generated and archive logs were deleted from production server too.

Now i have to sync DR from incremental bacukp from the SCN from which logs were missing.

To avoid this i used another way.

7. Restore archive logs of primary datatabase directly to standby database server.
8. No need to register archive logs with database, database will read from the location where i'm doing restore.



Wednesday, July 11, 2018

OAV-46599: internal error

Error

While deleting target from Audit vault i got an error.




Cause

Java framework was not running.


Solution


Start Java framework and retry delete.


Sunday, July 8, 2018

Changing database name using NID


1. Shutdown your database.
2. Start it in mount stage.
3. Run nid to apply changes.
4. After successful completion start database with resetlogs.

SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount;
ORACLE instance started.

Total System Global Area 3206836224 bytes
Fixed Size                  2257520 bytes
Variable Size            1778388368 bytes
Database Buffers         1409286144 bytes
Redo Buffers               16904192 bytes
Database mounted.
SQL> Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
bash-3.2$
bash-3.2$ nid TARGET=SYS/xxxxxxx DBNAME=UAT

DBNEWID: Release 11.2.0.4.0 - Production on

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

Connected to database PROD (DBID=337679511)

Connected to server version 11.2.0

Control Files in database:
    /DB/app/oracle/oradata/UAT/control01.ctl
    /DB/app/oracle/oradata/UAT/control02.ctl

Changing database ID from 337679511 to 3686432641
Changing database name from PROD to UAT
    Control File /DB/app/oracle/oradata/UAT/control01.ctl - modified
    Control File /DB/app/oracle/oradata/UAT/control02.ctl - modified
    Datafile /DB/app/oracle/oradata/UAT/system.294.87146925 - dbid changed, wrote new name
    Datafile /DB/app/oracle/oradata/UAT/sysaux.267.87146925 - dbid changed, wrote new name
    Datafile /DB/app/oracle/oradata/UAT/undotbs1.270.87146925 - dbid changed, wrote new name
    Datafile /DB/app/oracle/oradata/UAT/users.269.87146925 - dbid changed, wrote new name
    Datafile /DB/app/oracle/oradata/UAT/undotbs2.272.87146940 - dbid changed, wrote new name
    Datafile /DB/app/oracle/oradata/UAT/temp.295.87146934 - dbid changed, wrote new name
    Control File /DB/app/oracle/oradata/UAT/control01.ctl - dbid changed, wrote new name
    Control File /DB/app/oracle/oradata/UAT/control02.ctl - dbid changed, wrote new name
    Instance shut down

Database name changed to UAT.
Modify parameter file and generate a new password file before restarting.
Database ID for database UAT changed to 3686432641.
All previous backups and archived redo logs for this database are unusable.
Database has been shutdown, open database with RESETLOGS option.
Succesfully changed database name and ID.
DBNEWID - Completed succesfully.


Saturday, July 7, 2018

FRM-92095: Oracle JInitiator version too low

Error

FRM-92095: Oracle JInitiator version too low


Casue

The cause is the JRE version is not compatible. Oracle made an internal change in the Java plugin after Java 7 that causes Oracle Forms (Banner) to not recognize that Java is correctly installed.

Solution

Add JAVA_TOOL_OPTIONS in system environment setings.



Wednesday, July 4, 2018

Installing Oracle Forms and Reports 12c on Windows 64 Bit machine


This installation will be done in three phases.

1. Java JDK installation
2. Oracle WebLogic Server (FMW Infrastructure) Installation and
3. Oracle Forms and Reports 12c Installation

Java JDK installation

Download JDK from below location and complete the simple installation to java to your desired location

http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html









Oracle WebLogic Server (FMW Infrastructure) Installation

Download WebLogic Server from the below link and launch installer from java

http://www.oracle.com/technetwork/middleware/weblogic/downloads/wls-main-097127.html









Oracle Forms and Reports 12c Installation

Download software from the link mentioned below and run installer as administrator.

http://www.oracle.com/technetwork/developer-tools/forms/downloads/index.html











This completes your installation but, in 12c you have to run "Repository Configuration Utility (RCU)" and "Create the Forms and Reports Services Domain" manually.


Sunday, July 1, 2018

Could not create the change tracking file

Error

SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-19751: could not create the change tracking file
ORA-19750: change tracking file:
'+DATA_USG/RAREF/CHANGETRACKING/ctf.344.951649823'
ORA-17502: ksfdcre:4 Failed to create file
+DATA_USG/RAREF/CHANGETRACKING/ctf.344.951649823
ORA-15046: ASM file name '+DATA_USG/RAREF/CHANGETRACKING/ctf.344.951649823' is
not in single-file creation form
ORA-17503: ksfdopn:2 Failed to open file
+DATA_USG/RAREF/CHANGETRACKING/ctf.344.951649823

ORA-15012: ASM file '+DATA_USG/RAREF/CHANGETRACKING/ctf.344.951649823' does not exist

Cause

Block change tracking file entry that exists in source controlfile is not found where DB got restored because the directory structure.

Solution

Disable block change tracking and recreate it after opening database.

SQL> alter database disable block change tracking;

Database altered.

SQL> alter database open;

Database altered.

SQL>alter database enable block change tracking using file '+DATA_USG';

Failed to load Media Management Library

Error

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03009: failure of allocate command on c1 channel at 06/26/2018 11:28:08
ORA-19554: error allocating device, device type: SBT_TAPE, device name:
ORA-27211: Failed to load Media Management Library

Additional information: 2

Cause

Link between Oracle database server software and NetBackup API library wasn't found.

$ ls -l $ORACLE_HOME/lib/libobk.so
/u01/app/oradr/product/12.1.0.2/dbhome_1/lib/libobk.so: No such file or directory

Solution

Create soft link between Oracle database server software and NetBackup API library

$ ln -s /usr/openv/netbackup/bin/libobk.so64.1 $ORACLE_HOME/lib/libobk.so

$ ls -l $ORACLE_HOME/lib/libobk.so
lrwxrwxrwx   1 oradr    oinstall      38 Jun 26 11:30 /u01/app/oradr/product/12.1.0.2/dbhome_1/lib/libobk.so -> /usr/openv/netbackup/bin/libobk.so64.1
$

Wednesday, June 27, 2018

libsqlplus.so: cannot open shared object file

Error

libsqlplus.so: cannot open shared object file: No such file or directory

Cause

LD_LIBRARY_PATH is not set.

Solution

set the LD_LIBRARY_PATH environment variable to the folder where the “libsqlplus.so” file resides.

For example, 

export LD_LIBRARY_PATH=/DB/app/oracle/product/1124/dbhome_1/lib/

bash-3.2$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.4.0 Production on 

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

SQL> 

Friday, June 22, 2018

ORA-01000: maximum open cursors

Error

Retrieving Snapshot Target Data (1) - 14:48:59
Error: Snapshot Get Target Data routine failed. ORA-01000: maximum open cursors
exceeded
ORA-06512: at "SYS.DBMS_SYS_SQL", line 909
ORA-06512: at "SYS.DBMS_SQL", line 39
Running: CREATE TABLE snapshot_temp_data_764_1

Cause

Maximum open cursors limit exhausted.

Solution

If the value of the database parameter "open_cursors" is not set sufficiently high, then it causes the "ORA-01000: maximum open cursors exceeded" error.

SQL> alter  system set open_cursors=600 scope=both sid='*';

If you are using SPFILE to set database parameter, you can change this value by doing the following while logged into SQL*Plus as SYSDBA:

SQL> alter system set open_cursors=<new_value> scope=both;

In case you are not using SPFILE and are instead using init<SID>.ora file, you should change the value for open_cursors by adding a line to that file or changing any existing setting to look like:

OR

If open_cursors values is much enough then involve your developer to validate the code and ask them to close the cursor after processing statements which were left not closed.

ORA-00600: internal error code, arguments: [729]

Error

ORA-00600: internal error code, arguments: [729], [408], [space leak], [], [], [], [], [], [], [], [], []
Incident details in: /u01/app/oracle/diag/rdbms/tabsdr/TABS2/incident/incdir_33266/TABS2_ora_5348_i33266.trc

Cause

Memory leak problems generally occur when Oracle is trying to free memory allocated to a process. The memory leak dump is generally discovered during session logoff, when Oracle frees the heaps that are allocated for the user process.

Solution

When a user connects to Oracle, a user process is created and at that time the heap is allocated. Every process will have its own memory heap.

If there are no other errors reported at the same time, this may be a case where the error was a rare occurrence and can be safely ignored. As a rule of thumb, leaks less than 90,000 bytes in size are considered to be of low significance.

In this case the space leak is very very low i.e 408 which can be very safely ignored.

Reference

ORA-00600: Internal Error Code, Arguments: [729], [40], (Doc ID 2102971.1)

Saturday, June 2, 2018

ORA-46268: Conflicting operation on audit table(s)

Error

SQL> BEGIN
  DBMS_AUDIT_MGMT.set_audit_trail_location(
    audit_trail_type           => DBMS_AUDIT_MGMT.AUDIT_TRAIL_AUD_STD,
    audit_trail_location_value => 'TABS_DATA');
END;
/    2    3    4    5    6
BEGIN
*
ERROR at line 1:
ORA-46268: Conflicting operation on audit table(s)
ORA-06512: at "SYS.DBMS_AUDIT_MGMT", line 61
ORA-06512: at "SYS.DBMS_AUDIT_MGMT", line 1530

ORA-06512: at line 2

Cause


Session was interrupted by CTRL+C

Solution

No action required and nothing to worry, allow some time to API completion and retry it.

SQL> BEGIN

  DBMS_AUDIT_MGMT.set_audit_trail_location(
    audit_trail_type           => DBMS_AUDIT_MGMT.AUDIT_TRAIL_AUD_STD,
    audit_trail_location_value => 'TABS_DATA');
END;
/     2    3    4    5    6

PL/SQL procedure successfully completed.

Friday, May 11, 2018

ORA-20000: Unable to gather statistics concurrently: insufficient privileges

Error

exec DBMS_STATS.GATHER_TABLE_STATS('SPARKREF','TASK');

BEGIN DBMS_STATS.GATHER_TABLE_STATS('SPARKREF','TASK'); END;
Error at line 1
ORA-20000: Unable to gather statistics concurrently: insufficient privileges
ORA-06512: at "SYS.DBMS_STATS", line 34757

ORA-06512: at line 1

Cause

"ORA-20000: Unable to gather statistics concurrently, insufficient privileges" indicates that concurrent statistics gather option is enabled but failed due to insufficient privileges.

The User executing the DBMS_STATS.GATHER_TABLE_STATS does not have adequate privileges to perform 'concurrent statistics gathering'.

'concurrent statistics gathering' is new  from Oracle Database 11g Release 2 (11.2.0.2).

Solution

Execute one of the following options and then try again.

1. Grant following privileges to the user to enable them to run gather_stats in concurrent mode

GRANT CREATE JOB, MANAGE SCHEDULER, MANAGE ANY QUEUE to SPARK_REF_ADMIN;

OR

2. Disable the 'concurrent statistics gathering' feature using the following commands.

exec DBMS_STATS.SET_GLOBAL_PREFS(pname=>'CONCURRENT',pvalue=>'FALSE');

Thursday, May 10, 2018

ORA-39126: Worker unexpected fatal error in KUPW$WORKER.STATS_UNLOAD [MARKER]

Error:

Processing object type SCHEMA_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
Processing object type SCHEMA_EXPORT/STATISTICS/MARKER
ORA-39126: Worker unexpected fatal error in KUPW$WORKER.STATS_UNLOAD [MARKER]
MARKER
ORA-01000: maximum open cursors exceeded
ORA-06512: at "SYS.DBMS_STATS_INTERNAL", line 15556
ORA-06512: at "SYS.DBMS_STATS_INTERNAL", line 15568
ORA-02063: preceding 3 lines from PROD2DELTA

ORA-06512: at "SYS.DBMS_SYS_ERROR", line 105
ORA-06512: at "SYS.KUPW$WORKER", line 11265

----- PL/SQL Call Stack -----
  object      line  object
  handle    number  name
0x17ba1deff8     27116  package body SYS.KUPW$WORKER
0x17ba1deff8     11286  package body SYS.KUPW$WORKER
0x17ba1deff8     24429  package body SYS.KUPW$WORKER
0x17ba1deff8     20692  package body SYS.KUPW$WORKER
0x17ba1deff8     10206  package body SYS.KUPW$WORKER
0x17ba1deff8     13381  package body SYS.KUPW$WORKER
0x17ba1deff8      3173  package body SYS.KUPW$WORKER
0x17ba1deff8     12035  package body SYS.KUPW$WORKER
0x17ba1deff8      2081  package body SYS.KUPW$WORKER
0xd897ec40         2  anonymous block

Fixing up the name in the impdp stat table
ORA-39126: Worker unexpected fatal error in KUPW$WORKER.STATS_LOAD [MARKER]
ORA-30926: unable to get a stable set of rows in the source tables

ORA-06512: at "SYS.DBMS_SYS_ERROR", line 95
ORA-06512: at "SYS.KUPW$WORKER", line 11259

----- PL/SQL Call Stack -----
  object      line  object
  handle    number  name
0x17ba1deff8     27116  package body SYS.KUPW$WORKER
0x17ba1deff8     11286  package body SYS.KUPW$WORKER
0x17ba1deff8     24286  package body SYS.KUPW$WORKER
0x17ba1deff8     24415  package body SYS.KUPW$WORKER
0x17ba1deff8     10105  package body SYS.KUPW$WORKER
0x17ba1deff8     13381  package body SYS.KUPW$WORKER
0x17ba1deff8      3173  package body SYS.KUPW$WORKER
0x17ba1deff8     12035  package body SYS.KUPW$WORKER
0x17ba1deff8      2081  package body SYS.KUPW$WORKER
0xd897ec40         2  anonymous block

In STATS_UNLOAD
DBMS_STATS.EXPORT_STATS_FOR_DP
DBMS_STATS.EXPORT_STATS_FOR_DP
In STATS_LOAD with process_order 544
Fixing up the name in the impdp stat table

Job "EXPOPR"."SYS_IMPORT_SCHEMA_02" stopped due to fatal error.

Cause:

The issue is because of stale statistics.

Solution:

To overcome from this use the below workarounds:

1. Gather the statistics for Dictionary and Fixed Objects as follows:

SQL> exec dbms_stats.gather_dictionary_stats;
SQL> exec dbms_stats.lock_table_stats (null,'X$KCCLH');
SQL> exec dbms_stats.gather_fixed_objects_stats;

2. Run a fresh export after gathering stats then, use the new generated dump file to import.

OR

3. Exclude statistics during the import job and gather stats afterwards.

impdp system/password parfile=imp_user.par ...  exclude=statistics

Processing object type SCHEMA_EXPORT/TABLE/INDEX/INDEX
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/REF_CONSTRAINT

Job "EXPOPR"."SYS_IMPORT_SCHEMA_03" completed

Wednesday, May 9, 2018

ORA-20100: Error: FND_FILE failure. Unable to create file

Error:

Oracle error 20100: java.sql.SQLException: ORA-20100: Error: FND_FILE failure. Unable to create file, o0971960.tmp in the directory, /usr/tmp.
You will find more information in the request log.
ORA-06512: at "APPS.FND_FILE", line 417
ORA-06512: at "APPS.FND_FILE", line 526
ORA-06512: at "APPS.FND_CONCURRENT", line 1335
ORA-06512: at line 1
 has been detected in FND_CONCURRENT.SET_INTERIM_STATUS.+---------------------------------------------------------------------------+
Start of log messages from FND_FILE

Cause:

The common root cause of this type of issue is multiple instances targeting the same physical directory that can make it full or .tmp file with same request number might exist.


Solution:

Each environment needs to target a separate utl_file_dir to prevent the recurrence of this issue.

This value can be observed with the following query.

select value from v$parameter where name = 'utl_file_dir';

The issue is resolved by creating some space or changing utl_file_dir to some new location where user has access to read and write.

1. Clear /usr/tmp folder, or the folder that is full

OR

2. Change utl_file_dir and $APPLTMP location to some new location.

3. Check the APPLPTMP variable value is the same as the first directory path defined in UTL_FILE_DIR
e.g. echo $APPLPTMP

2. Retest the issue

Wednesday, April 25, 2018

ORA-38760: This database instance failed to turn on flashback database

Error

Starting recover at 24-APR-18
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=1072 device type=DISK

starting media recovery
media recovery failed
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 04/24/2018 14:54:07
ORA-00283: recovery session canceled due to errors
RMAN-11003: failure during parse/execution of SQL statement: alter database recover if needed
 start until cancel using backup controlfile
ORA-00283: recovery session canceled due to errors
ORA-38760: This database instance failed to turn on flashback database


Cause

Database was in flashback mode.

Solution

trun off flashback mode and rerun recovery.

SQL> alter database flashback off;

Database altered.

SQL>

RMAN> run
{
set until sequence 576;
recover database;
}2> 3> 4> 5>

executing command: SET until clause

Starting recover at 24-APR-18
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=1072 device type=DISK

starting media recovery

channel ORA_DISK_1: starting archived log restore to default destination
channel ORA_DISK_1: restoring archived log
archived log thread=1 sequence=573
channel ORA_DISK_1: restoring archived log
archived log thread=1 sequence=574
channel ORA_DISK_1: restoring archived log
archived log thread=1 sequence=575
channel ORA_DISK_1: reading from backup piece /d02/dbbackup/RMAN_backup1/RMAN_BKPMon_23Apr18/ar_974238549_2165_1
channel ORA_DISK_1: errors found reading piece handle=/d02/dbbackup/RMAN_backup1/RMAN_BKPMon_23Apr18/ar_974238549_2165_1
channel ORA_DISK_1: failover to piece handle=/d01/oracln/backup/RMAN_BKPMon_23Apr18/ar_974238549_2165_1 tag=TAG20180423T211704
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:02:25
archived log file name=/d01/oracln/data/archive1_573_970862557.dbf thread=1 sequence=573
archived log file name=/d01/oracln/data/archive1_574_970862557.dbf thread=1 sequence=574
archived log file name=/d01/oracln/data/archive1_575_970862557.dbf thread=1 sequence=575
media recovery complete, elapsed time: 00:00:27
Finished recover at 24-APR-18

RMAN>

Recovery Manager complete.

Thursday, April 12, 2018

Oracle Database Gateway Installation and configuration to connect SYBASE


Oracle Database Gateway: DB Link between oracle and sybase

Download Oracle Database 12c Database Gateway for Sybase from https://edelivery.oracle.com












 Configuring Oracle Database Gateway for Sybase



Configure Oracle Net for the Gateway.

The Oracle Net Listener listens for incoming requests from the Oracle database. For the Oracle Net Listener to listen for the gateway, information about the gateway must be added to the Oracle Net Listener configuration file.



Start the Oracle Net Listener for the Gateway home




Configure the Oracle Database for Gateway Access

To can access Sybase system, it must have an entry in its tnsnames.ora file to contact the listener we just created/modified, edit tnsnames.ora and add a connect descriptor for the gateway.


To access the Sybase server, you must create a database link. A public database link is the most common of database links.



Query Sybase object




RC-20200: Fatal: Could not find Unzip. At this time only Native UnZip 5.X is supported

Error

Log file located at /u01/oradr/db_1/appsutil/log/TEST_azuredr/ApplyDBTier_03271707.log
  /      0% completed       RC-20200: Fatal: Could not find Unzip. At this time only Native UnZip 5.X is supported.
Please make sure you have UnZip 5.X in your path and try again...

ERROR while running Apply...


ERROR: Failed to execute /u01/oradr/db_1/appsutil/clone/bin/adclone.pl

Solution

1. Check unzip version.
2. If 5.X version not exist then.
3. Take backup of existing unzip mv /usr/bin/unzip /usr/bin/unzip_Orig
4. Bring 5.X version from db home cp /u01/oradr/db_1/bin/unzip /usr/bin/unzip
5. Rerun clone and revert back the  /usr/bin/unzip to original one.

RC-00110: Fatal: Error occurred while relinking of ApplyDBTechStack

Error

/u01/oradr/db_1/appsutil/clone/bin/../jre/bin/java -Xmx600M -DCONTEXT_VALIDATED=true  -Doracle.installer.oui_loc=/u01/oradr/db_1/oui -classpath /u01/oradr/db_1/appsutil/clone/jlib/xmlparserv2.jar:/u01/oradr/db_1/appsutil/clone/jlib/ojdbc5.jar:/u01/oradr/db_1/appsutil/clone/jlib/java:/u01/oradr/db_1/appsutil/clone/jlib/oui/OraInstaller.jar:/u01/oradr/db_1/appsutil/clone/jlib/oui/ewt3.jar:/u01/oradr/db_1/appsutil/clone/jlib/oui/share.jar:/u01/oradr/db_1/appsutil/clone/jlib/oui/srvm.jar:/u01/oradr/db_1/appsutil/clone/jlib/ojmisc.jar   oracle.apps.ad.clone.ApplyDBTier -e /u01/oradr/db_1/appsutil/TEST_azuredr.xml -stage /u01/oradr/db_1/appsutil/clone   -showProgress
APPS Password : Log file located at /u01/oradr/db_1/appsutil/log/TEST_azuredr/ApplyDBTier_03271654.log
  \      0% completed       RC-00110: Fatal: Error occurred while relinking of ApplyDBTechStack

ERROR while running Apply...
Tue Mar 27 16:55:27 2018

 ERROR: Failed to execute /u01/oradr/db_1/appsutil/clone/bin/adclone.pl


Cause

log file reveled the information

"Perl lib version (5.10.1) doesn't match executable version (v5.10.0) at /usr/lib64/perl5/Config.pm line 50.
Compilation failed in require at /u01/oradr/db_1/appsutil/clone/ouicli.pl line 35.
BEGIN failed--compilation aborted at /u01/oradr/db_1/appsutil/clone/ouicli.pl line 35."

Solution

set perl to verion 5.10.0 as below and rerun the clone

export PERL5LIB=/u01/oradr/db_1/perl/lib/5.10.0:/u01/oradr/db_1/perl/lib/site_perl/5.10.0:/u01/oradr/db_1/appsutil/perl

export PATH=/u01/oradr/db_1/perl/bin:$PATH

ORA-39203: Partition selection is not supported over a network link.

Error

impdp xxxx/xxxxx directory=DBPUMP network_link=ARCH2CALLS tables=INCALLS:NOV201601 logfile=incalls_imp.log EXCLUDE=INDEX VERSION=11

Import: Release 11.2.0.4.0 - Production on Tue Apr 10 12:58:39 2018

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
ORA-39001: invalid argument value

ORA-39203: Partition selection is not supported over a network link.

Cause

Although i'm in 11.2.X parameter VERSION=11 referred as 11.1.X and as of limitation on 11.1.X only whole tables can be exported over NETWORK_LINK parameter not partitions of tables.

Solution

The enhancement request has been implemented in the 11.2 release rerun impdp by removing VERSION parameter.

Thursday, March 15, 2018

Heartbeat failed to connect to standby

Error on shipping log to standby


Error 12504 received logging on to the standby
PING[ARC2]: Heartbeat failed to connect to standby '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=uatdb01)(PORT=1529))(CONNECT_DATA=(SERVER=DEDICATED)(SID_NAME=TABS2)))'. Error is 12504.
Error 1033 received logging on to the standby

Solution


There are many reasons but, mainly check DG_CONFIG, LOG_ARCHIVE_DEST_2 and TNS entries, if all okey then check password file, if possible recreate password file on primary and copy it to standby.

RMAN-04006: error from auxiliary database: ORA-12514

Error:

Got error while creating DUPLICATE TARGET DATABASE from auxiliary after create spfile from memory

sql statement: create spfile from memory

Oracle instance shut down

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of Duplicate Db command at 03/13/2018 13:08:27
RMAN-05501: aborting duplication of target database
RMAN-03015: error occurred in stored script Memory Script
RMAN-04006: error from auxiliary database: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor.

Solution:

Create separate listener for RMAN duplication in Target,Update the Tnsnames.ora and try.

Create a static entry in listener configuration for auxiliary database.

RMAN-04006 And ORA-12514 During RMAN Duplicate [ID 883490.1]
Connection to Auxilary using connect string failed with ORA-12528 [ID 419440.1]
How to resolve ORA-16792 [ID 966472.1]

RMAN-04006 from auxiliary database

Error:

Getting below error while "DUPLICATE TARGET DATABASE FOR STANDBY FROM ACTIVE DATABASE"

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00554: initialization of internal recovery manager package failed
RMAN-04006: error from auxiliary database: ORA-12528: TNS:listener: all appropriate instances are blocking new connections

Cause:

Service handler is blocking connections.

Solution:

Append (UR=A) clause in "CONNECT_DATA=" section of TNS to allow a privileged or administrative user to connect via listener

Example:

UAT =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = uatdb01)(PORT = 1529))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = UAT)
  (UR = A)
    )