请教一个关于监听的问题,迷惑了……
1、本机数据库连接:
C:Documents and SettingsThinking>sqlplus system/manager
SQL*Plus: Release 9.2.0.7.0 - Production on 星期五 7月 4 11:22:26 2008
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
连接到:
Oracle9i Enterprise Edition Release 9.2.0.7.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.7.0 - Production
system@ora92(Thinking) select sysdate from dual;
SYSDATE
----------
04-7月 -08
system@ora92(Thinking) exit
从Oracle9i Enterprise Edition Release 9.2.0.7.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.7.0 - Production中断开
:连接没有问题。
2、查看监听状态:
C:Documents and SettingsThinking>lsnrctl status
LSNRCTL for 32-bit Windows: Version 9.2.0.7.0 - Production on 04-7月 -2008 11:24:01
Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC0)))
LISTENER 的 STATUS
------------------------
别名 LISTENER
版本 TNSLSNR for 32-bit Windows: Version 9.2.0.7.0 - Produc
tion
启动日期 04-7月 -2008 11:19:28
正常运行时间 0 天 0 小时 4 分 33 秒
跟踪级别 off
安全性 OFF
SNMP OFF
监听器参数文件 D:oracleora92
etworkadminlistener.ora
监听器日志文件 D:oracleora92
etworkloglistener.log
监听端点概要...
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=.pipeEXTPROC0ipc)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=Thinking)(PORT=1521))
)
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=Thinking)(PORT=8080))
(Presentation=HTTP)(Session=RAW))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=Thinking)(PORT=2100))
(Presentation=FTP)(Session=RAW))
服务摘要..
服务 "PLSExtProc" 包含 1 个例程。
例程 "PLSExtProc", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
服务 "ora92" 包含 2 个例程。
例程 "ora92", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
例程 "ora92", 状态 READY, 包含此服务的 2 个处理程序...
命令执行成功
C:Documents and SettingsThinking>
:监听也没有问题。
3、使用连接字符串连接数据库:
C:Documents and SettingsThinking>sqlplus system/manager@ora92
SQL*Plus: Release 9.2.0.7.0 - Production on 星期五 7月 4 11:25:35 2008
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
:连接被挂起,不再有反应。通过客户机连接报错如下。
SQL> conn system/manager@host
ERROR:
ORA-12518: TNS: 监听程序无法分发客户机连接
SQL>
4、停止监听:
C:Documents and SettingsThinking>lsnrctl stop
LSNRCTL for 32-bit Windows: Version 9.2.0.7.0 - Production on 04-7月 -2008 11:28:26
Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC0)))
命令执行成功
C:Documents and SettingsThinking>lsnrctl status
LSNRCTL for 32-bit Windows: Version 9.2.0.7.0 - Production on 04-7月 -2008 11:29:12
Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC0)))
TNS-12541: TNS:无监听器
TNS-12560: TNS: 协议适配器错误
TNS-00511: 无监听器
32-bit Windows Error: 2: No such file or directory
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=Thinking)(PORT=1521)))
TNS-01153: 未能处理字符串:
NL-00313: 空的指针或空的大小
5、通过连接字符串再次连接:
C:Documents and SettingsThinking>sqlplus system/manager@ora92
SQL*Plus: Release 9.2.0.7.0 - Production on 星期五 7月 4 11:31:26 2008
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
[code][/code]连接到:
Oracle9i Enterprise Edition Release 9.2.0.7.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.7.0 - Production
system@ora92(Thinking)
客户端连接:[code]SQL> conn system/manager@host
已连接。
SQL>
监听启动时客户端无法连接,停掉后客户端反而可以连接上了,不知道什么问题,谁能解释一下?
注意到监听停止成功,但在查询监听状态时有报错:
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=Thinking)(PORT=1521)))
TNS-01153: 未能处理字符串:
NL-00313: 空的指针或空的大小
|