3 Replies Latest reply on Aug 29, 2013 9:12 PM by user10437903

    Understanding kernel hugepages and Oracle 11g AMM incompatibility


      Metalink Note 749851.1 and http://docs.oracle.com/cd/E11882_01/server.112/e10839/appi_vlm.htm outlines that when Oracle SGA uses AMM, which uses /dev/shm, kernel hugepages are not used. The use of AMM is absolutely incompatible with hugepages.

      Well, I guess it's clear that a database using AMM will allocate /dev/shm and not use kernel hugepages.

      However, apparently according to my test below, it does not mean two DB instances, one using /dev/shm (AMM), and another one using kernel hugepages (ASMM), cannot coexist on the same server.

      I have installed a VirtualBox test installation using OL 5.7 x86_64 with UEK kernel and configured the system with kernel hugepages.

      $ grep Huge /proc/meminfo
      HugePages_Total: 1029
      HugePages_Free: 826
      HugePages_Rsvd: 60
      HugePages_Surp: 0
      Hugepagesize: 2048 kB

      $ df -h | grep shm
      tmpfs 2.0G 176M 1.8G 9% /dev/shm

      The server uses the following ASM instance:

      memory_max_target          big integer 272M
      memory_target               big integer 272M

      $ ls /dev/shm
      ora_ASM_2457605_0   ora_ASM_2457605_2 ora_+ASM_2457605_30  etc…

      And it happily runs the a test instance, using ASM and the following parameters:


      $ ipcs -m

      - Shared Memory Segments -
      key shmid owner perms bytes nattch status
      0x00000000 2097153 root 644 80 2
      0x00000000 2129922 root 644 16384 2
      0x00000000 2162691 root 644 280 2
      0x350d8a94 2457605 oracle 660 4096 0
      0x679f2fb0 2654214 oracle 660 551550976 28

      It seems I have been misinterpreting the information of AMM being incompatible with kernel hugepages. I was under the false impression that using /dev/shm or kernel hugepages was mutually exclusive, applying to the server, but it only applies to the DB instance. Can someone confirm this?