【TRACE】如何設定或動態跟蹤Oracle net偵聽器
APPLIES TO:
Oracle Net Services - Version 11.2.0.1 to 19.5.0.0.0 [Release 11.2 to 19]
Oracle Database - Enterprise Edition - Version 12.2.0.1 to 12.2.0.1 [Release 12.2]
Information in this document applies to any platform.
GOAL
This document is intended to clarify that from 11.2 onwards, there is no need to first set any tracing parameters under listener.ora or reload the listener to activate listener tracing with timestamps.
Listener tracing can be enabled dynamically through 'set trc_level' command in lsnrctl utility. Independent if ADR is or not enabled, the trace is created with timestamps.
Limitation
~~~~~~~~
Please note that if the
is set to ON for the Listener, then this cannot be done. This parameter needs to be set to OFF or commented out for Dynamic commands to work.
SOLUTION
If your listener name is not using the default name of "listener", then run the command " set current_listener <listener name>" in lsnrctl utility , before any other command is used.
Current Listener is LISTENER_TEST
1. To enable SQL*Net listener tracing dynamically run 'set trc_level 16' command in lsnrctl utility:
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=<hostname.domain>)(PORT=1529)))
LISTENER_TEST parameter "trc_level" set to support
The command completed successfully
If ADR is enabled for the listener , the trace is generated under $ORACLE_BASE/diag/tnslsnr/<hostname>/listener/trace on UNIX or $ORACLE_BASE\diag\tnslsnr\<hostname>\listener\trace on Windows. Default trace name is ora_xxxx_xxxxxxxxx.trc
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=<hostname.domain>)(PORT=1529)))
LISTENER_TEST parameter "trc_file" set to ora_17351_47472935529200.trc
The command completed successfully
If ADR is disabled for the listener , the trace is generated under $ORACLE_HOME/network/trace on UNIX or $ORACLE_HOME\network\trace on Windows. Default trace name is <listener_name>.trc
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=<hostname.domain>)(PORT=1529)))
LISTENER_TEST parameter "trc_file" set to listener_test.trc
The command completed successfully
2. To disable SQL*Net listener tracing dynamically run 'set trc_level 0' command in lsnrctl utility:
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=<hostname.domain>)(PORT=1529)))
LISTENER_TEST parameter "trc_level" set to off
The command completed successfully
Limitation
As mentioned above, if you have the
set to ON for the Listener in the listener.ora file, then you cannot issue any dynamic commands against this listener.
For example:
ADMIN_RESTRICTIONS_<listenername> = ON
The error that will be thrown is:
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=<hostname.domain>)(PORT=1529)))
TNS-12508: TNS:listener could not resolve the COMMAND given
This parameter would need to be set to OFF or commented out, for Dynamic commands to work:
ADMIN_RESTRICTIONS_<listenername> = OFF
Now this will work:
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=<hostname.domain>)(PORT=1529)))
LISTENER parameter "trc_level" set to support
The command completed successfully
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/29487349/viewspace-2856260/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- sp_trace_setfilter sqlserver篩選跟蹤或跟蹤過濾FilterSQLServer
- Golang 大殺器之跟蹤剖析 traceGolang
- Oracle執行語句跟蹤 使用sql trace實現語句追蹤OracleSQL
- Golang 效能測試 (3) 跟蹤刨析 golang traceGolang
- ABAP的許可權檢查跟蹤(Authorization trace)工具
- 如何實現Dolphinscheduler YARN Task狀態跟蹤?Yarn
- 【DB寶49】Oracle如何設定DB、監聽和EM開機啟動Oracle
- 【TRACE】如果通過10046跟蹤資料庫效能問題資料庫
- 使用dbms_monitor.session_trace_enable跟蹤一個會話Session會話
- Oracle資料庫跟蹤SQLOracle資料庫SQL
- 如何追蹤Java動態Java
- 如何追蹤Python動態Python
- 如何追蹤vue動態Vue
- 如何追蹤Go動態Go
- 如何追蹤laravel動態Laravel
- 如何收集Oracle程式中的SQL跟蹤資訊KUOracleSQL
- SAP CRM One Order跟蹤和日誌工具CRMD_TRACE_SET
- oracle跟蹤常用內部事件號Oracle事件
- 好用的時間跟蹤定時器:Eon Timer for Mac定時器Mac
- [20200219]strace跟蹤設定ENABLE=BROKEN的情況.txt
- 如何追蹤laravel動態<二>Laravel
- Linux 跟蹤器之選Linux
- 路由跟蹤命令 tracert www.zzcn.net路由
- oracle靜態監聽Oracle
- 轉:使用 Tkprof 分析 ORACLE 跟蹤檔案Oracle
- Vue計算屬性和偵聽器Vue
- oracle一個listener偵聽多個例項的配置Oracle
- .Net Core JWT 動態設定介面與許可權JWT
- Oracle session traceOracleSession
- ASP.NET Core整合Zipkin鏈路跟蹤ASP.NET
- [20190917]oracle跟蹤事件簡單寫法.txtOracle事件
- Vue中計算屬性和偵聽器Vue
- 命案偵破過程揭示Google能夠跟蹤全世界的手機Go
- 運用Log和Trace檔案排除Oracle Net問題Oracle
- oracle 設定監聽白名單,並且怎麼設定白名單地址Oracle
- [20210603]如何跟蹤索引分裂.txt索引
- w10動態桌布怎麼設定_win10電腦動態桌布如何設定Win10
- Oracle 10046 SQL TRACEOracleSQL