LoveUnix » ORACLE等数据库 » oracle客户端执行sqlplus 没有任何反应
让LU留住您的每

一天 让LU博客留住您的每一天
2007-5-28 21:31 Gavin_ygf
oracle客户端执行sqlplus 没有任何反应

操作系统:  rhel4-up2         内核:2.6.9-22.ELsmp
现象 切换到oracle 后 执行sqlplus 没有反映,也不抱错
[root@localhost~]# su - oracle
[oracle@localhost ~]$ sqlplus  

oracle下其他的命令可以执行

通过sar 看到信息
Linux 2.6.9-22.ELsmp (economy2)         05/28/2007

09:43:13 PM       CPU     %user     %nice   %system   %iowait     %idle
09:43:15 PM       all     46.77      0.00     53.23      0.00      0.00
09:43:17 PM       all     47.00      0.00     53.00      0.00      0.00
09:43:19 PM       all     43.20      0.00     54.37      2.43      0.00
Average:          all     45.63      0.00     53.54      0.82      0.00

结束sqlplus
通过sar 2 4 看到系统状况

09:44:15 PM       CPU     %user     %nice   %system   %iowait     %idle
09:44:17 PM       all      0.00      0.00      0.00      0.00      0.00
09:44:19 PM       all      0.00      0.00      0.00      0.00      0.00
09:44:21 PM       all      0.00      0.00      0.00    100.00      0.00
09:44:23 PM       all      0.00      0.00      0.00      0.00      0.00
Average:          all      0.00      0.00      0.00    100.00      0.00

如果系统从起后问题可以解决。但只要执行200天左右就会出现该现象。请问哪位遇到过类似的情况。

2007-5-28 22:39 hexiong
dmesg可以看到什么操作系统异常不?

2007-5-28 23:03 Gavin_ygf
回复 #2 hexiong 的帖子

没有任何异常。从起机器后问题就解决。

2007-5-29 08:22 hexiong
有没有尝试过 先执行sqlplus /nolog ; 再执行conn / as sysdba 一步步来呢?
或者先杀掉所有外部连接 kill -9 `ps -ef | grep NO | awk '{print $2}'` 再尝试登陆

2007-5-29 09:19 Gavin_ygf
回复 #4 hexiong 的帖子

执行sqlplus /nolog后也没有任何反应,估计是oracle10g客户端存在bug
现在还没有确定。我们也在验证的过程。

2007-5-30 16:25 Gavin_ygf
问题确定

SQL*Plus With Instant Client 10.2.0.1 Hangs, When System Uptime Is More Than 248 Days
metalink上的给出的答案是

Applies to: SQL*Plus - Version: 10.2.0.1.0
Linux x86
SymptomsTrying to invoke SQL*Plus  hangs when machine uptime reaches 248 days.

Database connection is not relevant as the 'sqlplus' executable itself hangs with or without connection information. It hangs regardless of what parameters are passed in.  For example:

   sqlplus -V

However, the hang does not reproduce with Instant Client version 10.1.0.4

Generating a stack trace using gdb debugger shows:

#0 0x0048a0dd in times () from /lib/tls/libc.so.6
#1 0x01884599 in sltrgatime64 () from ./libclntsh.so.10.1
#2 0x0137d70f in kghinp () from ./libclntsh.so.10.1
#3 0x00f86b47 in kpuinit0 () from ./libclntsh.so.10.1
#4 0x00f85e7a in kpuenvcr () from ./libclntsh.so.10.1
#5 0x01051b5e in OCIEnvCreate () from ./libclntsh.so.10.1
#6 0x0099787e in afidrv () from ./libsqlplus.so
#7 0x009702b9 in safimTerminate () from ./libsqlplus.so
#8 0x0098c246 in afidrv () from ./libsqlplus.so
#9 0x080486f6 in main ()

Running STRACE tool shows:

$ strace /oracle/home/bin/sqlplus -V 2>&1 |less
......
old_mmap(NULL, 385024, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x41794000
gettimeofday({1122996561, 411035}, NULL) = 0
access("/usr/local/UD/conf/sqlnet.ora", F_OK) = -1 ENOENT (No such file or directory)
access("/usr/local/UD/lib/oracle/network/admin/sqlnet.ora", F_OK) = -1 ENOENT (No such file or directory)
access("/usr/local/UD/conf/sqlnet.ora", F_OK) = -1 ENOENT (No such file or directory)
access("/usr/local/UD/lib/oracle/network/admin/sqlnet.ora", F_OK) = -1 ENOENT (No such file or directory)
fcntl64(-1218313656, F_SETFD, FD_CLOEXEC) = -1 EBADF (Bad file descriptor)
times(NULL) = -1825782405
times(NULL) = -1825782405
times(NULL) = -1825782405
times(NULL) = -1825782405
times(NULL) = -1825782405
times(NULL) = -1825782405
times(NULL) = -1825782405

It is looping on the times() function.

In addition to sqlplus, it has been reported that the netca and dbca tools also hang.

ChangesNew installation of Instant Client 10.2.0.1.0 on Linux platform. CauseThis is a known, unpublished bug.

Bug 4612267 OCI CLIENT IS IN AN INFINITE LOOP WHEN MACHINE UPTIME HITS 248 DAYS

SolutionSelect one of the following two solutions:

1) Apply one-off patch available for 10.2.0.1.
   a. Download one-off patch off Metalink:
       Patch 4612267
       Description OCI CLIENT IS IN AN INFINITE LOOP WHEN MACHINE UPTIME HITS 248 DAYS
       Product CORE
       Release Oracle 10.2.0.1

   b. To apply patch on Instant Client install, please follow instructions documented in the OCI manual.
        You can find this in:
        [url]http://www.oracle.com/pls/db102/db102.show_toc?which=main&partno=b14250&maxlevel=2&section=&expand=3216[/url]

        under "Patching Instant Client Shared Libraries on Linux or UNIX".

2)  Wait for Patchset 10.2.0.2 to be available.
      According to Bug 4612267, this bug is fixed in version 11, and backported to 10.2.0.2 patchset.
      This patchset is estimated to be available mid-Dec 2005; but this is subject to change.

References
--------------------------------------------------------------------------------

Help us improve our service. Please email us your comments for this document. .

2007-5-30 17:39 hexiong
多谢楼主!  
  metalink帐号过期之后 就一直没有办法上了 郁闷了

2007-5-31 01:15 oraix
applying the lasted package of patch is recommended

2007-5-31 12:08 Gavin_ygf
回复 #8 oraix 的帖子

其实最好的方法是打那个patch,但Patch 4612267是不能下载的。这个是给特殊用户作。现在的方法最好是升级客户端。

页: [1]


Powered by Discuz! Archiver 5.5.0  © 2001-2006 Comsenz Inc.