ORA-27102: out of memory

一、问题描述

数据库启动时报错,如下:

[[email protected] ~]$ sqlplus  / as sysdba

SQL*Plus: Release 11.2.0.4.0 Production on Tue Jul 31 22:52:00 2018

Copyright (c) 1982, 2013, Oracle.  All rights reserved.

Connected to an idle instance.

SQL> startup;

ORA-27102: out of memory

Linux-x86_64 Error: 28: No space left on device

Additional information: -150994944

Additional information: 1

二、问题解决思路

参考文档:

Upon startup of Linux database get ORA-27102: out of memory Linux-X86_64 Error: 28: No space left on device (Doc ID 301830.1)

ORA-27102: out of memory

经分析,该数据库kernel.shmall设置值为 2097152,设置值较小。需按照support文档参考值进行调整。

三、问题解决办法

  [[email protected] oradb]# echo "4194304" > /proc/sys/kernel/shmall

  [[email protected] oradb]# vi /etc/sysctl.conf

  设置:kernel.shmall = 4194304

   

 启动数据库:

 SQL> startup;

ORACLE instance started.

Total System Global Area 8451362816 bytes

Fixed Size                  2270112 bytes

Variable Size            1509952608 bytes

Database Buffers         6928990208 bytes

Redo Buffers               10149888 bytes

Database mounted.

Database opened.

 

四、问题深入学习分析

Kernel.shmall:共享内存总量,以页为单位。Linux 共享内存页大小为4KB, 共享内 

存段的大小都是共享内存页大小的整数倍。 一个共享内存段的最大大小是16G,那么需 

要共享内存页数是 16GB/4KB=16777216KB/4KB=4194304 (页)。8G的共享内存需要的内存页数是 2097152 。

Kernel.SHMMAX:单个共享内存段最大字节数 ,要求设置一般比SGA略大