Orcle 12c new features --- full library cache

1 Description

As the name suggests, the whole library cache, is to put the entire database into memory, really exciting. Of course, that memory size larger than the entire database, but also to estimate the amount of data growth. This way, the performance certainly brings enormous, especially for I / O response time and very obvious. This feature will be forced to cache all tables.

1.1 default database caching mechanism

  • Smaller tables are loaded into memory only when the table size is less than 2 percent of the buffer cache size.

Small table, two percent less than the size of the buffer cache, it will be loaded into the cache.

  • For medium tables, Oracle Database analyzes the interval between the last table scan and the aging timestamp of the buffer cache. If the size of the table reused in the last table scan is greater than the remaining buffer cache size, then the table is cached.
    for the table, Oracle database analyzes the gap between the aging timestamp of the last scan and a table of buffer cache. If the size of the last scan table with the table again larger than the remaining size of the buffer cache, then the cache table.

  • Large tables are typically not loaded into memory, unless if you explicitly declare the table for the KEEP buffer pool.

For large tables, default is not cached in the cache. Unless you KEEP display.

Note: In this case, Oracle is not cached NOCACHE the LOB object.

1.2 forcibly whole library cache

In forced full database cache mode, when the size of the database is smaller than the size of the buffer cache database, Oracle database cache the entire database.

All data is accessed files (including the use of SecureFiles NOCACHE lob and lob) are loaded into the buffer cache.

1.2.1 When to use a full library cache

Oracle recommends that:

  • The logical database size (or actual used space) is smaller than the individual buffer cache of each database instance in an Oracle RAC environment. This is applicable for non-Oracle RAC database as well.

  • The logical database size is smaller than 80% of the combined buffer cache sizes of all the database instances for well-partitioned workloads (by instance access) in an Oracle RAC environment.

  • The database uses SGA_TARGET or MEMORY_TARGET.

  • The NOCACHE LOBs need to be cached. The NOCACHE LOBs are never cached unless force full database caching is used.

note:

  1. For RAC ease, if one node is forcibly whole library cache, then all the other nodes will be full library cache.
  2. For CDB environment, cache full library, including all PDB on the CDB.

2 specific operation

Since the environment can not perform such an operation, for example where only the sub.

2.1 to see if the current database is to force a full library cache

SQL> SELECT FORCE_FULL_DB_CACHING FROM V$DATABASE;

FORCE_
------
NO

2.2 Enabling full library cache to force
the next -MOUNT state:

ALTER DATABASE FORCE FULL DATABASE CACHING;

2.3 library cache disabled to force full
implementation of -MOUNT state:

ALTER DATABASE NO FORCE FULL DATABASE CACHING;

Guess you like

Origin blog.csdn.net/qianglei6077/article/details/92980247