您好,登錄后才能下訂單哦!
今天有AP用戶反映,數據庫有時候連的上,有時候連不上,報如下的錯誤:
ORA-12519: TNS:no appropriate service handler found
二、原因解析
oracle@C01TEST03:/home/oracle>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.
第一個原因可能是Instance沒有注冊到Listener;
第二個原因可能是數據庫上當前的連接數目已經超過了它能夠處理的最大值。
三、解決方法
根據第二步,檢查兩個地方:
1、查看Instance是否注冊到Listener
oracle@C01TEST03:/home/oracle>lsnrctl status
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 03-NOV-2017 15:29:45
Copyright (c) 1991, 2013, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=C01TEST03)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date 25-AUG-2017 13:37:06
Uptime 70 days 1 hr. 52 min. 38 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /oracle/product/11.2.0/network/admin/listener.ora
Listener Log File /oracle/product/diag/tnslsnr/C01TEST03/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=C01TEST03)(PORT=1521)))
Services Summary...
Service "MTH" has 1 instance(s).
Instance "MTH", status READY, has 1 handler(s) for this service...
確認到"MTH" Instance已經注冊到listener里了;
2、數據庫上當前的連接數目已經超過了它能夠處理的最大值。
(1)查看當前連接數
SQL> select count(*) from v$process;
查看數據庫允許最大的連接數
SQL> show parameter processes;
(2)適當加大processes的值
alter system set processes = 300 scope = spfile;
(3)重啟數據庫
(4)查看當前有哪些用戶正在使用數據
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;
四、問題總結
以上便是該問題的思考及處理方向。處理方法以第二種,修改參數processes的方法為主。
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。