Home » RDBMS Server » Server Administration » Re: db link
Re: db link [message #49903] Sun, 17 February 2002 06:16 Go to next message
ricahrd
Messages: 4
Registered: February 2002
Junior Member
it still came out with error:
"ORA-12154: TNS:could not resolve service name"

i think i need to give you detail environment about my two servers, which are the same Sun SPARC solaris and same oracle9i on the local network. one of the two has the host name like myhost1.uk.com, however, another is supported by DHCP which is assigned the host name and IP address dynamically. It has a IP address and host name like UNKNOWN_16. i wonder if it is the reason that i could not connect with the other one.

i can give the global name for the first server (mydb1.myhost1.uk.com), but for the second, i was puzzled what the global name is. is it OK if mydb2.UNKNOWN_16). i'm afraid not. can i say mydb2.192.130.31.32? (suppose its IP is 192.130.31.32).

i used the following syntax to define the db link:
CREATE DATABASE LINK MYDB1.MYHOST1.UK.COM
CONNECT TO MYNAME IDENTIFIED BY MYPASSWD
USING '@MYDB1';

does oracle support DHCP for connectivity?

thank you for your patient

richard
Re: db link [message #49923 is a reply to message #49903] Mon, 18 February 2002 11:36 Go to previous message
Grant
Messages: 578
Registered: January 2002
Senior Member
try this:
CREATE DATABASE LINK MYDB1 CONNECT TO MYNAME IDENTIFIED BY MYPASSWD USING 'MYDB1.MYHOST1.UK.COM';

You should always use the server name not IP. IPs can change but server names usually do not. Make sure you have a DNS entry or use your hosts file.
Previous Topic: similar schema in the same database
Next Topic: Re: Free OCP Papers
Goto Forum:
  


Current Time: Tue Dec 24 11:55:29 CST 2024