异常:
Listener refused the connection with the following error: ORA-12519, TNS:no appropriate service handler found The Connection descriptor used by the client was: localhost:1521:orcl
Hibernate operation: Cannot open connection; uncategorized SQLException for SQL [???]; SQL state [null]; error code [0]; Listener refused the connection with the following error: ORA-12519, TNS:no appropriate service handler found The Connection descriptor used by the client was: localhost:1521:orcl ; nested exception is java.sql.SQLException: Listener refused the connection with the following error: ORA-12519, TNS:no appropriate service handler found The Connection descriptor used by the client was: localhost:1521:orcl
引用
查询数据库当前进程的连接数:
select count(*) from v$process;
查看数据库当前会话的连接数:
elect count(*) from v$session;
查看数据库的并发连接数:
select count(*) from v$session where status='ACTIVE';
查看当前数据库建立的会话情况:
select sid,serial#,username,program,machine,status from v$session;
查询数据库允许的最大连接数:
select value from v$parameter where name = 'processes';
或者:show parameter processes;
修改数据库允许的最大连接数:
alter system set processes = 300 scope = spfile;
(需要重启数据库才能实现连接数的修改)
重启数据库:
shutdown immediate;
startup;
查看当前有哪些用户正在使用数据:
select osuser,a.username,cpu_time/executions/1000000's' ,sql_fulltext,machine
from v$session a,v$sqlarea b
where a.sql_address = b.address
order by cpu_time/executions desc;
备注:UNIX 1个用户session对应一个操作系统process,而Windows体现在线程。
启动oracle
su - oracle
sqlplus system/pwd as sysdba //进入sql
startup //启动数据库
lsnrctl start //启动监听
sqlplus "/as sysdba"
shutdown immediate;
startup mount;
alter database open;
--
web应用连接oracle数据库时,经常在查询数据时发生
Listener refused the connection with the following error: ORA-12519, TNS:no appropriate service handler found The Connection descriptor used by the client was: 127.0.0.1:1521:ORCL
这种错误,网上查了很多,都说是ip地址改变之后的问题,要把tnsnames.ora中的实例配置中改为计算机名,我试过之后问题还是不能解决,今天终于找到问题所在了,是数据库连接数量的问题,12519错误为监听不能提供服务,通常为数据库进程达到上限导致。
可以先执行下 select count(*) from v$process ,看下现在系统有多少连接数,然后再查询 select value from v$parameter where name = 'processes' ,看下oracle设置中设置了多少连接数,一般一个应用都会使用20个,所以如果你开了几个应用的话(web、pl/sql、……)就会出这个问题了,这时只需要执行下
alter system set processes = 300 scope = spfile;
就可以了,当然300可以根据实际情况设置。
分享到:
相关推荐
ORA-12541 TNSno listener 的解决方案 ORA-12541 TNSno listener 的解决方案
用oracle数据库新建连接时遇到ora-12505,此问题解决后又出现ora-12519错误,郁闷的半天,经过一番折腾问题解决,下面小编把我的两种解决方案分享给大家,仅供参考。 解决方案一: 今天工作时在新建连接的时候遇到...
主要介绍了连接Oracle数据库时报ORA-12541:TNS:无监听程序的图文解决教程,非常不错,具有参考借鉴价值,需要的朋友可以参考下
However, it is possible to disable the flat file listener logging using the following commands: LSNRCTL>set current_listener <listener_name> LSNRCTL>set log_status OFF LSNRCTL>save_config 我就按照...
oracle网络配置(listener_ora-sqlnet_ora-tnsnames_ora).mht
刚开始时,有一台服务器的ORACLE 11G数据库连接不上,报错:ORA-12541:TNS:无监听程序 重启服务里面的两个Oracle服务,都没解决。 在网上看到一篇文章说另一种可能是oracle目录目录下listener.log日志文件过大(达到...
客户端进行连接的时候,系统不定期出现ora-12520,ora-12516的连接问题, 问题解决方案建议: 1、增加process和session的连接数。 2、检查连接的应用,是不是有没有释放的连接。 3、将修改参数local_listener中的vip为...
listener-tnsnamelistener-tnsnamelistener-tnsnamelistener-tnsnamelistener-tnsnamelistener-tnsnamelistener-tnsnamelistener-tnsname
Oracle报错ORA-12516 TNS:listener could not find available handler with matching protocol stack
oracle-12c驱动包,完美解决oracle版本落后无法连接数据库的问题!主要有以下报错::java.sql.SQLException: ORA-28040: No matching...java.sql.SQLException: Listener refused the connection with the following...
etworkadminlistener.ora 和 tnsnames.ora 也都对,这个问题浪费了我好大把时间,终于在下面这位大神的介绍中给解决了,其方法是启动listener: 运行->cmd启动dos窗口,执行lsnrctl stop关闭,lsnrctl start启动...
listener_ora sqlnet_ora tnsnames_ora的关系以及手工配置举例
若本地pl/sql链接数据库成功,其他机器链接数据提示错误:ORA-12541:TNS:no listener,如下图所示
oracle11g安装后,本地无法登录! 前提:服务全部打开,监听也配置好了! win7 64位 oracle 11g ...ora-00132【syntax error or unresolved network name ‘LISTENER_ORCL’】: 现在看来,完全可以理解就是001
1,ORA-12505: TNS:listener does not currently know of SID given in connect descriptor (DBD ERROR: OCIServerAttach) 2,ORA-28547: connection to server failed, probable Oracle Net admin error (DBD ERROR...
官方离线安装包,亲测可用
tetra-listener-vagrant:TETRA-Listener流浪者模板
2015-09-12 06:59:40.263: [ CRSAPP][11046]32CheckResource error for ora.p550b.LISTENER_P550B.lsnr error code = -2 2015-09-12 07:01:00.691: [ CRSEVT][12074]32CAAMonitorHandler :: 0:Could not join /opt/...
课时11:4..Sampler、Listener 和Summary Report 课时12:5.GraghView Results 和Timer 定时器 课时13:6.Processor 处理器和Assertion断言 课时14:7.演示:掌握JMeter各元素的使用 课时15:JMeter-II.ppt 课时16:1.测试...