INBOUND_CONNECT_TIMEOUT(zt)
1. sqlnet.ora 引數 SQLNET.INBOUND_CONNECT_TIMEOUT
表示等待使用者認證超時的時間,單位是秒,預設值是60秒
如果使用者認證超時了,伺服器日誌alert.log顯示出錯資訊
"WARNING: inbound connection timed out (ORA-3136)"
舉例:
連線監聽器,不輸入使用者名稱/密碼
sqlplus /@test
[oracle@MGT ~]$ sqlplus /@test
SQL*Plus: Release 10.2.0.4.0 - Production on Tue Jan 20 07:53:42 2009
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
Enter user-name:
等一分鐘後,alert.log報ora-3136錯
Tue Jan 20 07:54:42 2009
WARNING: inbound connection timed out (ORA-3136)
編輯$ORACLE_HOME/network/admin/sqlnet.ora,設定引數SQLNET.INBOUND_CONNECT_TIMEOUT等於12秒
grep SQLNET.INBOUND_CONNECT_TIMEOUT $ORACLE_HOME/network/admin/sqlnet.ora
[oracle@MGT ~]$ grep SQLNET.INBOUND_CONNECT_TIMEOUT $ORACLE_HOME/network/admin/sqlnet.ora
SQLNET.INBOUND_CONNECT_TIMEOUT=12
[oracle@MGT ~]$
再連線監聽器,不輸入使用者名稱/密碼
sqlplus /@test
[oracle@MGT ~]$ sqlplus /@test
SQL*Plus: Release 10.2.0.4.0 - Production on Tue Jan 20 07:59:39 2009
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
Enter user-name:
過了12秒,alert.log又報錯了
Tue Jan 20 07:59:51 2009
WARNING: inbound connection timed out (ORA-3136)
這個引數只要修改了sqlnet.ora配置檔案,便立即生效,不需要重啟監聽器/資料庫
2. listener.ora的引數 inbound_connect_timeout_監聽器名
表示等待使用者連線請求超時的時間,單位是秒,預設值是60秒
如果連線請求超時了,監聽器日誌listener.log顯示出錯資訊
"TNS-12525: TNS:listener has not received client's request in time allowed"
伺服器日誌alert.log裡不報錯
舉例:
用telnet命令在監聽器埠建立連線
time telnet localhost 1521
過一分鐘後,連線被斷開
[oracle@MGT ~]$ time telnet localhost 1521
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.
real 1m0.015s
user 0m0.001s
sys 0m0.002s
[oracle@MGT ~]$
同時監聽器日誌報錯
20-JAN-2009 08:01:29 * 12502
TNS-12502: TNS:listener received no CONNECT_DATA from client
20-JAN-2009 08:02:32 * * (ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=3871)) * establish * * 12525
TNS-12525: TNS:listener has not received client's request in time allowed
TNS-12535: TNS:operation timed out
TNS-12606: TNS: Application timeout occurred
把引數修改成9秒
lsnrctl set inbound_connect_timeout 9
[oracle@MGT ~]$ lsnrctl set inbound_connect_timeout 9
LSNRCTL for Linux: Version 10.2.0.4.0 - Production on 20-JAN-2009 08:03:06
Copyright (c) 1991, 2007, Oracle. All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
LISTENER parameter "inbound_connect_timeout" set to 9
The command completed successfully
[oracle@MGT ~]$
再試
time telnet localhost 1521
[oracle@MGT ~]$ time telnet localhost 1521
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.
real 0m9.004s
user 0m0.000s
sys 0m0.002s
[oracle@MGT ~]$
20-JAN-2009 08:03:28 * * (ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=3891)) * establish * * 12525
TNS-12525: TNS:listener has not received client's request in time allowed
TNS-12535: TNS:operation timed out
TNS-12606: TNS: Application timeout occurred
連線超時縮短為9秒
這個引數也是立即生效的,不需要重啟監聽器或資料庫
也可以修改listener.ora配置檔案,然後reload監聽器,使新的引數生效
grep INBOUND_CONNECT_TIMEOUT $ORACLE_HOME/network/admin/listener.ora
lsnrctl reload
[oracle@MGT ~]$ grep INBOUND_CONNECT_TIMEOUT $ORACLE_HOME/network/admin/listener.ora
INBOUND_CONNECT_TIMEOUT_LISTENER=5
[oracle@MGT ~]$ lsnrctl reload
LSNRCTL for Linux: Version 10.2.0.4.0 - Production on 20-JAN-2009 08:05:44
Copyright (c) 1991, 2007, Oracle. All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
The command completed successfully
[oracle@MGT ~]$
指定時間後連線超時
[oracle@MGT ~]$ time telnet localhost 1521
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.
real 0m5.006s
user 0m0.002s
sys 0m0.002s
[oracle@MGT ~]$
20-JAN-2009 08:06:06 * * (ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=3916)) * establish * * 12525
TNS-12525: TNS:listener has not received client's request in time allowed
TNS-12535: TNS:operation timed out
TNS-12606: TNS: Application timeout occurred
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/756652/viewspace-545291/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- INSTEAD OF(zt)
- lsof(zt)
- SQLSERVER SELECT(zt)SQLServer
- V$LOCK(zt)
- EXISTS、IN、NOT EXISTS、NOT IN(zt)
- Event Reference(zt)
- oracle enqueue(zt)OracleENQ
- Fallacies Of The CBO(zt)
- INBOUND_CONNECT_TIMEOUT與SQLNET.INBOUND_CONNECT_TIMEOUT小結SQL
- DBMS_PROFILER(zt)
- oracle event 2 (zt)Oracle
- ORA-00604(zt)
- 物化檢視(zt)
- SQL Access Advisor(zt)SQL
- DBMS_SUPPORT(zt)
- LOCK_SGA(zt)
- oracle job管理(zt)Oracle
- histogram與10053(zt)Histogram
- sybase複製(zt)
- DBMS_TRACE(zt)
- Understanding System Statistics(zt)
- ORACLE LARGE MEMORY(zt)Oracle
- dbms_stats(zt)
- 切換UNDO(zt)
- ora_rowscn(zt)
- checkpoint詳解(zt)
- SQLSERVER日期函式(zt)SQLServer函式
- SqlServer鎖的概述(zt)SQLServer
- how to show hidden parameter(zt)
- checkpoint是什麼(zt)
- crontab命令簡介(zt)
- AIX基礎教程(zt)AI
- oracle time_zone(zt)Oracle
- sybase優化概述(zt)優化
- AUTO START ORACLE ON LINUX(zt)OracleLinux
- SYBASE優化總結(zt)優化
- Oracle's Parallel Execution Features(zt)OracleParallel
- MySQL如何避免使用swap(ZT)MySql