Solved

Oracle Replication: Invalid username/password on RESUME_MASTER_ACTIVITY

Posted on 2006-11-17
6
1,626 Views
Last Modified: 2007-12-19
Hi everyone,
I'm trying to set up multi-master replication on Oracle 10.2.0.1.0 by using steps listed on http://www.akadia.com/services/ora_replication_guide.html . Database names are QS10DB0 and QS10DB1 and they are on different servers in same LAN. Replication group is called REPG which I created on QS10DB0 and added another master database which is QS10DB1. Looking into DBA_REPSITES everything looks ok by me.

SQL> select gname,DBLINK from dba_repsites;

GNAME
------------------------------
DBLINK
----------------------------------------------------

REPG
QS10DB0

REPG
QS10DB1

I've came to the point where DBA_REPCATLOG has cleared and I try to execute RESUME_MASTER_ACTIVITY on QS10DB0.

When I do this I get:

SQL> BEGIN
  2     DBMS_REPCAT.RESUME_MASTER_ACTIVITY (
  3       gname => 'REPG');
  4  END;
  5  /
BEGIN
*
ERROR at line 1:
ORA-04052: error occurred when looking up remote object SYS.SYS@QS10DB1
ORA-00604: error occurred at recursive SQL level 2
ORA-01017: invalid username/password; logon denied
ORA-02063: preceding line from QS10DB1
ORA-06512: at "SYS.DBMS_REPCAT_UTL4", line 119
ORA-06512: at "SYS.DBMS_REPCAT_UTL4", line 554
ORA-06512: at "SYS.DBMS_REPCAT_MAS", line 3533
ORA-06512: at "SYS.DBMS_REPCAT", line 826
ORA-06512: at line 2

I guess QS10DB0 can't connect to QS10DB1 because of  user account problems but I don't know how to fix it. Both databases were created as clones from a cold copy so they should be same.

Any help would be appreciated.
0
Comment
Question by:milan_novkovic
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
6 Comments
 
LVL 48

Assisted Solution

by:schwertner
schwertner earned 200 total points
ID: 17964904
Edit the tnsnames.ora in the <QS10DB0_db_home>/network/admin directory, or if $TNS_ADMIN is set, edit the tnsnames.ora in that directory and add an alias for the master OID database e.g.

ASDB.UK.ORACLE.COM =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = oidmasterserver.uk.oracle.com)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = asdb.uk.oracle.com)
)
)
0
 
LVL 16

Accepted Solution

by:
MohanKNair earned 300 total points
ID: 17964948
Check the database link. Create the dblink as SYS user and grant privileges to repadmin user or create public dblinks.
Try sample queries using sql*plus and dblink.
0
 

Author Comment

by:milan_novkovic
ID: 17964952
I think tnsnames.ora is ok since I can connect to one database from other server and vice versa using sqlplus and TOAD.

It looks like this (I changed server names):


QS10DB1 =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = server1)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SERVICE_NAME = QS10DB1)
    )
  )

QS10DB0 =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = server0)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = QS10DB0)
    )
  )
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:milan_novkovic
ID: 17964981
@MohanKNair

I've created database links using steps from tutorial I listed in my initial post. I did the following:

connect sys/pass@QS10DB0;
CREATE PUBLIC DATABASE LINK QS10DB1 USING '(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(COMMUNITY=TCP)(PROTOCOL=TCP)(Host=server1)(Port=1521)))(CONNECT_DATA=(SID=QS10DB1)))';
CONNECT repadmin/repadmin@QS10DB0;
CREATE DATABASE LINK QS10DB1 CONNECT TO repadmin IDENTIFIED BY repadmin USING 'QS10DB1';

CONNECT sys/pass@QS10DB1 as sysdba;
CREATE PUBLIC DATABASE LINK QS10DB0 USING '(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(COMMUNITY=TCP)(PROTOCOL=TCP)(Host=server1)(Port=1521)))(CONNECT_DATA=(SID=QS10DB0)))';
CONNECT repadmin/repadmin@QS10DB1;
CREATE DATABASE LINK QS10DB0 CONNECT TO repadmin IDENTIFIED BY repadmin USING 'QS10DB0';
0
 

Author Comment

by:milan_novkovic
ID: 17965113
I tries creating public database links, it seems I haven't created it correctly previosly. So now I'm getting follow error when trying to execute RESUME_MASTER_ACTIVITY:

SQL> BEGIN
  2     DBMS_REPCAT.RESUME_MASTER_ACTIVITY (
  3       gname => 'REPG');
  4  END;
  5  /
BEGIN
*
ERROR at line 1:
ORA-23358: invalid remote user
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 79
ORA-06512: at "SYS.DBMS_REPCAT_RPC", line 12
ORA-06512: at "SYS.DBMS_REPCAT_RPC", line 1783
ORA-06512: at "SYS.DBMS_REPCAT_UTL4", line 119
ORA-06512: at "SYS.DBMS_REPCAT_UTL4", line 554
ORA-06512: at "SYS.DBMS_REPCAT_MAS", line 3533
ORA-06512: at "SYS.DBMS_REPCAT", line 826
ORA-06512: at line 2

0
 

Author Comment

by:milan_novkovic
ID: 17965259
Ok, it working now! I've recreated dblinks, recreated replication support and RESUME_MASTER_ACTIVITY executed without errors. Data is being replicated between two databases now.

I'll split points between schwertner and MohanKNair but give MohanKNair more because he's answer helped me more to solve my problem.

Thanks
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction A previously published article on Experts Exchange ("Joins in Oracle", http://www.experts-exchange.com/Database/Oracle/A_8249-Joins-in-Oracle.html) makes a statement about "Oracle proprietary" joins and mixes the join syntax with gen…
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question