Oracle 体系结构
1、数据库和实例的关系 Oracle数据库database (物理结构) 包括有数据文件、控制文件、重做日志文件 数据库实例instance (逻辑结构) 实例是一系列复杂的内存结构和操作系统进程组成的 包括有数据库后台进程(PMON、SMON、DBWR、LGWR、CKPT等),内存区域SGA 数
1、数据库和实例的关系Oracle数据库database (物理结构)
包括有数据文件、控制文件、重做日志文件
数据库实例instance (逻辑结构)
实例是一系列复杂的内存结构和操作系统进程组成的
包括有数据库后台进程(PMON、SMON、DBWR、LGWR、CKPT等),内存区域SGA
数据库与实例之间是1对1/n的关系
非并行是1对1,并行可以1对多,但同一时间只能有一个实例运行
2、 SGA的各个组成部分的名称和作用
PGA与它有什么区别?
SGA(System Global Area系统全局区)主要由三个部分组成:
1.数据库高速缓冲(the data buffer cache)
存放着Oracle系统最近使用过的数据块(即用户的高速缓冲区),避免重复读取常用的数据
2.重做日志缓冲(the redo log buffer)
缓存对于数据块的所有修改以进行恢复,减少了磁盘的读写
3.共享池(the shared pool)
用于缓存最近被执行的SQL语句和最近被使用的数据定义,减少了相同SQL的编译,提高了SQL执行的速度
PGA(Process Global Area程序全局区)是为每个连接到Oracle database的用户进程保留的内存。
每个实例只有一个SGA,所有的进程都能访SGA,是共享的。
每个一个进程都一个PGA,PGA是私有的,只有对应进程才能访问。
3、数据库的逻辑结构是什么?
tablespace>segment>extent>block
数据块(block)Oracle的最小存储单元
区段(extent)是一组连续的Oracle数据块(block),它是磁盘分配的最小单元
段(segment)是在Oracle中占有磁盘空间的对象,它们由一批区段(extent)所组成
多个段组成表空间 (tablespace)
4、视图和同义词视图可以理解为虚拟的表,但是并不以表的形式保存
使用视图 ①可以提高安全性,屏蔽敏感字段
②可以使复杂的查询变得简单(如N个表连接)
同义词和字面意思理解的一样,就是别名,和视图功能类似,就是一种映射关系
可以为数据库中的 表、视图、序列、存储过程、包等定义同义词
同义词分为公有和私有两种,公有的同义词所以用户都可以使用,私有的同义词由创建者所以
使用同义词可以屏蔽对象的名字及其持有者,简化sql语句
视图和同义词都不占用实际存储空间,只有在数据字典中保存了对应的定义

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics











MySQL is an open source relational database management system, mainly used to store and retrieve data quickly and reliably. Its working principle includes client requests, query resolution, execution of queries and return results. Examples of usage include creating tables, inserting and querying data, and advanced features such as JOIN operations. Common errors involve SQL syntax, data types, and permissions, and optimization suggestions include the use of indexes, optimized queries, and partitioning of tables.

MySQL is chosen for its performance, reliability, ease of use, and community support. 1.MySQL provides efficient data storage and retrieval functions, supporting multiple data types and advanced query operations. 2. Adopt client-server architecture and multiple storage engines to support transaction and query optimization. 3. Easy to use, supports a variety of operating systems and programming languages. 4. Have strong community support and provide rich resources and solutions.

In Oracle, the FOR LOOP loop can create cursors dynamically. The steps are: 1. Define the cursor type; 2. Create the loop; 3. Create the cursor dynamically; 4. Execute the cursor; 5. Close the cursor. Example: A cursor can be created cycle-by-circuit to display the names and salaries of the top 10 employees.

Oracle views can be exported through the EXP utility: Log in to the Oracle database. Start the EXP utility, specifying the view name and export directory. Enter export parameters, including target mode, file format, and tablespace. Start exporting. Verify the export using the impdp utility.

MySQL is suitable for web applications and content management systems and is popular for its open source, high performance and ease of use. 1) Compared with PostgreSQL, MySQL performs better in simple queries and high concurrent read operations. 2) Compared with Oracle, MySQL is more popular among small and medium-sized enterprises because of its open source and low cost. 3) Compared with Microsoft SQL Server, MySQL is more suitable for cross-platform applications. 4) Unlike MongoDB, MySQL is more suitable for structured data and transaction processing.

When Oracle log files are full, the following solutions can be adopted: 1) Clean old log files; 2) Increase the log file size; 3) Increase the log file group; 4) Set up automatic log management; 5) Reinitialize the database. Before implementing any solution, it is recommended to back up the database to prevent data loss.

Oracle is not only a database company, but also a leader in cloud computing and ERP systems. 1. Oracle provides comprehensive solutions from database to cloud services and ERP systems. 2. OracleCloud challenges AWS and Azure, providing IaaS, PaaS and SaaS services. 3. Oracle's ERP systems such as E-BusinessSuite and FusionApplications help enterprises optimize operations.

Building a Hadoop Distributed File System (HDFS) on a CentOS system requires multiple steps. This article provides a brief configuration guide. 1. Prepare to install JDK in the early stage: Install JavaDevelopmentKit (JDK) on all nodes, and the version must be compatible with Hadoop. The installation package can be downloaded from the Oracle official website. Environment variable configuration: Edit /etc/profile file, set Java and Hadoop environment variables, so that the system can find the installation path of JDK and Hadoop. 2. Security configuration: SSH password-free login to generate SSH key: Use the ssh-keygen command on each node
