Operating System - HP-UX
1752740 Members
5406 Online
108789 Solutions
New Discussion юеВ

Re: ORA-12705 in Oracle10g

 
SOLVED
Go to solution
Ankit Grover
Frequent Advisor

ORA-12705 in Oracle10g

Dear all,

I have installed Oracle10g on HP-UX 11.23 IA64 box. I am facing error regarding NLS_LANG while trying to login through SQL*Plus

Pasting my log of events:

fnsonly1-/fns/y1/r/home>sqlplus /
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Apr 24 11:47:17 2007
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.

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


fnsonly1-/fns/y1/r/home>echo $NLS_LANG
AMERICAN_AMERICA.WE8ISO8859P1
fnsonly1-/fns/y1/r/home>unset NLS_LANG
fnsonly1-/fns/y1/r/home>sqlplus /
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Apr 24 11:49:11 2007
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.

Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options

SQL> select * from V$NLS_PARAMETERS where PARAMETER in ('NLS_LANGUAGE','NLS_TERRITORY','NLS_CHARACTERSET');

PARAMETER VALUE
---------------- ---------
NLS_LANGUAGE AMERICAN
NLS_TERRITORY AMERICA
NLS_CHARACTERSET WE8ISO8859P1

Any idea why it is happening?

Regards,
Ankit
9 REPLIES 9
SANTOSH S. MHASKAR
Trusted Contributor

Re: ORA-12705 in Oracle10g

Hi Ankit,

It is surely ur setting problem.
----------------------------
[oracle@wfms1] $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.
-----------------------------

It says ur setting r incorrect.

Below is what I got on my machine.

---------------------------
[oracle@wfms1] $env|grep NLS
NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1
[oracle@wfms1] $sqlplus

SQL*Plus: Release 10.2.0.1.0 - Production on Tue Apr 24 12:12:32 2007

Copyright (c) 1982, 2005, Oracle. All rights reserved.

Enter user-name: /as sysdba

Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options

SQL> Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options
[oracle@wfms1] $NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1_00
[oracle@wfms1] $sqlplus

SQL*Plus: Release 10.2.0.1.0 - Production on Tue Apr 24 12:13:06 2007

Copyright (c) 1982, 2005, Oracle. All rights reserved.

Enter user-name: /as sysdba
ERROR:
ORA-12705: Cannot access NLS data files or invalid environment specified


Enter user-name:
-------------------------------

Just check ur NLS_LANG parameter or ORACLE_HOME setting.
Ankit Grover
Frequent Advisor

Re: ORA-12705 in Oracle10g

Santosh,
I am not able to found anything wrong with the settings. I am sending the few details:

fnsonly1-/fns/y1/r/home>unset NLS_LANG
fnsonly1-/fns/y1/r/home>echo $NLS_LANG

fnsonly1-/fns/y1/r/home>sqlplus /
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Apr 24 12:34:45 2007
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.

Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options

SQL> Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - 64bit Production
With the Partitioning, OLAP and Data Mining options

fnsonly1-/fns/y1/r/home>export NLS_LANG=AMERICAN_AMERICA.WE8ISO8859P1
fnsonly1-/fns/y1/r/home>sqlplus /
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Apr 24 12:34:56 2007
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.

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


Environment variables:
fnsonly1-/fns/y1/r/home>env|grep -i oracle
SHLIB_PATH=/usr/lib/hpux64:/opt/cobol/cobdir/lib:/oracle/product/10g/lib
PATH=/home/scripts:/fns/y1/r/sh:/fns/y1/r/cat:/fns/y1/r/exe:/fns/y1/r/dbora/exe:/opt/bin:/usr/lbin:/usr/vacpp/bin:/home/scripts:/fns/y1/r/sh:/fns/y1/r/cat:/fns/y1/r/exe:/fns/y1/r/dbora/exe:/opt/bin:/usr/lbin:/usr/vacpp/bin:/usr/bin:/usr/ccs/bin:/usr/contrib/bin:/usr/contrib/Q4/bin:/opt/perl/bin:/usr/local/bin:/usr/bin:/opt/ansic/bin:/usr/ccs/bin:/usr/contrib/bin:/usr/contrib/Q4/bin:/opt/perl/bin:/opt/hparray/bin:/opt/nettladm/bin:/opt/fcms/bin:/usr/contrib/kwdb/bin:/usr/bin/X11:/opt/graphics/common/bin:/opt/upgrade/bin:/usr/contrib/bin/X11:/opt/ipf/bin:/opt/resmon/bin:/opt/ignite/bin:/opt/aCC/bin:/opt/sec_mgmt/bastille/bin:/opt/caliper/bin:/opt/gnome/bin:/opt/mozilla:/opt/wbem/bin:/opt/wbem/sbin:/opt/sec_mgmt/spc/bin:/opt/hpsmh/bin:/opt/langtools/bin:/opt/gwlm/bin:/opt/omni/bin:.:/utree/bin:/fns:.:/oracle/product/10g/bin:/home/scripts:/fns:/usr/local/bin:.:/utree/bin:/fns:.:/home/scripts:/fns:/usr/local/bin
ORACLE_SID=rcbo10g
BANCSORACLETRACEUSER=fnsonly1
ORACLE_HOME=/oracle/product/10g
Piergiacomo Perini
Trusted Contributor

Re: ORA-12705 in Oracle10g

Hi Ankit,

maybe this document from Oracle Metalink
could clarify your issue

Note:158654.1

hth
regards
pg
Yogeeraj_1
Honored Contributor
Solution

Re: ORA-12705 in Oracle10g

hi Ankit,

can you also verify if your files permission are ok.

In fact, if you do not have the right permissions set on the NLS data files, you will also receive an ORA-12705.

The NLS loadable files are usually located in:
$ORACLE_HOME/nls/data on Unix

The protections should be as follows:

drwxr-xr-x 2 oracle dba 9728 Aug 3 15:17 data/
-rw-r--r-- 1 oracle dba 714 Mar 312000 *.nlb

To change the protection issue:
Directory: chmod 755
Files: chmod 644 *.nlb

Hope this helps!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Ankit Grover
Frequent Advisor

Re: ORA-12705 in Oracle10g

Thanks a zillion Yogeeraj.

I had checked that the read permissions are there for all the files under NLS directory. By giving o+x to /oracle/product/10g/nls/data the problem has got resolved.

But I am not able to fully understand what has excatly happened. I mean others had read permissions on the folder earlier. What is the real meaning of execute permissions on the folder?
SANTOSH S. MHASKAR
Trusted Contributor

Re: ORA-12705 in Oracle10g

Hi,

May be following Metalink Notes can help u.

264157.1: The correct NLS_LANG setting in Unix Environments
152711.1: Connect Internal Using SQLPLUS Fails With ORA-12705
158654.1: ORA-12705 - Common Reasons and How to Resolve Them.


Regards

-Santosh
Yogeeraj_1
Honored Contributor

Re: ORA-12705 in Oracle10g

Hi Ankit,

The only thing that comes to my mind is the fact that some installation procedures had not been executed properly (e.g. running root.sh at some particular instant during the installation). It could be also be an accidental change made to the file system.

If you have a backup of the installation when it was freshly done, may be you can have a clearer picture.


Last thing that i can think of is a BUG!

As for the "why" of such file permissions, only Oracle can clarify this for us.

all the best.

kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Ankit Grover
Frequent Advisor

Re: ORA-12705 in Oracle10g

Oracle10g installation on HP Itanium boxes create lots of problems regarding file permissions. Many of them get resolved by installing latest 10g patch. But still there is a lot of struggle identifying the permissions problems. I hope Oracle will soon come up with new patch covering all such problems with the installation
Ankit Grover
Frequent Advisor

Re: ORA-12705 in Oracle10g

The error was coming due to wrong file permissions as has been discussed in the earlier posts