Learning oracle, the best way to first understand the framework of Oracle on the Oracle an overall understanding of the role of a strategically advantageous position
1, the physical structure (the control files, data files, redo log files, parameter files, archived files, password files)
The data stored in a database physical file on disk, is used, into memory
Which control the files, data files, redo log files, trace files and the warning log (trace files, alert files) is a database file;
Parameter file (parameter file) password file (password file) non-database files
1.1 Data File: store data files. Data file typically represents the basis of their use of disk space and amount determined by the volume of an Oracle database
For performance reasons, each type of data in the corresponding one or a series of documents in these files on different disks
types:
. Data dictionary. Data
. Redo data. Index
. Temporary data, etc.
1.2 control file: to maintain and verify database integrity contains the necessary information, for example, control file used to identify the data files and redo log files, a database at least one control file.
Control file content
Database name
Table space information
All of the data file name and location
All redo log file name and location
The current log sequence number
Check Point Information
Redo logs and archive on the current state of information
The use of process control file
Oracle control file to boot to the other parts of the database file when an instance starts, Oracle parameter file to read from the control file name and location of the installation database, Oracle opens the database control file to open the final, Oracle reads the data from the control file the list of files and open each file which
1.3 redo log files:
Changes to the database containing records of this case failure can enable a database data recovery needs at least two redo log files.
1.4 trace file and the warning log (Trace Files and Alert Files)
In each instance running in the background process has a trace file (trace file) connected to Trace file records events encountered in the process of background information
Warning Log (Alert Log) is a special trace file, there is a trace file for each database, synchronization and error messages recorded in the database.
1.5 parameter file: impact of Oracle database instances, including a large number of features set, such as the following settings:
Database control file location
Oracle is used to cache data read from the disk the amount of memory
The default choice of the optimization process.
[Next]
And database files related to the implementation of two important functions
1> for the database control files that
2> for the database archive log that the goal
1.6 archive: yes copy offline redo log files, these copies may be to recover from media failure is necessary.
1.7 password file: certification which users have permission to start and stop Oracle routines.
2, logic structures (table spaces, section, district, block)
Table space: a database of basic logical structure, a series of collection of data files.
Section: the object in the database space occupied.
District: data once reserved for a large storage space.
Block: ORACLE basic storage unit, the time specified in a database.
3, memory allocation (SGA and PGA)
SGA: is used to store database information memory area, the information sharing process for the database. It contains the Oracle server's data and control information, which is the Oracle server resides in the computer's real memory can be allocated, if not go down to the actual memory write virtual memory.
PGA: contains a single server process or a single background process data and control information, and contrary to several processes to share SGA, PGA is the only area used by a process, PGA is allocated in the creation process, when the termination process of recovery.
4, the background process
Including data write process (Database Writer, DBWR), the log write process (Log Writer, LGWR), System Monitor (System Monitor, SMON), process monitor (Process Monitor, PMON), the checkpoint process (Checkpoint Process, CKPT), Filed process, service process, the user process)
Data write process: responsible for the changed data from the database buffer cache to write data files
Log write process: the redo log buffer to write the changes in online redo log files
System Monitoring: Check the consistency of the database, if necessary, open the database will start to restore the database
Process Monitoring: Oracle process responsible for a failure to clean up resources
Checkpoint process: When the buffer cache responsible for changes in permanently recorded in the database, update the control file and data files in the database state information. The process occurs at checkpoints on all the data files to modify the title, indicating that the checkpoint. Under normal circumstances, the task execution by the LGWR. However, if the checkpoint significantly reduce system performance, enable CKPT process running, the original implementation by the LGWR process checkpoint separating the work, achieved by the CKPT process. For many applications, CKPT process is unnecessary. Only when the database has many data files, LGWR check point in significantly reduced performance only to CKPT run. CKPT process not to block written to disk, the work is done by the DBWR. init.ora file CHECKPOINT_PROCESS CKPT process parameter control to enable or not. Default when FALSE, shall be unable.
Archiving process: each log in the log when switching to full backup or archiving group
Service process: the process of service users.
User process: the client is responsible for the user's SQL statement passed to the service process and query data back from the server segment.
5, SCN (System ChangeNumber):
System change number, a serial number within the system maintenance. When the system needs to be updated automatically when the increase, he is the system in order to maintain data consistency and important sign of recovery.