Search This Blog

Monday, July 2, 2012

ORACLE.EXE Virtual Memory Keeps Increasing on x64 Windows

Applies to:

Oracle Server - Enterprise Edition - Version: 10.2.0.1 to 10.2.0.5.0   [Release: 10.2 to 10.2]
Microsoft Windows x64 (64-bit)
NOTICE that this is a PLATFORM SPECIFIC problem for 10gR2 on x64 Windows systems

Symptoms

ORACLE.EXE continuous increases the amount of virtual memory used, and you see zombie thread accumulation on 64-bit MS Windows environment.

No ORA-4030 seen, but instance needs be restarted frequently to bring down the amount of virtual memory consumed by the oracle.exe process. Eventually, if all virtual memory has been consumed, ORA-4030 will occur.

Using Perfmon or TaskManager you see that the virtual size of oracle.exe is constantly growing (up to several 100's MB per day).

Using the VMMap tool to analyze the oracle.exe process, you see that the process stack accumulates zombie threads that holds around 3072 KB per zombie thread, accounting for the excess virtual memory consumption.

VMMap is a process virtual and physical memory analysis utility (available for free) (technet.microsoft.com/sysinternals).

Cause

10.2 was the first release on x64 Windows and it shipped with the 1.5 JDK / 1.4 in the database. There are some memory management issues with this release which are only fixed in 11.1+, so customers should use the workaround or upgrade to 11.1+.

The problem can occur when running JVM related applications.

When a session ends, the thread is not cleaned up at OS level, but remains as a zombie thread, still occupying 3072 KB of thread stack memory.

Solution

Workaround the problem by setting the following parameter, and restart the instance :

  _kill_java_threads_on_eoc=TRUE

OR

Migrate to 11gR1 or 11gR2, where this problem does not occur.

No comments: