Oracle sqlplus连接很慢

一个测试库上有很多个用户,其中的一个用户修改密码之后,就出现了连接缓慢的情况,而这个数据库上其他的用户连接没有问题。这种问题得先用strace跟踪一下:

strace -T -t -o /tmp/s.out sqlplus test/test

-T Show the time spent in system calls. This records the time difference between the beginning and the end of each system call.
-o Write the trace output to the file filename rather than to stderr.
-t Prefix each line of the trace with the time of day.


13:55:09 execve("/data1/oracle11g/product/11.2.0.4/db_1/bin/sqlplus",["sqlplus","lcam_zc_0130/lcam_zc_pzgpassword"...],[/* 32 vars */]) = 0 <0.000364>
13:55:09 brk(0) = 0x1ea1000 <0.000040>
13:55:09 mmap(NULL,4096,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANONYMOUS,-1,0) = 0x7f32071aa000 <0.000025>
13:55:09 access("/etc/ld.so.preload",R_OK) = -1 ENOENT (No such file or directory) <0.000044>
13:55:09 open("/data1/oracle11g/product/11.2.0.4/db_1/lib/tls/x86_64/libsqlplus.so",O_RDONLY) = -1 ENOENT (No such file or directory) <0.000025>
13:55:09 stat("/data1/oracle11g/product/11.2.0.4/db_1/lib/tls/x86_64",0x7fff3e3dacf0) = -1 ENOENT (No such file or directory) <0.000013>
13:55:09 open("/data1/oracle11g/product/11.2.0.4/db_1/lib/tls/libsqlplus.so",O_RDONLY) = -1 ENOENT (No such file or directory) <0.000014>
13:55:09 stat("/data1/oracle11g/product/11.2.0.4/db_1/lib/tls",0x7fff3e3dacf0) = -1 ENOENT (No such file or directory) <0.000012>
13:55:09 open("/data1/oracle11g/product/11.2.0.4/db_1/lib/x86_64/libsqlplus.so",O_RDONLY) = -1 ENOENT (No such file or directory) <0.000014>
13:55:09 stat("/data1/oracle11g/product/11.2.0.4/db_1/lib/x86_64",0x7fff3e3dacf0) = -1 ENOENT (No such file or directory) <0.000013>
13:55:09 open("/data1/oracle11g/product/11.2.0.4/db_1/lib/libsqlplus.so",O_RDONLY) = 3 <0.000019>
.........................
13:55:10 write(10,"\5z\0\0\6\0\0\0\0\0\3s\3\376\377\377\377\377\377\377\377\f\0\0\0\1\1\0\0\376\377\377"...,1402) = 1402 <0.000016>
13:55:10 read(11,"\4\222\0\0\6\0\0\0\0\0\10\31\0\23\0\0\0\23AUTH_VERSION_S"...,8208) = 1170 <5.886348>
13:55:15 open("/data1/oracle11g/product/11.2.0.4/db_1/rdbms/mesg/oraus.msb",O_RDONLY) = 9 <0.000075>
13:55:15 fcntl(9,F_SETFD,FD_CLOEXEC) = 0 <0.000013>


很可惜,不知道这个是什么意思,因为有很多weblogic连到这个库上,weblogic有自动重连的机制,然后把weblogic连接池的密码都修改完后,sqlplus连接速度正常了。真是乱拳打死老师傅啊,问题解决了。

相关文章

文章浏览阅读773次,点赞6次,收藏9次。【代码】c# json字符...
文章浏览阅读8.7k次,点赞2次,收藏17次。此现象一般定位到远...
文章浏览阅读2.8k次。mysql脚本转化为oracle脚本_mysql建表语...
文章浏览阅读2.2k次。cx_Oracle报错:cx_Oracle DatabaseErr...
文章浏览阅读1.1k次,点赞38次,收藏35次。本文深入探讨了Or...
文章浏览阅读1.5k次。默认自动收集统计信息的时间为晚上10点...