patternMinor
Database instance and database
Viewed 0 times
databaseinstanceand
Problem
I did some research and finally came to this conclusion:
Database instance = processes + memory
Database = (physical) log files + control files + data files.
Thanks.
Database instance = processes + memory
Database = (physical) log files + control files + data files.
- Is this understanding correct?
- Can an application use multiple database instances of the same database?
- Can a table in database be used by multiple database instances at the same time?
Thanks.
Solution
Technically instance resides in memory and database (physical files) resides on disk. There can be an instance without a database (an example is a started instance right before you create a database). There also can be a database without an instance (example of this is database files residing on disk but instance is not running, or files copied to some other location, something along those lines). Typically you use database by connecting your client to it's instance in order to do some work on data contained within. So an instance, upon startup, associates itself with one or more databases (Firebird, for example - one server process can be used to connect to multiple databases).
Second question: Only in some High-Availability environment, namely RAC on Oracle, where multiple instances are clustered to service the same database. This is transparent to end-users, so practically no, it can't. If you're talking about non-clustered configurations then no - no two instances can use same set of database files, therefore no application can use more than one instance connected to the same set of database files. At least not in RDBMS I know about. However an application can, theoretically, use two instances servicing two distinct copies of the same database, why not. Only I can't see real-world reason to do so.
Third question: already answered. No database can be serviced by two instances unless it's some kind of HA environment.
EDIT about object types
This is what resulted from a query of
Second question: Only in some High-Availability environment, namely RAC on Oracle, where multiple instances are clustered to service the same database. This is transparent to end-users, so practically no, it can't. If you're talking about non-clustered configurations then no - no two instances can use same set of database files, therefore no application can use more than one instance connected to the same set of database files. At least not in RDBMS I know about. However an application can, theoretically, use two instances servicing two distinct copies of the same database, why not. Only I can't see real-world reason to do so.
Third question: already answered. No database can be serviced by two instances unless it's some kind of HA environment.
EDIT about object types
This is what resulted from a query of
select distinct object_type from dba_objects to my Ora 10g, it surprised even myself:CONSUMER GROUP, INDEX PARTITION, SEQUENCE, QUEUE, SCHEDULE, TABLE PARTITION, RULE, PROCEDURE, OPERATOR, LOB PARTITION, WINDOW, LOB, PACKAGE, PACKAGE BODY, LIBRARY, RULE SET,
PROGRAM, TYPE BODY, CONTEXT, TRIGGER, JOB CLASS, UNDEFINED, DIRECTORY, MATERIALIZED VIEW, TABLE, INDEX, SYNONYM, VIEW, FUNCTION, WINDOW GROUP, CLUSTER, TYPE, RESOURCE PLAN, EVALUATION CONTEXT, JOBContext
StackExchange Database Administrators Q#69989, answer score: 9
Revisions (0)
No revisions yet.