Oracle routine for beginners

Source: Internet
Author: User
Tags oracle rownum

Oracle is still quite common, So I studied the Oracle routine and shared it with you here. I hope it will be useful to you. The Oracle system is huge. To learn about it, you must first understand the Oracle framework. Here, we will give a brief introduction to the Oracle architecture, so that beginners can have a general understanding of Oracle.

1. The physical structure consists of control files, data files, redo log files, parameter files, archive files, and password files)
◆ Control file: contains necessary information to maintain and verify the integrity of the database. For example, a control file is used to identify data files and redo log files. A database must have at least one control file.
◆ Data file: a data file.
◆ Redo log file: contains the changes made to the database, so that data recovery can be enabled in case of a fault. A database requires at least two redo log files.
◆ Parameter file: defines the features of Oracle routines. For example, it contains parameters for adjusting the memory structure of SGA.
◆ Archive file: it is an offline copy of the redo log file, which may be necessary to recover from a media failure.
◆ Password File: Authenticate which users have the permission to start and close Oracle routines.

2. Logical Structure tablespaces, segments, partitions, and blocks)
◆ Tablespace: it is the basic logical structure in the database and a collection of data files.
◆ Segment: the space occupied by objects in the database.
◆ Zone: A large storage space reserved for data at one time.
◆ Block: the most basic storage unit of ORACLE, which is specified when a database is created.

3. Memory Allocation SGA and PGA)

SGA is the memory area used to store database information, which is shared by database processes. It contains data and control information of the Oracle server. It is allocated in the actual memory of the computer where the Oracle server resides. If the actual memory is insufficient, it is written into the virtual memory.

PGA: contains the data and control information of a single server process or a single background process. The SGA shared with several processes is the opposite. PGA is only used by one process, PGA is allocated during Process Creation and recycled upon Process Termination.

4. background process data writing process, log writing process, system monitoring, process monitoring, Checkpoint Process, archiving process, service process, and user process)
Data Writing Process: responsible for writing changed data from the database buffer cache to the data file
Log writing process: writes changes in the redo log buffer to online redo log files.
System Monitoring: Checks Database Consistency and starts database recovery when the database is opened if necessary.
Process Monitoring: clears resources when an Oracle process fails.
Checkpoint Process: updates the database status information in control files and data files whenever changes in the buffer cache are permanently recorded in the database.
Archiving process: backs up or archives a full log group during each log switch.
Service Process: User process service.
User process: On the client, the user is responsible for passing the user's SQL statement to the service process and retrieving the query data from the server segment.

5. Oracle routine:

The Oracle routine consists of the SGA memory structure and background processes used to manage the database. A routine can only open and use one database at a time.

6. SCN (System ChangeNumber ):

System Change number, a serial number maintained by the system. It is automatically added when the system needs to be updated. It is an important indicator of maintaining data consistency and sequential recovery in the system.

  1. Brief Introduction to Oracle 10 Gb Database
  2. Overview of Oracle Database physical files
  3. Description of Oracle data server startup mode
  4. Brief Analysis of Oracle Rownum
  5. Comprehensive Oracle Database 11g debate

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.