Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Problem in creating DB Link

RE: Problem in creating DB Link

From: kkennedy <kkennedy_at_firstpoint.com>
Date: Mon, 26 Aug 2002 13:41:49 -0800
Message-ID: <F001.004BFC83.20020826134149@fatcity.com>


Abdul,

You are hitting one of the more common problems with db links and domain names. The "us.oracle.com" at the end of the name is the symptom.

To use the link, append the domain (i.e., select * from junk_at_my_link.us.oracle.com).

To drop the link, try "drop public database link my_link.us.oracle.com". That should get rid of it.

To see where your problem is coming from:

sqlplus internal
show parameter domain
select * from global_name;

The output from these two commands should show you that your domain has been set to "us.oracle.com". This domain is only truly proper for Oracle internal databases. I suspect it gets used accidentally quite often.

I've been able to fix this problem in the past but can't remember exactly what I had to do. Seems like I changed the db_domain parameter in the init.ora file and also had to change the database name using an alter database command (or something like that) then I had to drop and recreate all my db links -- long time ago and far away when Enron was still walking the earth.....

Kevin Kennedy
First Point Energy Corporation

If you take RAC out of Oracle you get OLE! What can this mean?

-----Original Message-----
Sent: Monday, August 26, 2002 6:33 AM
To: Multiple recipients of list ORACLE-L

Thank you Edward,

As suggested, I have tried the following command (since PUBLIC is required) CREATE PUBLIC DATABASE LINK my_link

   CONNECT TO UserA1 IDENTIFIED BY passwordA    USING 'abc'

The Server B from where I am issuing this command, connects to the Server A using the same connect string 'abc'. After this connection I am able to view tables, data etc. But the command describe table1_at_my_link seems to be liking the error
ora-02019: connection description for remote database not found.

The view all_db_links lists this link but appends us.oracle.com to my_link under db_link column. Any more suggestions

For dropping the link, I was missing "PUBLIC" keyword

Aleem

 -----Original Message-----

Sent:	Monday, August 26, 2002 4:03 PM
To:	Multiple recipients of list ORACLE-L
Subject:	RE: Problem in creating DB Link

Hi Aleem,

Just try to create a simple link without PUBLIC and SHARED keywords if you don't really need them.
Login as user B and issue the following command:

CREATE DATABASE LINK mydblink
CONNECT TO userA IDENTIFIED BY password_of_userA USING 'abc';

If you get ORA-02019 then check if the correct service name (abc in that case) exists in your tnsnames.ora on server B. You can use TNSPING abc to ensure that your service name points remote db properly.

Regards,
Ed

>
> Hi,
>
> I have created a Database Link under the scenario detailed
> below: but when I try to access tables through the link it gives error
> ORA-02019: connection description for remote database not found.
>
> If I try to drop the link it gives error
> ORA-02024: database link not found
>
> TIA!
>
> Aleem
>
>
> This is the scenario:
> We have two db servers running on our LAN, for simplicity
> 'A', connect string 'abc' and 'B', connect string 'xyz'.
>
> Some of the tables on A in schema UserA1 are required (read
> only) by schema UserB1 on server B. As suggested by someone I
> tried to create a dblink. Using SQL*Plus connected as
> 'System' to Server B (since it requires to access tables from
> the other db) and applied the following command.
>
> CREATE SHARED PUBLIC DATABASE Link my_link
> CONNECT TO UserA1 IDENTIFIED BY abc
> AUTHENTICATED BY UserB1 IDENTIFIED BY def
> USING 'abc'
>
> --
> Please see the official ORACLE-L FAQ: http://www.orafaq.com
> --
> Author: Abdul Aleem
> INET: dmit_at_beaconhouse.edu.pk
>
> Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
> San Diego, California -- Public Internet access / Mailing Lists
> --------------------------------------------------------------------
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru')
> and in the message BODY, include a line containing: UNSUB
> ORACLE-L (or the name of mailing list you want to be removed
> from). You may also send the HELP command for other
> information (like subscribing).
>

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Edward Shevtsov
  INET: eshevtsov_at_detmir.ru

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Abdul Aleem
  INET: dmit_at_beaconhouse.edu.pk

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: kkennedy
  INET: kkennedy_at_firstpoint.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Mon Aug 26 2002 - 16:41:49 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US