How to troubleshoot ORA-00845 errors when the database is started
Problem description: A node database is down during inspection. When using sqlplus for the system, an empty instance is connected. An error is reported when the database is restarted through startup, prompting MEMORY_TARGETnot supported on this system, the error message "MEMORY_TARGET" is reported when you view the alarm log. You must increase the/dev/shm size to solve the problem.
The following error message is returned when you log on to the database:
[Oracle @ db01 ~] $ Sqlplus/as sysdba
SQL * Plus: Release 11.2.0.4.0 Productionon Mon Oct 30 09:26:35 2017
Copyright (c) 1982,201 3, Oracle. All rights reserved.
Connected to an idle instance.
SQL> startup
ORA-00845: MEMORY_TARGET not supported on this system
The background log reports the following information:
Starting ORACLE instance (normal)
WARNING: You are trying to use theMEMORY_TARGET feature. this feature requires the/dev/shm file system to bemounted for at least 13522436096 bytes. /dev/shm is either not mounted or ismounted with available space less than this size. please fix this so that MEMORY_TARGETcan work as expected. current available is 12203786240 and used is 454021120bytes. ensure that the mount point is/dev/shm for this directory.
Memory_target needs larger/dev/shm
Problem Analysis:
Because AMM is used in Oracle11g, when MEMORY_TARGET is greater than/dev/shm, the system is prompted not to support this system, and thus the database cannot be started due to an error, because/dev/shm uses the tmpfs size, you can modify the size in Linux to solve the problem.
Solution:
1. view the current tmpfs size information
[Oracle @ i60001 ~] $ Df-h
Filesystem Size Used Avail Use % Mounted on
/Dev/mapper/vg_db01-LogVol02 229G 65G 153G 30%/
Tmpfs 12G 434 M 12G 4%/dev/shm -- modify here
/Dev/sde1 485 M 40 M 420 M 9%/boot
/Dev/mapper/vg_db01-LogVol00 30G 5.0G 24G 18%/usr
[Oracle @ i60001 ~] $ Mount-o size = 20G-onr_inodes = 1000000-o noatime, nodiratime-o remount/dev/shm
Mount: onlyroot can do that
To modify the tmpfs size, perform the following operations under the root user to switch to the root user.
[Oracle @ i60001 ~] $ Su root
Password:
2. Modify the tmpfs size
[Root @ db01oracle] # mount-o size = 20G-o nr_inodes = 1000000-o noatime, nodiratime-o remount/dev/shm
[Root @ db01oracle] # df-h
Filesystem Size Used Avail Use % Mounted on
/Dev/mapper/vg_db01-LogVol02 229G 65G 153G 30%/
Tmpfs 20G 434 M 20G 3%/dev/shm -- Modified size
/Dev/sde1 485 M 40 M 420 M 9%/boot
/Dev/mapper/vg_db01-LogVol00 30G 5.0G 24G 18%/usr
3. After modifying the tmpfs size, log on to the database and restart the instance.
[Oracle @ db01 ~] $ Sqlplus/as sysdba
SQL * Plus: Release 11.2.0.4.0 Production on Mon Oct 30 09:42:02 2017
Copyright (c) 1982,201 3, Oracle. All rights reserved.
Connected toan idle instance.
SQL> startup;
ORACLEinstance started.
Total SystemGlobal Area 1.3462E + 10 bytes
Fixed Size 2265984 bytes
Variable Size 7381978240 bytes
DatabaseBuffers 6039797760 bytes
Redo Buffers 38014976 bytes
Databasemounted.
Database opened.-The startup is successful.
-- Query whether the current database instance is normal
SQL> select open_mode from v $ database;
OPEN_MODE
--------------------
READ WRITE