某银行工作流的一个数据库连接不上但现场后通过以下方式进行了排查,后发现由于监听文件太大所致。

1.  排查 过程


1)       ping ip能通

2)       telnet到机器上 数据库server正常

3)       查看监听 发现监听程序没有启动

4)       重启监听  客户端能够连接正常


2. 分析

1) 检查lsnrctl status 正常

2) 检查listener.log 文件  发现这个文件大小为4G。里面内容到3.29日后没有记录

3) 备份listener.log文件 清空 原文件


4) 检查系统是否有文件大小限制

系统 ulimit –a

File size  unlimited不是系统限制


5) 检查是否是oracle限制 官方文档没有明确说listener.log不能超过4G

分析: listener.log 文件太大,理论上来说应该不影响监听,但是实际情况会有很多不确认因素,导致 监听 crash, 客户端连接不上,具体见下文。


Log files arenot mandatory files so need not cause any problem if not generated. As I saidin my earlier updates , if log files are huge can cause connections to hang orprocess instability, random crashes etc. You cannot be sure of out come.Listener can hang, or crash or even not generate tracefiles as is the casehere. It becomes unstable as it has to read through complete file for eachconnection in order to reach its end and update the logs