Escolar Documentos
Profissional Documentos
Cultura Documentos
21
C H A P T E R
In This Chapter
Introduction to Oracle8 instances Oracle8 database applications Oracle8 Parallel Server applications Distributed database server applications
istributing an Oracle8 database seamlessly throughout your enterprise is a challenge. This process involves knowledge of the Users and the applications that use the database, the Oracle8 instance, and the enterprises network, as well as the Oracle8 applications that support multi-instance communication between the Oracle8 database servers. This chapter focuses on the concepts, strategies, and principles involved in implementing multiple instance Oracle8 database systems in your enterprise.
520
3 Database Write 3 Log Writer 3 Checkpoint 3 System Monitor 3 Process Monitor 3 Archiver 3 Recoverer 3 Lock 3 Snapshot Refresh 3 Dispatcher 3 Shared Servers The background processes depend on the configuration and application of the Oracle8 server.
Note
Oracle8 options and modules installed on a database server also create extra background processes. You can start an Oracle8 instance in either an exclusive or shared (parallel) mode. Once an instance has mounted a database in an exclusive mode, that database cannot be mounted by any other instance. Exclusive mode instances enable you to design Oracle8 applications with interdatabase communication across the nodes in a loosely coupled multiple database system Oracle8 distributed database systems. A database mounted on an instance started in shared or parallel mode, on the other hand, allows other instances residing on other nodes to mount the same database as well. Shared or parallel multi-instance database systems are known as Oracle8 Parallel Server applications. Oracle8 requires interinstance communication across all nodes of the system to manage the parallel DML transactions directed to a single Oracle8 database. The SGA and the Oracle8 processes of an instance work together to manage the databases data. The combination of the SGA and the Oracle8 processes is known as an Oracle database instance.
521
3 Multi-instance database system in parallel mode. 3 Distributed database systems in exclusive mode.
Oracle8 instance
Oracle8 database
522
continued access to all data when one instance fails, including the data accessed by an instance on the failed node. Figure 21-2 illustrates multiple instance database application.
Oracle8 instance
Oracle8 instance
Oracle8 instance
Node 1
Node 2
Node 3
Oracle8 database
An applications performance usually improves with exclusive access to a database on a larger system in comparison with its performance on smaller nodes of a multinode database system. In the latter situation, the high cost of synchronizing and maintaining the database tasks could affect system performance. A Parallel Server accessing a single consolidated database avoids distributed updates, inserts, and deletions. This arrangement also avoids the more expensive two phase commit operations by allowing a transaction on any node to write to multiple Tables simultaneously, regardless of which nodes usually write to these Tables. Overall, the difference in performance depends on the characteristics of all applications sharing access to one single database through the multiple database instances residing on the different nodes of the system.
523
Note
This Oracle8 application requires the Integrated Distributed Lock Manager (IDLM) process to run on each instance. This process communicates with other IDLMs on other instances to coordinate global locking. The following types of applications are best suited for the Oracle8 Parallel Server application: 3 Applications that primarily query data. 3 Applications that either change disjointed groups of data blocks or change the same data blocks at different times. (These characteristics reduce synchronization costs and IDLM work.)
Caution
Do not assume you can seamlessly switch to a Parallel Server application from a single instance application. This change requires a great deal of database design and tuning. Also, the scalability of a system is not only determined by the number of nodes or CPUs involved, but also by interconnect (bandwidth/latency) and by the amount and cost synchronization.
An Oracle8 Parallel Server application, in contrast, involves multiple instances that automatically share direct access to a single Oracle8 database. Figure 21-3 illustrates an Oracle8 distributed database application. With distributed database applications, you can keep the data at several widely separated sites as long as network connections exist between the separate nodes. Parallel Server applications, on the other hand, require all data reside at a single site due to the requirement for low latency and high bandwidth communication between the database nodes. If data can be partitioned into multiple databases with minimal overlap, you should use distributed database applications instead of Parallel Server applications.
524
Oracle8 instance
Oracle8 instance
Net8
Node 1
Node 2
Oracle8 database
Oracle8 database
Administrating a distributed database system requires the coordination of separate database administration between the databases and the network protocols, however. A Parallel Server system, with its consolidated database, greatly simplifies the administrative tasks.
525
In Parallel Server applications, data blocks can be present in several SGAs at the same time. Data sharing between SGAs in an Oracle8 Parallel Server is controlled by the Parallel Cache Management (PCM) process, which uses PCM Locks. PCM Locks ensures database buffer cache consistency for all instances. Each Oracle8 instance in a Parallel Server system has a shared memory pool. Any applications connected to the particular instance use this pool. If the same SQL statement is also submitted by another application on a different instance, then the same SQL statement is parsed and stored on the other instance as well. Each instance in an Oracle8 Parallel Server system has its own set of background processes, which are identical to the background process of a single Oracle8 server in exclusive mode. Each instance of an Oracle8 Parallel Server system has its own dictionary cache containing Data Dictionary information in its SGA. Oracle instances in parallel and exclusive modes have the same Data Dictionary structure. In addition to the standard background processes, each instance of a Parallel Server has at least one lock process (LCK0) additional lock processes can be enabled if required. The Oracle8 Parallel Server also has an Integrated Distributed Lock Manager (IDLM) that uses the LMON and LMD0 processes. The LMON process manages instances and processes the data. The LMD process handles remote lock requests. The lock process (LCKn) manages the locks used by an instance and coordinates requests for those locks by other instances. All instances in an Oracle8 Parallel Server must have the same number of lock processes. When an instance fails in shared mode, another instances System Monitor process detects failure and recovers for the failed instance. The lock process of the recovery instance cleans up any outstanding PCM locks for the failed instance. The following list summarizes the characteristics of an Oracle8 Parallel Server system: 3 It is possible to start an Oracle8 instance on one or more nodes in the network. 3 Each instance has its own SGA and set of background processes. 3 All instances share the same datafiles and Control Files. 3 The redo logs must be accessible to all instances in case of instance failure. 3 Archived Logs are private but must be accessible to all instances for media recovery. 3 All instances can execute transactions concurrently against the same database and each instance can have multiple Users executing transactions. 3 Row level locking is preserved. 3 You must connect to an instance to administer the Oracle8 Parallel Server.
526
In addition to the normal Oracle8 instance background processes, the Oracle8 Parallel Server option also contains the following: 3 A parallel cache management lock area in its SGA to coordinate the use of shared resources. 3 An integrated distributed lock manager. 3 Lock processes to coordinate the locking of shared resources among the multiple processes in a Parallel Server. 3 A lock monitor process to manage global locks and resources.
Task synchronization
In an Oracle8 system, synchronization applies to the coordination of concurrent tasks. The amount of synchronization depends on the amount of resources and the number of Users and tasks working on the resources. Parallel Server database design should have little or no synchronization. A server spending a large amount of time synchronizing tasks indicates a high contention for resources. This contention diminishes the benefits of the parallel processing of tasks. If the cost of synchronization is too high when a Table takes inserts from different nodes, for example, there will be high contention from the different nodes to insert into the same data block. This situation arises because the data block must be passed between the different instance nodes.
Locking
Locks are fundamental to Oracle8 Parallel Server application synchronization. The IDLM is the internal locking facility used by the Oracle8 Parallel Server. The IDLM coordinates resource sharing between nodes running the Oracle8 Parallel Server. The multiple instances also use the IDLM to communicate and coordinate modifications of database resources.
527
Note
Each Parallel Server node operates independently from the other nodes except when contending for the same resources. The IDLM process performs the following database services: 3 Keeps track of the current ownership of a resource. 3 Accepts lock requests for resources from application processes. 3 Notifies the requesting process when a lock on a resource is available. 3 Obtains access to resources for a process. 3 Performs database messaging.
Interinstance communication
The Oracle8 Parallel Server system requires the IDLM to perform interinstance communication over a high network bandwidth with low latency. A networks bandwidth can be described as the total size of messages one can send per second. Latency applies to the time (in seconds) to place a message on the network for processing.
Hardware
Oracle8 Parallel Server systems are more memory- and CPU-intensive than single instance database systems. Migrating or designing a Parallel Server application enables you to complete database tasks in less time. This savings comes with an overhead cost, however. Extra background processes are required for locking and synchronizing tasks from the multiple instances in the Parallel Server system. I recommend the following hardware to support each node in an Oracle8 Parallel Server system: 3 Clustered and Massively Parallel Processing (MPP) hardware in which each node has its own memory. 3 SMP hardware in which multiple processors use one memory resource.
528
ALTER SYSTEM
When an instance adds a datafile or brings an offline datafile online, all instances verify access to that datafile. If the verification fails for any instance, you need to diagnose and repair the datafiles using the ALTER SYSTEM CHECK DATAFILES. This statement ensures online datafiles are available for instances that require access. Oracle8 cannot recover from media instance failure unless the instance that performs recovery can verify access to all online datafiles.
Note
You cannot minimize the number of PCM lock operations during the final tune of the system. You must plan this stage early in the physical database design process. By partitioning the application and data, you obtain greater cache affinities between the database data and the specific nodes. A partitioned application ensures Oracle8 performs a minimum number of lock conversions. In this way, you reduce data block pinging and IDML activities. A lock conversion occurs when a shared lock moves up to an exclusive lock and vice versa.
529
must undertake an access cross-reference profile of the application Tables and their respective access patterns. This profiling exercise can include: 3 Identifying read only Tables 3 Experiencing random SELECT and UPDATE SQL operations 3 Experiencing SELECT, INSERT, UPDATE, and DELETE SQL operations
ALTER TABLESPACE
Consider putting read only Tables on read only Tablespaces using the ALTER TABLESPACE READ ONLY statement. This placement speeds recovery and does not require PCM locks.
These types of SQL operations require reading a number of data blocks and modifying some or all of the data blocks read. This process requires converting the PCM locks to shared mode and then converting them to exclusive mode after block modification. Again, if these types of transactions are executed from different nodes, a performance penalty could result from the number of PCM locks converted and held. Using the Table access profiles, you can differentiate between transactions that run well over multiple Oracle8 Parallel Server nodes and transactions which should be executed within a single node. Load balancing between the nodes should not be the main objective. Partitioning is the key to good performance and CPU utilization in an Oracle8 Parallel Server system.
530
Partitioning Users
Users can be partitioned based on the following criteria: 3 The groups of Users who access the database 3 Application User groups that access the same data 3 Users based on their respective locations
Partitioning applications
Partitioning applications involves running different applications on different instance nodes in an Oracle8 Parallel Server system. Application partitioning yields good performance as long as you assign different PCM locks to their respective datafiles. With this approach, you must ensure each applications Tables and Indexes are stored so that a PCM lock does not cover any data blocks used by more than one application. Applications that share a set of SQL statements perform optimally when run on the same instance because SQL areas are not shared across instances. Similar sets of SQL statements should run on one instance to improve memory usage and reduce parsing.
Note
This partitioning model is very similar to a distributed database model in which the accessed database Objects are stored together. Data partitioning. In data partitioning, you partition the data vertically and horizontally. This type of partitioning ensures each SQL transaction is executed upon the correct Oracle8 Parallel Server instance. The correct node for execution of the SQL transaction depends on the actual data values used in the transaction. Another name for this process is data-dependent routing. Vertical partitioning. Vertical partitioning divides tables among the instances. Applications run against tables in a single partition and a large number of tasks can run on a large number of resources without substantial synchronization. Figure 21-4 illustrates vertical partitioning of an Oracle8 Parallel Server system. In this example, tables used only for engineering students reside in one partition, exclusive tables for computer science students are stored in a second partition, and tables only for accounting students are placed in a third partition of the database. The three parallel nodes each serve a single set of students so there is no resource contention between the nodes.
531
Oracle8 instance
Oracle8 instance
Oracle8 instance
Engineering student
Accounting student
Node 1
Node 2
Node 3
Oracle8 Database
Engineering Accounting
Computer science
Horizontal partitioning
Horizontal partitioning divides portions of tables among the instances based on a data value. Suppose an Oracle8 Parallel Server system is made up of four instances. The data can be partitioned so that each instance accesses only a subset of the whole data. Little synchronization is necessary because the instances access different sets of rows. Figure 21-5 illustrates horizontal partitioning of an Oracle8 Parallel Server system. In this type of partitioning, a single tables rows are divided into partitions. The three partitions base their division of rows on the type of student (engineering, computer science, or accounting). Furthermore, the three nodes have applications dedicated to a single type of student. Few transactions affect more than one partition, thus minimizing synchronization.
532
Oracle8 instance
Oracle8 instance
Oracle8 instance
Engineering student
Accounting student
Node 1
Node 2
Node 3
Oracle8 database
Node 1 data
Node 2 data
Node 3 data
533
global constant initialization parameters some of which must be identical for all instances. When the instances of the Parallel Server start, each instance compares the global constant initialization values with other instances in the Parallel Server system. If certain core values are different, Oracle8 generates a message and the Parallel Server system startup fails.
The PFILE option of the STARTUP command enables you to specify a parameter file other than the default file when you start an instance. The parameter must be accessible to the local node, even for an instance on a Remote node.
534
ALTER DATABASE
Use the following steps as a guide to starting the instances on each node of the Parallel Server system: 1. Set the PARALLEL_SERVER parameter to TRUE in the initialization file. (Default is FALSE.) 2. Start any required OS-specific processes. 3. Start Group Membership Services. 4. Connect with SYSDBA or SYSOPER privileges or connect as INTERNAL. 5. Start an instance by using the following command:
STARTUP NOMOUNT;
If an instance mounts a database with the PARALLEL_SERVER parameter set to FALSE, no other instance can mount that database. Before you can start an instance in exclusive mode, you must shut down all instances running in shared mode. Suppose you attempt to start an instance and mount a database in shared mode while another instance is currently recovering the same database. Your new instance cannot mount the database until the recovery is complete. In this case, specify the STARTUP RETRY statement, which causes the new instance to attempt to remount the database every five seconds until it succeeds. For example:
STARTUP OPEN <database_Name> RETRY;
535
for INSERTs and UPDATEs and enables efficient maintenance of partitioned data among the instances. If an instance does not use a specified instance number, it automatically acquires the lowest available instance number. The startup order of the instances determines the instance numbers for those instances that do not specify their own INSTANCE_NUMBER parameter. These nonspecified instance numbers are difficult to control when instances start in parallel because a particular instance receives a new number when you shut down and restart that instance.
Note
Instance numbers must be unique for each instance in the Oracle8 Parallel Server system. The SHOW PARAMETERS INSTANCE_NUMBER command displays the instance numbers assigned for each instance in an Oracle8 Parallel Server system. A null value for an instance number implies the value is server-assigned.
You cannot change instance groups dynamically. To use a particular instance group for a given parallel operation, specify the following parameter in the initialization file:
PARALLEL_INSTANCE_GROUP = <groupname>
All operations initiated from that instance spawn processes only within that group. You can change this dynamic parameter using ALTER SESSION or ALTER SYSTEM commands.
536
537
Space management
Allocating space for inserts creates space management issues in an Oracle8 Parallel Server system.
Example
For example, when a Table uses more space for an INSERT operation, how do you make sure no other INSERT transaction uses the same space? How can you make sure two nodes are not inserting into the same space on the same disk in the same Datafile? The Oracle8 Parallel Server system uses free lists and free list groups to optimize space management.
Free lists
A free list is a set of data blocks located in extents that contain free space. You use these data blocks when you make INSERTs or UPDATEs to a database Object (such as a Table or a cluster). No contention among instances occurs when different instance transactions insert data into the same database Object. Oracle8 locates the free space for the new rows using free space lists it associates with one or more instances. The free lists may be from a common pool of blocks or multiple free lists can be partitioned so specific extents in files are allocated to objects.
538
across instances including lock messages piggyback the SCNs. Thus, you generate the SCNs without extra communication among the multiple instances.
539
instance lock from another instance. The instance requiring the data block uses the IDLM to request the locking instance to disown the instance lock, writing the blocks to disk if necessary. Read lock mode. The read lock mode only allows the instance to read the data blocks. Multiple instances can own an instance read lock as long as they do not modify the data blocks covered. Null lock mode. The null lock mode allows instances to keep a lock without any permission on the actual data block. This mode is useful when you do not continually need to obtain and release instance locks, thus saving the cost of lock conversions.
Higher performance
A Parallel Server takes advantage of each instances processor by sharing resources without sacrificing any transaction processing features of the Oracle8 DBMS. Utilizing this database topology, more CPUs are available to an application. The improvement in performance is dependent on the degree of internode locking and synchronization activities, however. Each lock operation is processor- and message-intensive, thereby allowing for high levels of latency.
540
Higher availability
An Oracle8 Parallel Server system isolates the nodes. In this way, a failure at one node does not crash the whole system. The remaining nodes can recover the failed node transactions and continue to provide data access to Users. This strategy enables applications to automatically reconnect to the database after a break in the connection. On instance failure, any active transactions are rolled back the new database is identical to the original database. An Oracle8 Parallel Server system never allows a client to experience loss of connection as long as one instance is left serving the application.
Tip
The DBA should dictate which applications run on the different Oracle8 instances, thus creating a failover order for each application.
Greater flexibility
Instances can be allocated or deallocated from an Oracle8 Parallel Server system as necessary. If there is a high demand for database resources, instances can be temporarily allocated. Once the traffic for the database reduces, the instances can be deallocated from the system. Thus, the DBA can set up instance allocation strategies based on peak and nonpeak times of a database applications usage.
More Users
An Oracle8 Parallel Server system can overcome memory limits by enabling a single system to serve thousands of Users.
The IDLM locks coordinate sequences across the multiple instances in an Oracle8 Parallel Server.
541
behalf of a single query. The Parallel Server splits individual queries into units of work Oracle8 can process simultaneously.
Tip
In general, queries consume more CPU and disk I/O than INSERT, UPDATE, and
DELETE transactions.
Database replication should not be confused with a distributed database system. Replication is the process of copying and maintaining database objects in multiple databases that compose a distributed database system. You need a networking infrastructure to link and allow the Oracle8 database servers to communicate with each other. You can accomplish this interdatabase communication by using Net8, Oracles networking software for distributed database systems. Net8 supports remote and distributed transactions in an Oracle8 distributed database system. Net8 makes the connectivity necessary to transmit SQL requests transparent and receives data for applications using the distributed database system. Net8 transmits SQL and Packages to an Oracle server over industry-standard communication protocols (such as TCP/IP). Net8 also receives replies from a server and packages them for transmission back to the appropriate client.
Note
Net8 supports all interdatabase communication independent of an underlying network operating system.
542
An Oracle8 network can also use Oracle Names to provide the system with a global directory service. This service acts as a central repository for information about each database in the distributed system. Thus, introducing Oracle Names to a distributed database system eases the configuration of all distributed database access requirements.
Each Oracle8 Open Gateway product contains some or all of the preceding features.
543
3 The importance of access of a node if the link goes down 3 The need for referential integrity among remote and local Tables using Constraints and Triggers Each preceding point is critical in any Oracle8 distributed database environment.
Location transparency
Location transparency enables a User or application to refer universally to a database Object, regardless of the location of the node to which the database connection takes place. The advantages for location transparency follow: 3 Access to remote data is simple because the Users are not concerned with the physical location of the database Objects. 3 Administrators can move database Objects with no impact on end Users or existing applications. You can achieve location transparency for database Objects by creating Synonyms.
544
A Synonym can be created for any Table, type, view, snapshot, sequence, Procedure, function, or Package. All Synonyms are stored in the Data Dictionary of the database in which they are created.
See Reference Section
CREATE SYNONYM
For example, the following statement creates a Synonym for the STUDENTS Table residing in the ObjectMind domain:
CREATE PUBLIC SYNONYM students for tony.students@UK.ObjectMind.COM
To access the STUDENTS Table without using Synonyms, use the following SQL statements:
SELECT student_Name FROM tony.students@UK.ObjectMind.COM
With the Synonym in place, you can issue the following SQL statement to retrieve the same results:
SELECT student_Name FROM students
A Synonym is a reference to an actual database Object. A User with access to a Synonym for a particular Schema Object must also have privileges on the Schema Object itself. The owner of the local Synonym cannot grant any Object privileges on the Synonym to any other local User.
Tip
Local views can also provide location transparency for database Tables residing on remote databases.
The preceding DML statements must reference LONG and LONG RAW data on the same node.
545
Note
You should name a database link the global database name of the remote database it references. Oracle uses the global database name to globally name the Schema Objects using the following naming convention:
<Schema>.<schema_Object><@Global_Database_Name>
For example, the following global Object name identifies the STUDENTS Table in Marias Schema in the UK.ObjectMind.COM domain:
maria.students@UK.ObjectMind.COM
Tip
If you set the GLOBAL_NAMES initialization parameter to TRUE, Oracle8 ensures the database link name matches the global database name of the remote database. Once global naming has been enabled, database links are essentially transparent to the Users and applications of a distributed database system.
Database links
Database links facilitate application database requests within an Oracle8 distributed database system. These links define a one-way communication path from one Oracle8 database to another Oracle8 database. A database link should
546
be transparent to Users and applications if it shares the same name as the global name of the database to which the link points.
See Reference Section
For example, the following statement creates a database link in a local server to the UK.ObjectMind.COM database:
CREATE DATABASES LINK UK.ObjectMind.COM;
After creating this database link, Users and applications connected to the local database can immediately access data in the remote UK.ObjectMind.COM database. If the Oracle8 Names server is used to resolve distributed database network addresses for the SQL queries, the Net8 Assistant tool can also create database links, as illustrated in Figure 21-6.
547
Database links can be created with three levels of security: Private. With a private database link, only the owner of a database link or PL/SQL subprograms in the schema can use the link to access data and Objects in a corresponding remote database.
See Reference Section
To create a private database link, begin the command using the following syntax:
CREATE PRIVATE DATABASE LINK...
Private links can only be used by the user that created the link. Public. With a public database link, all Users and PL/SQL subprograms in a database can use a public database link to access data and database Objects in the corresponding remote database.
See Reference Section
To create a public database link, begin the command using the following syntax:
CREATE PUBLIC DATABASE LINK...
Global database links. Global database links only apply to networks that use Oracle Names. In such a system, the Oracle8 Name servers automatically create and manage global database links for every Oracle8 database in the network. With a private or public database link, you can dictate to which Schema on the remote database the database link establishes connections. To enable these connections, create fixed User, current User, and connected User database links. Fixed User database link. With a fixed User database link, the local server always establishes a connection to a fixed remote Schema in the remote database. Use the following syntax to create a fixed User database link:
CREATE [PUBLIC] DATABASE LINK <db_Link_Name> [CONNECT TO Username IDENTIFIED BY Password] | [CONNECT TO CURRENT_USER] AUTHENTICATED BY Schema_Name IDENTIFIED BY Password [USING 'service_name'];
Connected User and current User database links. In an Oracle8 distributed database system, the credentials used to connect to a remote database can change depending on the User referencing the database Link and the operations performed by the application. For example, if you want to establish a database link based on the type of credentials of the connected User or applications, you create connected User and current User database links.
548
A connected User connects to a database using a database application. A current User connects to the database in the security context in which a database operation executes. Use the following syntax to create a connected User database link:
CREATE [PUBLIC] DATABASE LINK <db_Link_Name> AUTHENTICATED BY Schema_Name IDENTIFIED BY Password [USING 'service_name'];
Shared database links. By default, every application that references a remote server using a standard database link establishes a connection between the local database and the remote database. Therefore, many Users or applications accessing the databases simultaneously can cause the number of connections between the local and remote databases to increase suddenly. You can use shared database links to resolve the escalating connection problem. Shared database links limit the number of network connections required between the local and remote server. Use shared database links when you expect the number of Users accessing a database link to be much larger than the number of shared servers in the local database. Use the following syntax to create a shared database link:
CREATE SHARED DATBASE LINK <db_Link_Name> [CONNECT TO Username IDENTIFIED BY Password] | [CONNECT TO CURRENT_USER] AUTHENTICATED BY Schema_Name IDENTIFIED BY Password [USING 'service_name'];
Note
To use shared database links, the local server must run in Multi-Threaded Server (MTS) mode. The remote server can either run in MTS mode or dedicated server Mode.
To drop an existing database link regardless of its type, use the following syntax:
DROP DATABASE LINK <db_Link_Name>
Tip
Use one of the following Data Dictionary views first to confirm the database link exists.
549
Do not confuse a remote transaction with a distributed transaction. A remote transaction contains remote statements that all reference the same remote node. A distributed transaction includes statements that individually or as a group update data on two or more distinct nodes of a distributed database system.
Queries starting after a node has prepared the transaction cannot access the associated locked data until all phases are complete.
550
When a requester instructs a node to prepare, it can respond using the following return values: 3 Prepared. Implies the node has successfully prepared. 3 Read Only. Implies data on the node can only be queried, not modified. 3 Abort. Implies the node could not successfully prepare, causing the transaction to be rolled back immediately.
Client
The client node references information from another nodes database.
Database server
The database server node is directly referenced in a distributed transaction or is requested to participate in a transaction because another node requires data from its database.
551
Global coordinator
The global coordinator node identifies the node from which the distributed Transaction originated. This node becomes the parent node or root of the session tree. The global coordinator node performs the following steps: 1. It sends all distributed transactions directly to the referenced nodes, thus forming the session tree. 2. If all nodes prepare successfully, the global coordinator instructs the commit point site to initiate the global commit of the transaction. 3. If one or more abort messages are received, the global coordinator instructs all nodes to initiate a global rollback of the transaction.
Local coordinator
The local coordinator node references data on other nodes to complete its part in a distributed transaction. The following criteria determine the roles played by nodes in a distributed transaction: 3 Whether a transaction is local or remote to the node 3 The commit point strength of that node 3 Whether all requested data is available at a node or whether other nodes need to be referenced 3 Whether the node is read only
You can set a nodes commit point strength by using the initialization parameter COMMIT_POINT_STRENGTH. The range of valid values for the commit point strength are 0 200.
552
Summary
This chapter introduces the concept of having multiple instances to an Oracle8 database. Multiple instance Oracle8 databases can be created using two different architectures the Oracle8 Parallel Server option and the Oracle8 distributed database architecture. Both architectures require a great deal of architecture planning and implementation effort. The end result, embraced by the hardware resources, provides fault tolerant node architectures for an Oracle8 database. The advantages of distributing the processing and data across multiple modes (Parallel Server) and databases (Distributed Architecture) are as follows: 3 Increased performance on most transactions. 3 Increased transaction handling. 3 Higher availability for the database system. 3 The flexibility to handle a larger user population. 3 Better backup and recovery strategies. 3 Distribution of the data processing throughout the database system.
Parallel Server
This Oracle8 Parallel Server architecture is designed to create multiple instances on the Oracle8 nodes. All Oracle8 instances share a single physical database. Each Parallel Server node has its own suite of Oracle8 instance background processes, including the Integrated Distributed Lock Manager (IDLM). The Oracle8 Parallel Server architecture divides large database transactions into smaller transactions that are executed concurrently on the Oracle8 Parallel Server nodes. Each independent transaction executes immediately on its respective nodes processor with no wait time. The Oracle8 Parallel Server can load balance the database transactions across the multiple nodes in the architecture, providing concurrent access to the data.
Chapter 21 3 Summary
553
Each Oracle8 database in a distributed database system efficiently cooperates with the other remote Oracle8 databases to maintain consistency of the globally distributed data. Net8 gels the network communications required between the distributed databases. The Oracle8 distributed model permits the integration of heterogeneous systems.