签到成功

知道了

CNDBA社区CNDBA社区

关于Oracle ASM的自动内存管理的介绍说明

2018-01-29 10:57 3142 0 原创 Oracle 12C
作者: Expect-乐

1.说明

utomatic memory management automatically manages the memory-related parameters for both Oracle ASM and database instances with the MEMORY_TARGET parameter. Automatic memory management is enabled by default on an Oracle ASM instance, even when the MEMORY_TARGET parameter is not explicitly set. The default value used for MEMORY_TARGET is acceptable for most environments. This is the only parameter that you must set for complete Oracle ASM memory management. Oracle strongly recommends that you use automatic memory management for Oracle ASM.

默认情况下,Oracle ASM实例是启用自动内存管理的,并且Oracle强烈建议为ASM使用自动内存管理。

n Oracle ASM instance can automatically increase the values set for MEMORY_TARGET and MEMORY_MAX_TARGET if an ORA-04031 error is raised and automatic memory management is enabled. If MEMORY_MAX_TARGET has been explicitly set to a value, then every time ORA-04031 is raised, the MEMORY_TARGET value is increased by 10% of the existing MEMORY_TARGET value or 128 MB, whichever is greater, but not greater than the customer specified MEMORY_MAX_TARGET value. If MEMORY_MAX_TARGET is not explicitly set, then both MEMORY_TARGET and MEMORY_MAX_TARGET are increased by 10% of the existing MEMORY_TARGET value or 128 MB, whichever is greater, for a maximum of five increases. The Oracle ASM instance must be rebooted to use the new MEMORY_TARGET and MEMORY_MAX_TARGET settings.http://www.cndba.cn/Expect-le/article/2593http://www.cndba.cn/Expect-le/article/2593

如果启用了ORA-04031错误并启用了自动内存管理,Oracle ASM实例可以自动增加MEMORY_TARGET和MEMORY_MAX_TARGET的值。如果MEMORY_MAX_TARGET被显式地设置为一个值,那么每次出现ORA-04031错误时,MEMORY_TARGET值都会增加现有MEMORY_TARGET值的10%或128 MB,无论哪个更大,但不能超过用户指定的MEMORY_MAX_TARGET的大小。如果没有显式地设置MEMORY_MAX_TARGET,那么MEMORY_TARGET和MEMORY_MAX_TARGET都增加了现有MEMORY_TARGET值的10%或128 MB,无论哪个更大,增加大小次数最大值为5次。必须重新启动Oracle ASM实例才能使MEMORY_TARGET和MEMORY_MAX_TARGET生效。http://www.cndba.cn/Expect-le/article/2593

f you do not set a value for MEMORY_TARGET, but you do set values for other memory related parameters, Oracle internally calculates the optimum value for MEMORY_TARGET based on those memory parameter values. You can also increase MEMORY_TARGET dynamically, up to the value of the MEMORY_MAX_TARGET parameter, just as you can do for the database instance.

如果你没有为MEMORY_TARGET设置一个值,但是你设置了其他内存相关参数的值,那么Oracle内部会根据这些内存参数值计算MEMORY_TARGET的最优值。你还可以动态地增加MEMORY_TARGET大小,达到MEMORY_MAX_TARGET一样大小。

lthough it is not recommended, you can disable automatic memory management by either setting the value for MEMORY_TARGET to 0 in the Oracle ASM parameter file or by running an ALTER SYSTEM SET MEMORY_TARGET=0 statement. When you disable automatic memory management, Oracle reverts to automatic shared memory management and automatic PGA memory management. To revert to Oracle Database 10g Release 2 (10.2) functionality to manually manage Oracle ASM SGA memory, also run the ALTER SYSTEM SET SGA_TARGET=0 statement. Unless specified, the behaviors of the automatic memory management parameters in Oracle ASM instances behave the same as in Oracle Database instances.

虽然不推荐使用,但是可以通过在Oracle ASM参数文件中将MEMORY_TARGET的值设置为0,或者通过执行ALTER SYSTEM SET MEMORY_TARGET=0语句来禁用自动内存管理。当禁用自动内存管理时,Oracle将恢复到自动共享内存管理和自动PGA内存管理。要恢复Oracle Database 10g R2(10.2)的手动管理Oracle ASM SGA内存,也运行ALTER SYSTEM SET SGA_TARGET=0语句。除非指定,Oracle ASM实例中的自动内存管理参数的行为与Oracle数据库实例中的行为相同。

注意:
对于linux环境,如果/dev/shm不可用,那么自动内存管理讲无法工作。
Oracle ASM的MEMORY_TARGET的最小值为1G,如果设置小于1G,Oracle也会自动增加到1G。http://www.cndba.cn/Expect-le/article/2593

更多内容,请查看官方文档:
https://docs.oracle.com/en/database/oracle/oracle-database/12.2/ostmg/init-params-asm-instance.html#GUID-6FA72F9A-CD1C-459F-B8A0-2754A11E76D0

http://www.cndba.cn/Expect-le/article/2593
http://www.cndba.cn/Expect-le/article/2593http://www.cndba.cn/Expect-le/article/2593
http://www.cndba.cn/Expect-le/article/2593

2.查看MEMORY_TARGET和memory_max_target

SQL> show parameter memory

NAME                     TYPE     VALUE
------------------------------------ ----------- ------------------------------
memory_max_target             big integer 1076M
memory_target                 big integer 1076M

3禁用自动内存管理
虽然不推荐使用,但是可以通过在Oracle ASM参数文件中将MEMORY_TARGET的值设置为0,或者通过执行ALTER SYSTEM SET MEMORY_TARGET=0语句来禁用自动内存管理。http://www.cndba.cn/Expect-le/article/2593

http://www.cndba.cn/Expect-le/article/2593

版权声明:本文为博主原创文章,未经博主允许不得转载。

AMM

用户评论
* 以下用户言论只代表其个人观点,不代表CNDBA社区的观点或立场
Expect-乐

Expect-乐

关注

Without the continuous bitter cold, there can be no fragrant plum blossom

  • 336
    原创
  • 6
    翻译
  • 100
    转载
  • 41
    评论
  • 访问:1547148次
  • 积分:1957
  • 等级:核心会员
  • 排名:第4名
精华文章
    最新问题
    查看更多+
    热门文章
      热门用户
      推荐用户
        Copyright © 2016 All Rights Reserved. Powered by CNDBA · 皖ICP备2022006297号-1·

        QQ交流群

        注册联系QQ