My Oracle Support Banner

ORDS Failing with Message "There is insufficient memory for the Java Runtime Environment to continue." (Doc ID 2575918.1)

Last updated on OCTOBER 17, 2023

Applies to:

Oracle REST Data Services - Version 17.4.1 and later
Oracle Cloud Infrastructure - Database Service - Version N/A and later
Information in this document applies to any platform.

Symptoms

 1. ORDS is failing with the following errors:

There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (mmap) failed to map 65536 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=
# JVM is running with Zero Based Compressed Oops mode in which the Java heap is
# placed in the first 32GB address space. The Java Heap base address is the
# maximum limit for the native heap growth. Please use -XX:HeapBaseMinAddress
# to set the Java Heap base and to place the Java Heap above 32GB virtual address.
# This output file may be truncated or incomplete.

2. DB alert.log shows the following:

=============================================================================================
[Date Time Stamp]
WARNING: Heavy swapping observed on system in last 5 mins.
Heavy swapping can lead to timeouts, poor performance, and instance eviction.

See Note 411.1 at My Oracle Support for error and packaging details.
[Date Time Stamp]

:*****************************************************************
):An internal routine has requested a dump of selected redo.
:This usually happens following a specific internal error, when
:analysis of the redo logs will help Oracle Support with the
:diagnosis.
:It is recommended that you retain all the redo logs generated (by
:all the instances) during the past 12 hours, in case additional
:redo dumps are required to help with the diagnosis.
:*****************************************************************

3. ORDS 18.2 is running as a standalone
4. This is a Linux server with only 16GB of memory

top - 22:34:16 up 6:13, 1 user, load average: 7.93, 44.22, 30.01
Tasks: 477 total, 1 running, 476 sleeping, 0 stopped, 0 zombie
Cpu(s): 3.1%us, 2.6%sy, 0.0%ni, 94.0%id, 0.3%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 15133948k total, 13737144k used, 1396804k free, 16624k buffers
Swap: 2097148k total, 2095680k used, 1468k free, 947184k cached

 PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
8801 root RT 0 1172m 163m 101m S 1.7 1.1 6:02.04 osysmond.bin
10657 grid -2 0 1790m 6920 6464 S 1.0 0.0 4:36.71 asm_vktm_+asm1
13000 grid -2 0 718m 5732 5296 S 1.0 0.0 4:36.99 apx_vktm_+apx1
15715 oracle -2 0 8400m 1200 736 S 1.0 0.0 4:36.40 ora_vktm_ocupad
26491 grid 20 0 1347m 87m 41m S 1.0 0.6 0:02.42 oraagent.bin
8833 root 0 -20 1089m 22m 19m S 0.7 0.2 0:32.43 cssdagent
9809 root RT -5 958m 234m 101m S 0.7 1.6 1:55.03 ologgerd
11988 root 20 0 1254m 63m 30m S 0.7 0.4 1:54.87 orarootagent.bi
14260 oracle 20 0 1329m 37m 30m S 0.7 0.3 0:35.22 oraagent.bin
27181 root 20 0 2637m 170m 21m S 0.7 1.2 0:23.78 java
28969 oracle 20 0 15348 2464 1812 R 0.7 0.0 0:00.07 top
86248 oracle 20 0 6228m 1.6g 0 S 0.7 11.1 2:12.68 java - (This is the ORDS Process)

 Summary According to top:

Memory available: 15.134 GB
memory used : 13.737 GB
Free : 1.4 GB

Changes

 None.

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Changes
Cause
Solution


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.