Oracle 中的一个实例与多个实例
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/3566349/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
One Instance Versus Multiple Instances In Oracle
提问by BeginnerAmongBeginners
What are the advantages and disadvantages of having a single instance compared to multiple instances when multiple databases are intended to be created?
当打算创建多个数据库时,与多个实例相比,拥有单个实例的优点和缺点是什么?
回答by Vincent Malgrat
You may want to browse the Oracle concept guide, especially if you're more familiar with other DBMS.
您可能想浏览Oracle 概念指南,尤其是在您更熟悉其他 DBMS 的情况下。
- A database is a set of files, located on disk, that store data. These files can exist independently of a database instance.
- An instance is a set of memory structures that manage database files. The instance consists of a shared memory area, called the system global area (SGA), and a set of background processes. An instance can exist independently of database files.
- 数据库是位于磁盘上的一组文件,用于存储数据。这些文件可以独立于数据库实例而存在。
- 实例是一组管理数据库文件的内存结构。该实例由一个共享内存区域(称为系统全局区域 (SGA))和一组后台进程组成。实例可以独立于数据库文件而存在。
A single instance (set of processes) can mount at mostone database (set of files). If you need to access multiple databases, you will need multiple instances. More on the difference between instances and databases on askTom.
单个实例(一套流程)可以安装在最多一个数据库(组文件)。如果您需要访问多个数据库,您将需要多个实例。有关askTom 上实例和数据库之间差异的更多信息。
Ideally, you only want one instance per server (the server may be a logical server -- i.e a virtual server). This will allow Oracle to know exactly what is going on. This implies one database per server.
理想情况下,您只需要每台服务器一个实例(该服务器可能是一台逻辑服务器——即虚拟服务器)。这将使 Oracle 能够准确了解正在发生的事情。这意味着每台服务器一个数据库。
If your databases are really independent, going with multiple instances/databases would make sense, since you have greater control over DB version, administration, etc.
如果您的数据库真的是独立的,那么使用多个实例/数据库是有意义的,因为您可以更好地控制数据库版本、管理等。
If however your databases are not really independent (you frequently share data across them, you need some common data accessible to all of them), it may be more efficient (and simpler) to go with a single consolidated database. Each original database would have its own set of schemas. In this case cross-schema referential integrity would be easy, you wouldn't need to duplicate the data that needs to be shared.
然而,如果您的数据库并不是真正独立的(您经常在它们之间共享数据,您需要一些可供所有数据库访问的公共数据),使用单个统一数据库可能会更有效(也更简单)。每个原始数据库都有自己的模式集。在这种情况下,跨架构参照完整性会很容易,您不需要复制需要共享的数据。