Monday, August 5, 2013

Oracle: ORA-12519, TNS: no appropriate service handler found

This error can have various root causes, but in my particular case it was bothering me while trying to open new connections because apparently I had exceeded the maximum amount of processes and/or allowed sessions.

Fortunately, this value can be modified by running a simple SQL sentence (Oracle needs to be restarted after):


alter system set processes=150 scope=spfile;

SQL*Plus: Release 10.2.0.1.0 - Production on Thu Jun 27 14:46:58 2013

Copyright (c) 1982, 2005, Oracle.  All rights reserved.


Connected to:
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production

SQL> select * from v$resource_limit where resource_name in ('processes','sessions');

RESOURCE_NAME                  CURRENT_UTILIZATION MAX_UTILIZATION
------------------------------ ------------------- ---------------
INITIAL_ALLOCATION
----------------------------------------
LIMIT_VALUE
----------------------------------------
processes                                       38              40
        40
        40

sessions                                        42              49
        49
        49

RESOURCE_NAME                  CURRENT_UTILIZATION MAX_UTILIZATION
------------------------------ ------------------- ---------------
INITIAL_ALLOCATION
----------------------------------------
LIMIT_VALUE
----------------------------------------


SQL> alter system set processes=150 scope=spfile;

System altered.

SQL> exit
Disconnected from Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
gabo@gabo-Precision-M6600:/usr/lib/oracle/xe/app/oracle/product/10.2.0/server$ sudo /etc/init.d/oracle-xe restart
Shutting down Oracle Database 10g Express Edition Instance.
Stopping Oracle Net Listener.

Starting Oracle Net Listener.
Starting Oracle Database 10g Express Edition Instance.

No comments:

Post a Comment