![]() |
|
|
||
| FireWire Real Application Cluster
With the demands of a 24/7 marketplace, a highly available and scalable database is getting increasingly more important. In the past, you had to choose from one of two options in a cluster. High availability clusters were used to protect your database from hardware failure. Load balanced clusters with many nodes were used to support a much larger volume of traffic than single multi-processor implementations. Redundant components such as additional nodes, multiple interconnects, and arrays of disks helped provide high availability. Such redundant hardware architectures avoid single points-of-failure and provide exceptional fault resilience. RAC takes the cluster architecture even further, providing improved fault resilience and incremental system growth by offering connection failover and load balancing in the same cluster. In the event of a system failure, RAC ensures your database will still be available. In the event of a large spike in traffic, RAC can distribute the load over many nodes. Not only does RAC make good sense from a data availability and performance point of view, but with large SMP servers going for a premium price a pair of 2 processor servers can be half the cost of a single 4 processor server. RAC gives you the availability and scalability that enterprises demand. RAC provides the following key benefits to e-business application deployments:
An alternative to using a Storage Area Network (SAN) or Network Attached Storage (NAS) is an external FireWire hard drive enclosure. This allows a low cost solution for testing your systems in a RAC environment prior to roll-out on your production RAC. With the use of commodity hardware you can build your development environment for a fraction of the cost. This article looks at the process and some helpful tips to help you configure RAC for your development environment using a low cost alternative to a SAN, etc. After reading this article you should be able to setup your RAC environment more quickly and with fewer headaches.
Background / Overview
Our environment was set up to provide us with a low cost development environment to see how RAC fit into our application environment. We had two Compaq 700 MHz Pentium3 desktops, each with 512MB RAM and 10GB internal drives. We also had a spare switch to use for the interconnect. The only hardware we needed to purchase was an external FireWire enclosure, an IDE hard drive and two FireWire adapters. These additional hardware components came up to less than $400.
By the end of this article you will understand the steps necessary to setup your own RAC environment for testing clustered applications. For those familiar with Linux and Oracle we estimate approximately 1-2 days worth of work to setup your development RAC environment.
1: Ensure your configuration is certified. The setup we used was Red Hat 7.1 with RAC 9.0.1. If you’re interested in using another distribution of Linux or 9iR2 be sure to check the certified configurations.
2: Obtain proper FireWire chipset and adapters. We used an
external hard drive enclosure that contained an Oxford Semiconductor
OXFW911 sbp2
chipset, which supports up to four concurrent logins. The hardware
savings is quite noticeable here, as two FireWire adapters and a shared
disk
can be bought for less than a single fiber channel controller (let
alone the cost of a full SAN implementation). 3: Kernel configuration 4: Driver modification
This modification is well documented in the file and will allow both nodes to have access to the external FireWire hard drive simultaneously. You will want to read through the rest of the source code in this file as there are several tuning parameters which can be set here. 5: Compile the kernel
Next build the kernel according to your distributions instructions. Another error
we ran into was “Error invoking target
install of makefile /op/oracle/product/9.0.1/plsql/lib/ins_plsql.mk”.
6: Detect FireWire devices
7: Partitioning your drive For this reason we decided to drop the USERS and TOOLS tablespaces during the DBCA setup. This obviously doesn’t follow the optimal flexible architecture (OFA), but since this is a development system it will work just fine. You could also use multiple disks to allow you to set up additional partitions.
8: Oracle patch You can download
this from http://metalink.oracle.com and
simply follow the installation instructions. Once
you’ve created and started your database,
you’re ready to connect to the RAC from a client workstation.
9: Testing SESSION Failover SELECT Failover is implemented by transparently re-executing the SELECT statement and then bringing the cursor up to the same point as it was before the failure. There's no automatic recovery mechanism built into SELECT failover to handle DML statements, such as INSERTs and UPDATES which are in progress when a failover occurs. Your application will still need to use error checking routines and transactions, but now if a failure occurs you can try the transaction again on the same connection. If it was a node failure the connection has already reestablished itself to another node. The METHOD
parameter defines if Oracle pre-establishes connections to
connect to the backup node. Now comes the exciting part, testing your Real Application Cluster for failover. The following text describes the connect string in the clients TNSNAMES.ORA file for SELECT failover. (notice that TYPE=SELECT):
In our case we were connected to instance “clust2”. So if we were to run an SQL statement and take down this instance, then we should be failed over to instance “clust1” on the other node. The next step is to run an SQL SELECT statement. Make sure it will run long enough for you to shutdown the instances you’re currently connected to. You could import a table from your production system via the imp/exp utilities.While the SQL is processing, type the following on your server to shut down the instance where your SQL is processing:
where clust is the name of your cluster database and clust2 is the specific instance you want to take down. If everything is working properly you should see your SQL results pause for a moment and then pick back up. Once the SQL has completed verify that you are connected to the other instance by running:
Conclusion |
||
| Oraclenotes.com » |
| ©
Copyright 2002 Oraclenotes.com. All Rights Reserved. Not affliated or endorced by Oracle Corporation. |
|||