码迷,mamicode.com
首页 > 其他好文 > 详细

ORA-12162

时间:2017-08-24 14:51:30      阅读:258      评论:0      收藏:0      [点我收藏+]

标签:可见   database   net   nbsp   sysdba   engine   登录   ring   detail   

 

 

2.故障原因

诡异的故障背后的原因竟然是那样的基础:ORACLE_SID没有指定!
确认系统当前的ORACLE_HOME和ORACLE_SID环境变量

[sql] view plain copy

 

  1. [oracle@asdlabdb01 ~]$ echo $ORACLE_HOME  
  2. /oracle/app/oracle/product/10.2.0/db_1  
  3. [oracle@asdlabdb01 ~]$ echo $ORACLE_SID  
  4.   
  5. [oracle@asdlabdb01 ~]$  


可见,此时只设置了ORACLE_HOME环境变量,但ORACLE_SID此时为空,这就是该问题的真实原因。

3.故障处理

给出ORACLE_SID,重新尝试登录。

[sql] view plain copy

 
  1. [oracle@asdlabdb01 ~]$ export ORACLE_SID=ora10g  
  2. [oracle@asdlabdb01 ~]$ echo $ORACLE_SID  
  3. ora10g  
  4. [oracle@asdlabdb01 ~]$ sqlplus / as sysdba  
  5.   
  6. SQL*Plus: Release 10.2.0.3.0 - Production on Sat Aug 27 23:27:34 2010  
  7.   
  8. Copyright (c) 1982, 2006, Oracle.  All Rights Reserved.  
  9.   
  10. Connected to:  
  11. Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bit Production  
  12. With the Partitioning, Oracle Label Security, OLAP and Data Mining Scoring Engine options  
  13.   
  14. sys@ora10g>  


OK,此时问题处理完毕。

ORA-12162

标签:可见   database   net   nbsp   sysdba   engine   登录   ring   detail   

原文地址:http://www.cnblogs.com/feiyun8616/p/7422716.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!