-
Originally posted by prasen999
i think that will involve a recreation of the control file of PDSOURCE.
No, you are not going to recreate the control file.
Hold on for a while I will give you the work-around.
-
Originally posted by prasen999
yes , that is true that in sqlnet.ora the default domain in the 2 servers are different - so does changing the sqlnet.ora default domain to be the same in both the dbs solve the issue?
thanks and regards
considering you're not going to touch global_names.
I will give you a work around just to simplify my view and to work things out.
omit the value of default_domain in SQLNET.ORA in both servers, or might as well rename SQLNET.ORA to SQLNET.BAK
edit the tnsnames of both servers(please post which server did you create your dblink).
1st server: tnsnames.ora(also include tnsnames of 2nd server)
PDSOURCE =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = TCS031301)(PORT = 1521))
)
(CONNECT_DATA =
(SID= PDSOURCE)
(SERVER = DEDICATED)
)
)
2nd server: tnsnames.ora tnsnames.ora(also include tnsnames of 1nd server)
UII =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 172.18.34.133)(PORT = 1521))
)
(CONNECT_DATA =
(SID = UII)
(SERVER = DEDICATED)
)
)
Then recreate your db link like(assuming you are creating db link from 2nd server):
create database link YOURDBLINK_UII
connect to strmadmin
identified by strmadminpd
using PDSOURCE
-
removing the sqlnet.ora default_domain value, i am not being able to login
C:\>sqlplus strmadmin/strmadminpd@pdsource
SQL*Plus: Release 9.2.0.1.0 - Production on Wed Sep 22 13:38:04 2004
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
ERROR:
ORA-12154: TNS:could not resolve service name
moreover, the box having the uii db has other dbs also which are in use by the team - so it wont be prudent to tamper with that.
thanks and regards.
-
that's because you didn't change the tnsnames entry from
PDSOURCE.TCSKOLKATA.CO.IN to PDSOURCE.
"moreover, the box having the uii db has other dbs also which are in use by the team - so it wont be prudent to tamper with that."
your client connection to your server is different with your server/server connection. As long as the listener is up and the tnsnames, sqlnet in client is well configured, then it should just be fine.
Anyway, if you decide not to touch your tnsnames, sqlnet in your server try creating the db link like this(assuming you are creating your db in UI.WORLD):
create database link YOURDBLINK_UII
connect to strmadmin
identified by strmadminpd
using PDSOURCE.TCSKOLKATA.CO.IN
-
Instead of strugling further follow the steps.
1.Alter database rename global_names to xxx
on both the servers.
2.create database link abcd.xxx connect to user_name identified by password using
'(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = your host )(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = database_sid)
)
)';
-
guys, sorry to say .. but now i am thoroughly confused - i have done something for which the link seems to work .. i am pasting what i had done -
i checked the sqlnet.ora of the other server and saw that default_domnin = tcskolkata.co.in
so i let the default_domain in my box to be tcskolkata.co.in
then as per reydp's suggestion .. i changed the tnsnames connect-desc riptor to pdsource.world
then according to akhadar i changed the global_name of both the databases to pdsource (but here the domain that got appended was different)
then i recreated the database link - which seemed to work fine.
this i executed from strmadmin@pdsource.world
SQL> select * from uii.ar_classes@pdsource_uii;
DEP COURSE
--- ----------
DESCRIPTION
------------------------------------------------------------------------------
MAX_STUDENTS CURRENT_STUDENTS NUM_CREDITS ROOM_ID CREDITS_ALLOWED
------------ ---------------- ----------- ---------- ---------------
PHY 1
OPTICS
100 75 9 100 9
BUT INTERESTINGLY IN THE OEM THE DATABASE LINK STILL TELLS ME NOT ACTIVE.
hey guys, can u give me a good info regarding these things -
when i am creating a link between 2 databases how does global_name, global_names, domain come into the picture and play a part
thanks and regards
-
Originally posted by akhadar
Instead of strugling further follow the steps.
1.Alter database rename global_names to xxx
on both the servers.
2.create database link abcd.xxx connect to user_name identified by password using
'(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = your host )(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = database_sid)
)
)';
It was really my bad akhadar,
Though I mention earlier that without touching global_names, the preceeding post that i have made is for prasen999 to understand what is the usual oracle behaviour for db link creation when global_names is not used.
prasen999,
You are close, it will also help you if you just read documents for proper and easier understanding.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|