ORA-01157 When Standby Database Open Read Only

The following errors occur when trying to open a standby database read only:

SQL> alter database open read only;
alter database open read only
*
ERROR at line 1:
ORA-10458: standby database requires recovery
ORA-01157: cannot identify/lock data file 1 - see DBWR trace file
ORA-01110: data file 1: '+DATA2/TESTDB/DATAFILE/system.3203.1186181325'

When checking ASM file for SYSTEM tablespace, the file exists but with different name:

ASMCMD> ls -lt +DATA2/TESTDB/DATAFILE/system*
Type Redund Striped Time Sys Name
DATAFILE UNPROT COARSE NOV 30 10:00:00 Y SYSTEM.577.1186394617

It seems incantation issue from database control file.

SOLUTION

List incarnation:

RMAN> list incarnation;

using target database control file instead of recovery catalog

List of Database Incarnations
DB Key Inc Key DB Name DB ID STATUS Reset SCN Reset Time
------- ------- -------- ---------------- --- ---------- ----------
1 1 TESTDB 2969509608 PARENT 1 17-APR-19
2 2 TESTDB 2969509608 PARENT 1920977 27-NOV-24
3 3 TESTDB 2969509608 CURRENT 2848922 29-NOV-24

Rest incarnation:

RMAN> RESET DATABASE TO INCARNATION 2;

database reset to incarnation 2

RMAN> list incarnation;

using target database control file instead of recovery catalog

List of Database Incarnations
DB Key Inc Key DB Name DB ID STATUS Reset SCN Reset Time
------- ------- -------- ---------------- --- ---------- ----------
1 1 TESTDB 2969509608 PARENT 1 17-APR-19
2 2 TESTDB 2969509608 CURRENT 1920977 27-NOV-24
3 3 TESTDB 2969509608 ORPHAN 2848922 29-NOV-24

Then standby database open read only successfully.

SQL>  alter database open read only;

Database altered.

‘Cannot allocate memory’, PRCR-1172 : Failed to execute “srvmhelper” for -getTargetHubSize

When install or check 13.5 OEM agent on Linux 8, the following errors occur:

$ emctl status agent
Java HotSpot(TM) 64-Bit Server VM warning: INFO: os::commit_memory(0x00006f2078020000, 2798568, 0) failed; error='Cannot allocate memory' (errno=12).
$ cat /tmp/ hs_err_pid12345.log
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (mmap) failed to map 1400832 bytes for committing reserved memory.
# Possible reasons:
# The system is out of physical RAM or swap space
# The process is running with CompressedOops enabled, and the Java Heap may be blocking the growth of the native heap
# Possible solutions:
# Reduce memory load on the system
# Increase physical memory or swap space
# Check if swap backing store is full
# Decrease Java heap size (-Xmx/-Xms)
# Decrease number of Java threads
# Decrease Java thread stack sizes (-Xss)
# Set larger code cache with -XX:ReservedCodeCacheSize=
# This output file may be truncated or incomplete.
#
# Set larger code cache with -XX:ReservedCodeCacheSize=, tid=0x00007fd043ec1700
#
# JRE version: (8.0_261-b12) (build )
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.261-b12 mixed mode linux-amd64 compressed oops)
# Core dump written. Default location: /u01/app/oracle/product/13.5.0/agent/agent_inst/sysman/emd/core or core.12345

Also when installing Oracle 12.2 on Linux 8, the following errors occur:

ID: oracle.install.commons.util.exception.AbstractErrorAdvisor:849
oracle.cluster.verification.VerificationException: An internal error occurred within cluster verification framework
PRCR-1172 : Failed to execute "srvmhelper" for -getTargetHubSize
PRCR-1172 : Failed to execute "srvmhelper" for -getTargetHubSize
PRCR-1172 : Failed to execute "srvmhelper" for -getTargetHubSize
PRCR-1172 : Failed to execute "srvmhelper" for -getTargetHubSize
$ cluvfy stage -pre dbinst -allnodes -r 12.2 -d /u01/app/oracle/product/12.2.0/dbhome_1
Java HotSpot(TM) 64-Bit Server VM warning: INFO: os::commit_memory(0x00007f7aa945a000, 2793472, 0) failed; error='Cannot allocate memory' (errno=12)
#
# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (mmap) failed to map 2793472 bytes for committing reserved memory.
# An error report file with more information is saved as:
# /home/oracle/hs_err_pid79287.log

SOLUTION

Subscribe to get access

Read more of this content when you subscribe today.

OPatch Error: This Java instance does not support a 64-bit JVM.opatch

When trying to run opatch, the following error occurs:

$ opatch

Error: This Java instance does not support a 64-bit JVM.
Please install the desired version.

OPatch failed with error code 1

SOLUTION

Download the right opatch.

For 19c opatch on Linux x86-64 download “p6880880_190000_Linux-x86-64.zip” instead of “p6880880_190000_Linux.zip”.