ORA-12519 ORA-12516

目录:

  •   错误信息
  •   原因分析
  •   解决方法

  

1. 错误信息

  

[oracle@test1 admin]$ oerr ora 12519
12519, 00000, "TNS:no appropriate service handler found"
// *Cause: The listener could not find any available service handlers that
// are appropriate for the client connection.
// *Action: Run "lsnrctl services" to ensure that the instance(s) have
// registered with the listener, and are accepting connections.
[oracle@test1 admin]$ oerr ora 12516
12516, 00000, "TNS:listener could not find available handler with matching protocol stack"
// *Cause: None of the known and available service handlers for the given 
// SERVICE_NAME support the client's protocol stack: transport, session, 
// and presentation protocols.
// *Action: Check to make sure that the service handlers (e.g. dispatchers) 
// for the given SERVICE_NAME are registered with the listener, are accepting 
// connections, and that they are properly configured to support the desired 
// protocols.

2. 原因分析

  这两个错误 ,都是在说,无法获取handler 。区别在于 12519 错误没有明确说明因为什么,而12516明确说明 是因为 protocal stack(网络协议)。

  其实最关键的都是一点:无法获取 handler. 而这个错误要分两个情况:一种是监听本身无法启动子进程进行分配连接,另一种情况是服务器不允许建立新的连接。

  

  •  关于监听本身无法分配连接的情况,大多是由于受硬件限制,监听程序本身的处理能力受限。
  •  服务器不允许建立新的连接,一般情况下,是由于连接数已经达到最大值 ,相关参数有sessions,processes.

3. 解决方法 

  1.  确认问题根源。

    如果连接数已经达到或者非常接近最大值时,我们应该果断调整sessions,processes参数,以适应日异增长的业务量,或者说暂时缓解业务连接问题,下一步抓紧分析连接数爆满的原因。

  

alter system set processes=1200 scope=spfile;

  这里调整processes 参数即可,因为 sessiones 会随着processes 参数的变动而自动调整。当然手动指定也是可以的。

    2. 增强监听的处理能力

  对于监听处理能力较弱的问题,暂时没有什么特别好的方法,只有一个方法: 单独分配一个监听 。只有配置静态监听才能实现这种作用:

  

LISTENER_ORCL = 
  (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = x.x.x.x)(PORT = 1534))
    )
  )

SID_LIST_LISTENER_ORCL =
  (SID_LIST =  
    (SID_DESC =  
      (GLOBAL_DBNAME = ORCL)  
      (ORACLE_HOME = /u01/app/oracle/product/11.2.0/dbhome_1)
      (SID_NAME = oracle)  
    )  
  ) 

  


===================
天行健,君子以自强不息
地势坤,君子以厚德载物
===================
原文地址:https://www.cnblogs.com/halberd-lee/p/8601209.html