码迷,mamicode.com
首页 > 其他好文 > 详细

ORA-12521: TNS: 监听程序当前无法识别连接描述符中请求的实例(原)

时间:2014-05-17 15:03:24      阅读:443      评论:0      收藏:0      [点我收藏+]

标签:des   c   ext   a   cti   name   

今天登录PL/SQL出现问题:

---------------------------
sys@RAC1 as SYSDBA
---------------------------
ORA-12521: TNS: 监听程序当前无法识别连接描述符中请求的实例

---------------------------

但是TNSPING RAC1可以通的。

RAC1 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST =192.168.1.203)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = racdb)
(INSTANCE_NAME = racdb1)
)
)

查看rac1监听配置:

LISTENER_RAC1 =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = rac1-vip)(PORT = 1521)(IP = FIRST))
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.223)(PORT = 1521)(IP = FIRST))
)
)

 

SID_LIST_LISTENER_RAC1 =
(SID_LIST =
(SID_DESC =
(SID_NAME = PLSExtProc)
(ORACLE_HOME = /opt/ora10g/product/10.2.0/db_1)
(PROGRAM = extproc)
)
)

没什么错误,

 

后来发现在配置etc/hosts的时候有点问题:

127.0.0.1 rac1 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6
192.168.1.223 rac1
192.168.1.224 rac2
192.168.1.203 rac1-vip
192.168.1.204 rac2-vip
10.0.0.223 rac1-priv
10.0.0.224 rac2-priv
[root@rac1 etc]# ping rac1
PING rac1 (127.0.0.1) 56(84) bytes of data.
64 bytes from rac1 (127.0.0.1): icmp_seq=1 ttl=64 time=0.438 ms
64 bytes from rac1 (127.0.0.1): icmp_seq=2 ttl=64 time=0.103 ms

--- rac1 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1002ms
rtt min/avg/max/mdev = 0.103/0.270/0.438/0.168 ms

修改为:

# that require network functionality will fail.
127.0.0.1 localhost
192.168.1.223 rac1
192.168.1.224 rac2
192.168.1.203 rac1-vip
192.168.1.204 rac2-vip
10.0.0.223 rac1-priv
10.0.0.224 rac2-priv

[root@rac1 etc]# ping rac1
PING rac1 (192.168.1.223) 56(84) bytes of data.
64 bytes from rac1 (192.168.1.223): icmp_seq=1 ttl=64 time=0.040 ms
64 bytes from rac1 (192.168.1.223): icmp_seq=2 ttl=64 time=0.063 ms

然后在把监听重启一下,等待片刻之后。

PL/SQL可以登录了

 

ORA-12521: TNS: 监听程序当前无法识别连接描述符中请求的实例(原),布布扣,bubuko.com

ORA-12521: TNS: 监听程序当前无法识别连接描述符中请求的实例(原)

标签:des   c   ext   a   cti   name   

原文地址:http://www.cnblogs.com/future2012lg/p/3730846.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有
迷上了代码!