« September 2007 | Main | November 2007 »

October 2007 Archives

October 2, 2007

Data Guard, Broker, Observer and Switchover, Step by Step

This post is the continuation of  the previous Data Guard, Physical Standby Implementation, Step by Step

This time I did focus on configuring Data Guard Broker, the Observer and implement Switchover from the Primary to the Standby and back. The step by step instructions are contained on this document: Configuration of 10g Data Guard Broker and Observer for Switchover

This configuration do require a third server to run from it the Observer process on the background. It proved to be more efficient than other hardware cluster solutions in terms of the time required to switchover, about 5 minutes.

The best solution is to upgrade  the configuration to RAC + Data Guard, that provides maximum protection and availability.

October 8, 2007

Oracle Flashback Technologies

Flashback Database, Table, Query, Transaction and Drop provides an extremely useful set of tools to the DBA.  Once understood they are easily configured, implemented and used, in case of need.

They are not only useful for recovery purposes but sometimes for informational purposes as well, a question like: which was the value for some record the last 6 hours? can be easily answered using flashback records.

Metalink Note 435998.1 : What Do All 10g Flashback Features Rely on and what are their Limitations ? contain additional conceptual information and links to some of the sources I did use to prepare the document I'm attaching here:






October 24, 2007

10g Dataguard, Flashback and New Features Q&A

Last week I had the privilege to share some time with a selected group of DBA's.

We did a review of some of the strong 10g features like ADDM, AWR, Dataguard, Flashback Technologies and ASM.

There were many interesting questions been raised up, I did take note of some of them, and compiled them into this document;  10g Questions and Answers


October 30, 2007

How to Generate a Script to Kill the Sessions Holding an Object

The main issue in this post is a simple script, you can use to find sessions holding an object, and thus disabling the possibility to compile it. The script generate kill -9 commands to clear their shadow processes at the OS level.

select 'kill -9 '||b.spid||' # username '||c.username||''

from v$access a, v$process b, v$session c

where a.object=upper('&name')

and a.sid=c.sid

and b.addr=c.paddr

/


If you want to have an example of using this script you can continue reading :-)

This morning we find that a package holding a new version was invalid, because a dependent object was not changed accordingly, as projected to be.

The dependent package, that remain unchanged, was being executed by about ~200 from ~5000 concurrent users.

The options were:
  • rollback the package that failed compilation or
  • introduce the new version of the dependent, and after that recompile  the invalid object.
We decided to introduce the changes to the dependent.

In one screen I did run this script to generate kill -9 commands for all shadow sessions holding the dependent,

set echo off  head off  veri off  feed off  pages 50000
/
spool killsess.sh
/
select 'kill -9 '||b.spid||' # username '||c.username||''

from v$access a, v$process b, v$session c

where a.object=upper('&name')

and a.sid=c.sid

and b.addr=c.paddr

/
spool off

On other screen I did start an sqlplus session to compile the new version, wrote down the compile command and left the screen open, ready to hit the enter key.

Once the generate of kill -9 commands finished I did set execution privileges for the script and executed it, from within sqlplus

!chmod 700 killsess.sh

!./killsess.sh

After that, immediately I did compile the dependent, and the invalid object from the second screen:

@compile_version;
alter package <pkgname> compile body;



      





CRS and ASM Fail to Start After Linux Kernel Upgrade

The case I'm describing apply to a specific configuration:

RAC 10g R2 on Linux x86_64 with EMC storage using EMC Powerpath and ASM.

It may be not relevant in other configurations, still it provides guidelines to diagnose and solve similar issues. In brief the problem was the following:

CRS failed to start after the Linux Kernel was upgraded from version  2.6.9-22.ELsmp to 2.6.9-55.0.2.ELsmp; ASM also failed to start

The solution steps were:
  • Reinstall EMC Powerpath
  • Reconfigure /etc/sysconfig/rawdevices
  • Install ASMLib rpm's matching the new kernel
This document provide a full description of the case and the solution implementation:



About October 2007

This page contains all entries posted to Alejandro Vargas' Blog in October 2007. They are listed from oldest to newest.

September 2007 is the previous archive.

November 2007 is the next archive.

Many more can be found on the main index page or by looking through the archives.

Powered by
Movable Type and Oracle