Oracle: ORA-00845: MEMORY_TARGETnotsupportedonthissyst

Source: Internet
Author: User
Oracle common error: ORA-00845: MEMORY_TARGETnotsupportedonthissystem

Oracle common error: ORA-00845: MEMORY_TARGET not supported on this system

Oracle common error: ORA-00845: MEMORY_TARGET not supported on this system

1. Question proposal

The following error is reported:
[Oracle @ night ~] $ Sqlplus/nolog
SQL * Plus: Release 11.2.0.1.0 Production on Thu Jul 25 15:39:40 2013
Copyright (c) 1982,200 9, Oracle. All rights reserved.
SQL> conn sys/as sysdba
Enter password:
Connected to an idle instance.
SQL> startup
ORA-00845: MEMORY_TARGET not supported on this system
SQL>

2. Explanation of the problem

This error has been mentioned in many official documents. You can use this document to learn more about the explanation of this error, so that you can solve the problem faster, more accurately, and more thoroughly.

Open the error messages tag in the official document and you can see the explanation of the error code.

ORA-00845: MEMORY_TARGET not supported on this system
Cause: The MEMORY_TARGET parameter was not supported on this operating system or/dev/shm was not sized correctly on Linux.
Action: Refer to documentation for a list of supported operating systems. Or, size/dev/shm to be at least the SGA_MAX_SIZE on each Oracle instance running on the system.

You can also use the search function of the official document to search for error codes and find corresponding explanations and solutions.

Setting Memory Target at Instance Startup on Linux
Starting with Oracle Database 11g Release 1 (11.1), Oracle provides the option of automatically managing SGA and PGA with a combined MEMORY_TARGETparameter without having to set SGA_TARGET and PGA_AGGREGATE_TARGET explicitly. this is supported on Linux, Windows, Solaris, HPUX, and AIX (reference Bug 7258378 ).
If you see the ORA-00845 error reported on Linux machines at Oracle instance startup when using the MEMORY_TARGET parameter, then check the size of/dev/shm. if/dev/shm is not configured, then mount it sized to be at least the value of MEMORY_TARGET. if/dev/shm is configured but the amount of available space reported (through df-k/dev/shm) is less than MEMORY_TARGET, then free the space or mount a larger/dev/shm to satisfy the MEMORY_TARGET size. note that if you set theMEMORY_MAX_TARGET parameter greater than MEMORY_TARGET, then ensure that/dev/shm is sized to be at least the value of MEMORY_MAX_TARGET.
Memory Target for Oracle Database InstancesRunning Database Configuration Assistant (DBCA) ults to this Automatic Memory Management option. In the case of upgrade or manual database creation, MEMORY_TARGET can be specified in the initialization parameter file.

The error is explained in detail in the above content because/dev/shm is smaller than the MEMORY_TARGET size, or/dev/shm is not mounted at all. If both MEMORY_TARGET and MENORY_MAX_TARGET are set, then/dev/shm must be at least the same size as MEMORY_MAX_TARGET.

Insufficient Memory Target Errors
On Linux systems, if the operating system/dev/shm mount size is too small for the Oracle system global area (SGA) and program global area (PGA ), then you encounter the following error:
ORA-00845: MEMORY_TARGET not supported on this system.
The cause of this error is an insufficient/dev/shm allocation. the total memory size of the SGA and PGA, which sets the initialization parameter MEMORY_TARGETor MEMORY_MAX_TARGET, cannot be greater than the shared memory file system (/dev/shm) on your operating system.
Background
Automatic Memory Management (AMM) has been updated in Oracle ASM 11g Release 2. it manages both the SGA and PGA together. it is managed by the Memory Manager Process (MMAN ). in this release, note the following changes to AMM:
It uses MEMORY_TARGET instead of SGA_TARGET
It uses MEMORY_MAX_TARGET instead of SGA_MAX_SIZE (defaults to MEMORY_TARGET)
It uses memory allocated by/dev/shm
If the value of max_target is set to a value greater than the allocation for the/dev/shm size, then you may encounter the error ORA-00845: MEMORY_TARGET not supported on this system.
Note:
An ORA-00845 error can also occur if/dev/shm is not properly mounted. to rule out this possibility, run the command df-k to ensure that/dev/shm is mounted. for example: $ df-k

Filesystem 1K-blocks Used Available Use % Mounted on
Shmfs 6291456 832356 5459100 14%/dev/shm
Solution
Increase the/dev/shm mountpoint size.
For example:
# Mount-t tmpfs shmfs-o size = 7g/dev/shm
To make this change persistent internal SS system restarts, add an entry in/etc/fstab similar to the following:
Shmfs/dev/shm tmpfs size = 7g 0

The above content not only tells the cause of the error, but also roughly describes the automatic memory management in oracle 11g, and provides the command to solve the error.

3. What is/dev/shm?
First, let's take a look at the mounted file system in linux.
[Oracle @ night ~] $ Df-Th
File System Type capacity available in use % mount point
/Dev/sda2 ext3 16G 11g 3.9G 74%/
/Dev/sda3 ext3 1.6G 37 M 1.4G 3%/tmp
/Dev/sda1 ext3 99 M 12 M 83 M 13%/boot
Tmpfs 252 M 0 252 M 0%/dev/shm

It can be seen that I have mounted/dev/shm, but the file system of this partition is not a common file system type, but a tmpfs file system type, so what is the file system type in tmpfs format?
Tmpfs is a temporary file system in linux. Its size is not fixed. The default size is half of the actual memory.
[Root @ night ~] # Free-m
Total used free shared buffers cached
Mem: 503 368 134 0 26 283
-/+ Buffers/cache: 58 444
Swap: 2525 0 2525
[Root @ night ~] # Df-Th/dev/shm/
File System Type capacity available in use % mount point
Tmpfs 252 M 0 252 M 0%/dev/shm
[Root @ night ~] #

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.