Link to home
Start Free TrialLog in
Avatar of sharscho
sharscho

asked on

oracle 10g data guard question

Hi experts I want to know if I can shutdown my standby db to start it with spfile without any problems. I have a dataguard environment running fine but I wanted to configure data guard broker during normal operation hours but I see now that the standby db is not started with spfile and so I can not configure the data guard broker on the standby db. I wanted to just do a shutdown immediate and a startup mount. I guess I have to issue the command: alter database recover managed standby database disconnect from session; to start the arch log to be applied..
Can someone advice me what is best to do in this situation?
Avatar of Praveen Kumar Chandrashekatr
Praveen Kumar Chandrashekatr
Flag of India image

You can shutdown your standy database and start it with spfile.
and as u said run

alter database recover managed standby database disconnect from session;
check the archive log list for log sequence no of your standby and primary database.

                                                       
alter database recover managed standy datababse cancel;
ASKER CERTIFIED SOLUTION
Avatar of POracle
POracle
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of sharscho
sharscho

ASKER

Thanks POracle, this looks more like it. I will do the steps and let you know.
I did not configure the standby db yet because I ahve noticed that the entries in my primary and standby init.ora does not contain the service _names parameter, is this parameter essential for the good functioning of the data guard broker?
No service_name is not essential for data_guard_broker, instead you need db_unique_name parameter. But I suggest to refer this documentation for oracle data guard broker.

http://download.oracle.com/docs/cd/B19306_01/server.102/b14230/concepts.htm#i1012797
OK I see. I did configure the standby db now and it went good, thank you very much but I am now at the point of the listener and the tnsnames.ora and I see that in the tnsnames the service_name is defined, Is that not necessary to place this service_name in the spfile? I could not find anything about that in the link that you have send me, I only info for the listener.ora...
But My listener.ora looks like this and only the global_name,  the sid_name and the host differs on both servers and so I corrected it to becone the same listener file for both the prim and standby db like it is said in the doc you have send me. Is this OK?
Here is a copy of the listener file:
$ vi listener.ora
"listener.ora" 14 lines, 286 characters
SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (GLOBAL_DBNAME = computron.alm.local)
      (ORACLE_HOME = /opt/oracle/product/10.2.0/db_1)
      (SID_NAME = computron)
    )
    (SID_DESC = (GLOBAL_DBNAME = computrons.alm.local)
     (ORACLE_HOME = /opt/oracle/product/10.2.0/db_1)
     (SID_NAME = computrons)
   )
  )

LISTENER =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = hercules.alm.local)(PORT = 1521))
  )
I see that in the tnsnames the service_name is defined, Is that not necessary to place this service_name in the spfile?>>

You can use sid name in tnsnames.ora file like ,

PriDb =  
(DESCRIPTION =  
 (ADDRESS_LIST =  
     (ADDRESS = (PROTOCOL = TCP) (HOST = PrimaryHost) (PORT = 1521))
   )  
 (CONNECT_DATA =      (SID = computrons)  
  )
 )
Remember, dataguard and data guard broker are two different things.

Data guard broker is management architecture, which can ease your data guard environment monitoring task.



POracle, |I thank you for your advice but I am still struggling with the listener file that has to reside on both the prime as the standby server. In all the examples that I have gone through they show that the host entry has to remain the same for both servers. So  (ADDRESS = (PROTOCOL = TCP)(HOST = hercules.alm.local)(PORT = 1521))
this line has to exist exactly the same on both server. Or better, bother listener files has to be identical on both server. right now the host entry has a value of the name of each server resp. why is it that for data guard broker to function correctly the host entry for the listener files on both servers has to point to only the primary server????
. In all the examples that I have gone through they show that the host entry has to remain the same for both servers.>>

Please, post link for the docs you visit.
See. if both databases, means primary and standby database are on same server then it is possible to have same host name on both listener file. otherwise this is not true...
sharscho,

Here is very good blog for standby database configuration. it contains each steps in details. Though it is for oracle 9i but still very good to understand standby database.

http://curiosityatoracle.blogspot.com/
sharscho,

Let us know whether you solve this or still have some issue.
please refer  the below tnsnames.ora and try it.

Prod =  
(DESCRIPTION =  
 (ADDRESS_LIST =  
     (ADDRESS = (PROTOCOL = TCP) (HOST = ProdHost) (PORT = 1521))
   )  
 (CONNECT_DATA =      (SID = devo)  
 )
 )
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
This question took a long time because I had to go with pregnancy leave earlier due to complications. I could not try this databroker setup due to some issues with the application. It is so that the application uses one tns.ora and when a failover has to take place what we do is start the standby db with the sidname of the prod db and start the listener to point to the prod db name and so no changes need to be made for the application that is why the failover is occurring manually. So I can not state that the problem is solved but I am going to close the question since I am still on leave and whe I start back I am going to test the the setup and place comments about it. I thank you for your advices, I appreciate it.
Thank you all!!