Oracle数据库数据恢复、性能优化

找回密码
注册
搜索
热搜: 活动 交友 discuz
发新帖

13

积分

0

好友

0

主题
1#
发表于 2012-1-8 20:59:30 | 查看: 9274| 回复: 7
在linux 5.5(64bit)上安装RAC完后,用dbca建库,报ora-12705错误!

env:
NLS_LANG=AMERICAN_AMERICA.UTF-8

安装时字符集选的也是utf-8
2#
发表于 2012-1-8 21:06:45
[oracle@vrh1 admin]$ oerr ora 12705
12705, 00000, "Cannot access NLS data files or invalid environment specified"
// *Cause: Either an attempt was made to issue an ALTER SESSION command
//         with an invalid NLS parameter or value; or the environment
//         variable(s) NLS_LANG, ORA_NLSxx, or ORACLE_HOME was incorrectly
//         specified, therefore the NLS data files cannot be located.
// *Action: Check the syntax of the ALTER SESSION command and the NLS
//          parameter, correct the syntax and retry the statement, or
//          specify the correct directory path/values in the environment
//          variables.


action plan:

1.  env

2.  which oracle


将以上命令的输出上传

回复 只看该作者 道具 举报

3#
发表于 2012-1-8 21:11:13

env&&which oracle

[oracle@rac1 ~]$ env
HOSTNAME=rac1
SHELL=/bin/bash
TERM=vt100
HISTSIZE=1000
NLS_LANG=AMERICAN_AMERICA.UTF-8
KDE_NO_IPV6=1
QTDIR=/usr/lib64/qt-3.3
QTINC=/usr/lib64/qt-3.3/include
USER=oracle
LD_LIBRARY_PATH=/app/oracle/product/10.2.0/db_1/lib:/lib:/usr/lib:/app/oracle/product/10.2.0/db_1/rdbms/lib
LS_COLORS=no=00:fi=00:di=01;34:ln=01;36:pi=40;33:so=01;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi=01;05;37;41:ex=01;32:*.cmd=01;32:*.exe=01;32:*.com=01;32:*.btm=01;32:*.bat=01;32:*.sh=01;32:*.csh=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.gz=01;31:*.bz2=01;31:*.bz=01;31:*.tz=01;31:*.rpm=01;31:*.cpio=01;31:*.jpg=01;35:*.gif=01;35:*.bmp=01;35:*.xbm=01;35:*.xpm=01;35:*.png=01;35:*.tif=01;35:
ORACLE_SID=racdb1
ORACLE_BASE=/app/oracle
KDEDIR=/usr
TNS_ADMIN=/app/oracle/product/10.2.0/db_1/network/admin
MAIL=/var/spool/mail/oracle
PATH=/app/oracle/product/10.2.0/db_1/bin:/app/oracle/product/10.2.0/crs_1/bin:/home/oracle/bin:/bin:/sbin:/usr/ccs/bin:/usr/local/bin:/usr/lib64/qt-3.3/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/oracle/bin
INPUTRC=/etc/inputrc
PWD=/home/oracle
LANG=en_US.UTF-8
KDE_IS_PRELINKED=1
SSH_ASKPASS=/usr/libexec/openssh/gnome-ssh-askpass
SHLVL=1
HOME=/home/oracle
ORACLE_CRS_HOME=/app/oracle/product/10.2.0/crs_1
LOGNAME=oracle
QTLIB=/usr/lib64/qt-3.3/lib
CVS_RSH=ssh
CLASSPATH=/app/oracle/product/10.2.0/db_1/JRE:/app/oracle/product/10.2.0/db_1/jlib:/app/oracle/product/10.2.0/db_1/rdbms/jlib:/app/oracle/product/10.2.0/db_1:/app/oracle/product/10.2.0/db_1/network/jlib
LESSOPEN=|/usr/bin/lesspipe.sh %s
SHLIB_PATH=/app/oracle/product/10.2.0/db_1/lib32:/app/oracle/product/10.2.0/db_1/rdbms/lib
ORACLE_HOME=/app/oracle/product/10.2.0/db_1
G_BROKEN_FILENAMES=1
_=/bin/env
[oracle@rac1 ~]$ which oracle
/app/oracle/product/10.2.0/db_1/bin/oracle
[oracle@rac1 ~]$

回复 只看该作者 道具 举报

4#
发表于 2012-1-8 21:23:39
action plan:


unset NLS_LANG

dbca

回复 只看该作者 道具 举报

5#
发表于 2012-1-8 21:36:01
为什么要使用unset NLS_LANG

回复 只看该作者 道具 举报

6#
发表于 2012-1-8 21:45:39
ODM Data
  1. [oracle@vrh1 admin]$ export NLS_LANG=AMERICAN_AMERICA.UTF-8
  2. [oracle@vrh1 admin]$ echo $NLS_LANG
  3. AMERICAN_AMERICA.UTF-8
  4. [oracle@vrh1 admin]$ sqlplus  / as sysdba

  5. SQL*Plus: Release 11.2.0.3.0 Production on Mon Jan 9 00:43:56 2012

  6. Copyright (c) 1982, 2011, Oracle.  All rights reserved.

  7. ERROR:
  8. ORA-12705: Cannot access NLS data files or invalid environment specified


  9. Enter user-name:
  10. ERROR:
  11. ORA-01017: invalid username/password; logon denied


  12. Enter user-name:
  13. ERROR:
  14. ORA-01017: invalid username/password; logon denied


  15. SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
  16. [oracle@vrh1 admin]$ export NLS_LANG=AMERICAN_AMERICA.UTF8
  17. [oracle@vrh1 admin]$ sqlplus  / as sysdba                 

  18. SQL*Plus: Release 11.2.0.3.0 Production on Mon Jan 9 00:44:01 2012

  19. Copyright (c) 1982, 2011, Oracle.  All rights reserved.


  20. Connected to:
  21. Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
  22. With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
  23. Data Mining and Real Application Testing options
复制代码
注意 是 NLS_LANG=AMERICAN_AMERICA.UTF8 而非NLS_LANG=AMERICAN_AMERICA.UTF-8

回复 只看该作者 道具 举报

7#
发表于 2012-1-8 21:49:14
哦,这样啊,是我自己写错了,谢谢Maclean!

回复 只看该作者 道具 举报

8#
发表于 2012-1-9 08:10:25
很多问题不要首先想复杂了。PSU 没打吗?

回复 只看该作者 道具 举报

您需要登录后才可以回帖 登录 | 注册

QQ|手机版|Archiver|Oracle数据库数据恢复、性能优化

GMT+8, 2024-11-15 01:59 , Processed in 0.052696 second(s), 22 queries .

Powered by Discuz! X2.5

© 2001-2012 Comsenz Inc.

回顶部
TEL/電話+86 13764045638
Email service@parnassusdata.com
QQ 47079569