Newbie questions abt data guard [message #474499] |
Mon, 06 September 2010 14:59 |
ultgnp
Messages: 106 Registered: May 2010 Location: Germany
|
Senior Member |
|
|
Hi,
I have a Database of Size approx 150GB. I want to create a standby server(High Availability). I have few questions,which some experts here can help me with.
Scenario
1)If our Primary Database crash, the standy server should instantly start automatically i.e no down time.
2)There should be no data loss.
3)Are Data Guard and Replication similar?
Thanks,
[Updated on: Mon, 06 September 2010 15:05] Report message to a moderator
|
|
|
|
|
|
Re: Newbie questions abt data guard [message #474642 is a reply to message #474539] |
Tue, 07 September 2010 16:00 |
John Watson
Messages: 8964 Registered: January 2010 Location: Global Village
|
Senior Member |
|
|
In reply to your question 1, you can get very fast automatic failover with Data Guard. The default delay for the fast start failure initiated by the Data Guard Broker Observer is 30 seconds. Of course there is a bit more time needed to activate the standby.
The delay is more likely to be making sure that your clients connect to the new primary immediately the original primary fails. You need a startup trigger that detects the mode in which the database is operating, and starts the appropriate service for registration with the listeners. Something like this:
CREATE TRIGGER ROLE_REGISTRATION AFTER STARTUP ON DATABASE
DECLARE
ROLE VARCHAR(30);
OPENMODE VARCHAR(30);
BEGIN
SELECT DATABASE_ROLE INTO ROLE FROM V$DATABASE;
SELECT OPEN_MODE INTO OPENMODE FROM V$DATABASE;
IF ROLE = 'PRIMARY' THEN
DBMS_SERVICE.START_SERVICE ('PROD');
ELSIF ROLE = 'PHYSICAL STANDBY' THEN
DBMS_SERVICE.START_SERVICE ('STANDBY');
END IF;
END;
/
Then, if you have appropriate settings in your tnsnames files, your clients should reconnect their broken sessions automatically to the new primary.
|
|
|