Oracle dbca时报:ORA-12547: TNS:lost contact错误的解决

前言

最近在工作中遇到了一个问题,错误是oracle dbca时报错:ora-12547: tns:lost contact,通过查找相关的资料终于找到了解决的方法,下面分享给大家,话不多说了,来一起看看详细的介绍吧。

环境:

  • os:rhel6.5 x86-64bit
  • db:11.2.0.4 for linux 86-64bit

思路:

dbca报错,首先看dbca的日志,日志中也是报ora-12547: tns:lost contact

于是再sqlplus / as sysdba敲回车,也是报ora-12547: tns:lost contact,

基于之前的工程经验,先到bdump下找trc文件,不过在bdump下是没有任何trc生成的。

再到/u01/app/oracle/product/11.2.0/db_1/rdbms/log下找trc文件,果然找到了:

[oracle@dg1 log]$ pwd 
/u01/app/oracle/product/11.2.0/db_1/rdbms/log 
[oracle@dg1 log]$ ls -lrt 
total 9808 
-rw-r-----. 1 oracle oinstall 401207 feb 1 16:16 dbua1557284_ora_8053.trc 
-rw-r-----. 1 oracle oinstall 401207 feb 1 16:16 dbua1557284_ora_8062.trc 
-rw-r-----. 1 oracle oinstall 401207 feb 1 16:16 dbua1557284_ora_8065.trc 
-rw-r-----. 1 oracle oinstall 401373 feb 1 16:18 dg1_ora_8227.trc 
-rw-r-----. 1 oracle oinstall 401228 feb 1 16:26 dg1_ora_2701.trc 
-rw-r-----. 1 oracle oinstall 401228 feb 1 16:26 dg1_ora_2706.trc 
-rw-r-----. 1 oracle oinstall 401410 feb 1 16:27 dg1_ora_2715.trc 
-rw-r-----. 1 oracle oinstall 401228 feb 1 16:27 dg1_ora_2722.trc 
-rw-r-----. 1 oracle oinstall 401244 feb 1 16:31 dbua3144297_ora_2792.trc 
-rw-r-----. 1 oracle oinstall 401244 feb 1 16:31 dbua3144297_ora_2801.trc 
-rw-r-----. 1 oracle oinstall 401244 feb 1 16:31 dbua3144297_ora_2804.trc 
-rw-r-----. 1 oracle oinstall 401410 feb 1 16:34 dg1_ora_2930.trc 
-rw-r-----. 1 oracle oinstall 401341 feb 1 17:27 dg1_ora_3181.trc 
-rw-r-----. 1 oracle oinstall 401090 feb 1 17:27 dg1_ora_3187.trc 
-rw-r-----. 1 oracle oinstall 401341 feb 1 17:27 dg1_ora_3190.trc 
-rw-r-----. 1 oracle oinstall 401090 feb 1 17:28 dg1_ora_3205.trc 
-rw-r-----. 1 oracle oinstall 401341 feb 1 17:28 dg1_ora_3210.trc 
-rw-r-----. 1 oracle oinstall 401090 feb 1 17:28 dg1_ora_3214.trc 
-rw-r-----. 1 oracle oinstall 401090 feb 1 17:36 dg1_ora_3313.trc 
-rw-r-----. 1 oracle oinstall 401341 feb 1 17:37 dg1_ora_3329.trc 
-rw-r-----. 1 oracle oinstall 401090 feb 1 17:37 dg1_ora_3341.trc 
-rw-r-----. 1 oracle oinstall 401090 feb 1 17:37 dg1_ora_3344.trc 
-rw-r-----. 1 oracle oinstall 401341 feb 1 17:40 dg1_ora_3369.trc 
-rw-r-----. 1 oracle oinstall 401341 feb 1 17:40 dg1_ora_3375.trc 
-rw-r-----. 1 oracle oinstall 401090 feb 1 17:40 dg1_ora_3378.trc 
[oracle@dg1 log]$ 
[oracle@dg1 log]$ vi dg1_ora_3369.trc 
 
dump file /u01/app/oracle/product/11.2.0/db_1/rdbms/log/dg1_ora_3369.trc 
 
*** 2016-02-01 17:40:23.652 
oracle database 11g enterprise edition release 11.2.0.4.0 - 64bit production 
with the partitioning, olap, data mining and real application testing options 
oracle_home = /u01/app/oracle/product/11.2.0/db_1 
system name: linux 
node name:  dg1 
release:  2.6.32-431.el6.x86_64 
version:  #1 smp sun nov 10 22:19:54 est 2013 
machine:  x86_64 
instance name: dg1 
redo thread mounted by this instance: 0 <none> 
oracle process number: 0 
unix process pid: 3369, image: oracle@dg1 
 
 
*** 2016-02-01 17:40:23.652 
skgm error 27135: errno = 0, info = 0, 0, 0, 0, 1048576, 2097152, 0 
skgm error 27135: errno = 0, info = 0, 0, 0, 0, 1048576, 2097152, 0 
 
*** 2016-02-01 17:40:23.654 
exception [type: sigsegv, address not mapped to object] [addr:0x3d8] [pc:0x95be6eb, opiodr()+11347] [flags: 0x0, count: 1] 
registers: 
%rax: 0x000000000c0ea630 %rbx: 0x000000000c0ea638 %rcx: 0x0000000000000000 
%rdx: 0x0000000000000000 %rdi: 0x000000000c0ccba0 %rsi: 0x00007fffa308e250 
%rsp: 0x00007fffa308d970 %rbp: 0x00007fffa308e440 %r8: 0x00007fffa308d970 
 %r9: 0x00007fffa308e440 %r10: 0x00007fffa308c600 %r11: 0x00007fab40ec1538 
%r12: 0x000000000000003c %r13: 0x0000000000000004 %r14: 0x00007fffa308e6f8 
%r15: 0x0000000000000002 %rip: 0x00000000095be6eb %efl: 0x0000000000010246 
 opiodr()+11325 (0x95be6d5) lea (%rax,%rbx),%rdx 
 opiodr()+11329 (0x95be6d9) mov %rdx,(%rcx,%rbx) 
 opiodr()+11333 (0x95be6dd) mov 0x2b34a84(%rip),%rax 
 opiodr()+11340 (0x95be6e4) mov 0x178(%rax),%rdx 
> opiodr()+11347 (0x95be6eb) movzwl 0x3d8(%rdx),%ecx 
 opiodr()+11354 (0x95be6f2) test $0x100,%ecx 
 opiodr()+11360 (0x95be6f8) jz 0x95bc8c7 
 opiodr()+11366 (0x95be6fe) mov -0x18(%rbp),%eax 
 opiodr()+11369 (0x95be701) cmp $60,%eax 
 
*** 2016-02-01 17:40:23.660 
dbkeddefdump(): starting a non-incident diagnostic dump (flags=0x1, level=3, mask=0x0) 
----- error stack dump ----- 
ora-07445: exception encountered: core dump [opiodr()+11347] [sigsegv] [addr:0x3d8] [pc:0x95be6eb] [address not mapped to object] [] 
ora-27135: operating system hard stack limit is set too low ----------->>>>>>>注意此处 
additional information: 1048576 
additional information: 2097152 
----- sql statement (none) ----- 
current sql information unavailable - no sga. 
以下省略。。。 

解决方法

最后确认,是/etc/security/limits.conf文件的问题:

oracle soft nproc 2047 
oracle hard nproc 16384 
oracle soft nofile 1024 
oracle hard nofile 65536 
oracle soft stack 1024--->此处应该是10240,依据:requirements for installing oracle 11gr2 rdbms on rhel6 or ol6 64-bit (x86-64) (文档 id 1441282.1) 

修改完之后,关闭dbca界面,exit退出oracle用户,su – oracle用户,再重新发起dbca即可。

总结

以上就是这篇文章的全部内容了,希望本文的内容对大家的学习或者工作具有一定的参考学习价值,如果有疑问大家可以留言交流,谢谢大家对www.887551.com的支持。

(0)
上一篇 2022年3月21日
下一篇 2022年3月21日

相关推荐