Solved

DBLink issue, ORA-12154: TNS:could not resolve service name

Posted on 2010-09-07
8
1,324 Views
Last Modified: 2013-11-16
Hi Experts,

I'm able to connect through SQLPLUS, using tkeep/tiger@pepsi

Now created DB Link, in other DB, with the below command:

CREATE DATABASE LINK TKEEPDBLINK
   CONNECT TO TKEEP IDENTIFIED BY TIGER
   USING 'PEPSI';

When trying to do a
SELECT * from aug@TKEEPDBLINK  
gives the below error
ORA-12154: TNS:could not resolve service name

Please do the needful.

Thanks.
0
Comment
Question by:amutallibkhan
[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
  • 3
  • 2
  • 2
  • +1
8 Comments
 
LVL 13

Expert Comment

by:riazpk
ID: 33616139
Do you have more than one oracle homes?
0
 

Author Comment

by:amutallibkhan
ID: 33616160
Ya, we have.
0
 
LVL 1

Accepted Solution

by:
esmail1349 earned 500 total points
ID: 33616269
test TNSPING PEPSI in windows command prompt on machine that DBlink arised.
it should return OK.
else check pepsi host string for any problem.
0
Is Your DevOps Pipeline Leaking?

Is your CI/CD pipeline a hodge-podge of randomly connected tools? You’ve likely got a tool to fix one problem & then a different tool to fix another, resulting in a cluster of tools with overlapping functionality. Learn how to optimize your pipeline with Gartner's recommendations

 

Author Comment

by:amutallibkhan
ID: 33616342
C:\Documents and Settings\Abdulmutallib>tnsping pepsi

TNS Ping Utility for 32-bit Windows: Version 9.2.0.1.0 - Production on 07-SEP-20
10 13:18:15

Copyright (c) 1997 Oracle Corporation.  All rights reserved.

Used parameter files:
D:\oracle\ora92\network\admin\sqlnet.ora


Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (COMMUNITY = tcp
.world) (PROTOCOL = TCP) (Host = 10.10.40.5) (Port = 1521)) (ADDRESS = (COMMUNIT
Y = tcp.world) (PROTOCOL = TCP) (Host = 10.10.40.5) (Port = 1526))) (CONNECT_DAT
A = (SID = ORCL)))
OK (0 msec)
0
 
LVL 1

Expert Comment

by:esmail1349
ID: 33616616
pepsi host string should be in D:\oracle\ora92\network\admin\tnsnames.ora
and then
check/add  ORACLE_HOME environment variable to value "D:\oracle\ora92"
0
 
LVL 4

Expert Comment

by:boriskalavsky
ID: 33621755
check firewall
0
 
LVL 4

Expert Comment

by:boriskalavsky
ID: 33621827
are you listening on both ports on 10.10.40.5 (1521 and 1526)? Can you ost a listener.ora file from  10.10.40.5?
0
 

Author Closing Comment

by:amutallibkhan
ID: 33624303
Helped in getting resolved.
0

Featured Post

MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.

Question has a verified solution.

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

Note: You must have administrative privileges in order to create/edit Sharing Rules. Salesforce.com (http://www.salesforce.com) (SFDC) is a cloud-based customer relationship management (CRM) system. It is a database most commonly used by sales an…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.

752 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