INSYS 366 Oracle Memory Internals 2252021 ISYS 366

  • Slides: 6
Download presentation
INSYS 366 Oracle Memory Internals 2/25/2021 ISYS 366 , Oracle Memory Internals 1

INSYS 366 Oracle Memory Internals 2/25/2021 ISYS 366 , Oracle Memory Internals 1

Oracle Memory Structures n Oracle instance n n 2/25/2021 Have names Memory buffers (SGA)

Oracle Memory Structures n Oracle instance n n 2/25/2021 Have names Memory buffers (SGA) Background processes (Oracle processes) Parallel servers may share a database 2

Oracle Memory Structures n PGA (Program/Private/Process Global Area) n n Stores data and control

Oracle Memory Structures n PGA (Program/Private/Process Global Area) n n Stores data and control information for a single user process Created when a user process connects to database (e. g. , SQL*Plus) n n n Stack space, containing contents of variables and arrays that the session is using Session information All this depends on whether you are running a multi-threaded server 2/25/2021 3

Oracle Memory Structures n SGA (System/Shared Global Area) n n Stores data that the

Oracle Memory Structures n SGA (System/Shared Global Area) n n Stores data that the user has retrieved from the database or that the user wants to stored in the database. The importance of this is due to the high cost of disk I/O. Contains n n 2/25/2021 Database buffer cache Redo log buffer Shared pool Cursors 4

Oracle Memory Structures n SGA (System/Shared Global Area) n Contains n Database buffer cache

Oracle Memory Structures n SGA (System/Shared Global Area) n Contains n Database buffer cache n n n Redo log buffer n 2/25/2021 1. Data blocks (written by DBWR process). Buffer size and number of buffers are specified in INIT<SID>. ORA 2. Index blocks 3. Rollback segment blocks 4. Temporary segment blocks Written to the Redo logfiles by LGWR 5

Oracle Memory Structures n SGA (System/Shared Global Area) n Contains n Shared pool n

Oracle Memory Structures n SGA (System/Shared Global Area) n Contains n Shared pool n n Cursors n n 2/25/2021 1. Data dictionary cache: most frequently asked questions of the data dictionary 2. Library cache: PL/SQL statements and its execution plan (e. g. , whether indexes will be used) 3. Control structures: locks, cache handles, etc. 1. Parsed SQL statements (the parsed representation of a SQL statement) 2. Execution plan (algorithm for executing the statement) 3. Number of rows affected 4. In the case of a SELECT, the rows returned 6