cancel
Showing results for 
Search instead for 
Did you mean: 

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

Former Member
0 Kudos

We just upgraded our database to Oracle 10g and I am not able to connect to the database. We are running ECC 5 on a 640 kernel. It seems that the NLS_LANG environment variable is being set somewhere other than the <sid>adm environment. The environment variables point to the 92x_64 client and oracle home points to 10g. I do not understand where this variable is being set.

Here is the R3trans.log:

sapo-xdps01:bbbadm 5% more trans.log

4 ETW000 R3trans version 6.13 (release 640 - 21.06.06 - 08:38:00).

4 ETW000 ===============================================

4 ETW000

4 ETW000 date&time : 02.08.2007 - 13:56:42

4 ETW000 control file: <no ctrlfile>

4 ETW000 R3trans was called as follows: R3trans -d

4 ETW000 trace at level 2 opened for a given file pointer

4 ETW000 [dev trc ,00000] Thu Aug 2 13:56:42 2007 253 0.000253

4 ETW000 [dev trc ,00000] db_con_init called 40 0.000293

4 ETW000 [dev trc ,00000] create_con (con_name=R/3) 242 0.000535

4 ETW000 [dev trc ,00000] Loading DB library '/usr/sap/BBB/SYS/exe/run/dboraslib.so' ...

4 ETW000 84 0.000619

4 ETW000 [dev trc ,00000] load shared library (/usr/sap/BBB/SYS/exe/run/dboraslib.so), hdl 0

4 ETW000 87968 0.088587

4 ETW000 [dev trc ,00000] Library '/usr/sap/BBB/SYS/exe/run/dboraslib.so' loaded

4 ETW000 88 0.088675

4 ETW000 [dev trc ,00000] function DbSlExpFuns loaded from library /usr/sap/BBB/SYS/exe/run/dboraslib.so

4 ETW000 83 0.088758

4 ETW000 [dev trc ,00000] Version of '/usr/sap/BBB/SYS/exe/run/dboraslib.so' is "640.00", patchlevel (0.125)

4 ETW000 857 0.089615

4 ETW000 [dev trc ,00000] function dsql_db_init loaded from library /usr/sap/BBB/SYS/exe/run/dboraslib.so

4 ETW000 54 0.089669

4 ETW000 [dev trc ,00000] function dbdd_exp_funs loaded from library /usr/sap/BBB/SYS/exe/run/dboraslib.so

4 ETW000 138 0.089807

4 ETW000 [dev trc ,00000] New connection 0 created 43 0.089850

4 ETW000 [dev trc ,00000] 0: name = R/3, con_id = -000000001 state = DISCONNECTED, perm = YES, reco = NO , timeout = 000, con_max = 25

5, con_opt = 255, occ = NO

4 ETW000 75 0.089925

4 ETW000 [dev trc ,00000] db_con_connect (con_name=R/3) 39 0.089964

4 ETW000 [dev trc ,00000] find_con_by_name found the following connection for reuse:

4 ETW000 47 0.090011

4 ETW000 [dev trc ,00000] 0: name = R/3, con_id = 000000000 state = DISCONNECTED, perm = YES, reco = NO , timeout = 000, con_max = 255

, con_opt = 255, occ = NO

4 ETW000 47 0.090058

4 ETW000 [dev trc ,00000] Got ORACLE_HOME=/usr/oracle/product/10g2.2 from environment

4 ETW000 610 0.090668

4 ETW000 [dev trc ,00000] -->oci_initialize (con_hdl=0) 318 0.090986

4 ETW000 [dev trc ,00000] got NLS_LANG='AMERICAN_AMERICA.WE8DEC' from environment

4 ETW000 53 0.091039

4 ETW000 [dev trc ,00000] Client NLS settings: AMERICAN_AMERICA.US7ASCII 15272 0.106311

4 ETW000 [dev trc ,00000] Logon as OPS$-user to get SAPR3's password 53 0.106364

4 ETW000 [dev trc ,00000] Connecting as /@BBB on connection 0 (nls_hdl 0) ... (dbsl 640 310306)

4 ETW000 49 0.106413

4 ETW000 [dev trc ,00000] Nls CharacterSet NationalCharSet C EnvHp ErrHp ErrHpBatch

4 ETW000 51 0.106464

4 ETW000 [dev trc ,00000] 0 US7ASCII 1 10124dee0 101255720 1012550b8

4 ETW000 70 0.106534

4 ETW000 [dev trc ,00000] Allocating service context handle for con_hdl=0 33 0.106567

4 ETW000 [dev trc ,00000] Allocating server context handle 37 0.106604

4 ETW000 [dev trc ,00000] Attaching to DB Server BBB (con_hdl=0,svchp=101254fe8,svrhp=101255de8)

4 ETW000 103 0.106707

4 ETW000 [dev trc ,00000] Assigning server context 101255de8 to service context 101254fe8

4 ETW000 173460 0.280167

4 ETW000 [dev trc ,00000] Allocating user session handle 58 0.280225

4 ETW000 [dev trc ,00000] Starting user session (con_hdl=0,svchp=101254fe8,srvhp=101255de8,usrhp=101260038)

4 ETW000 67 0.280292

4 ETW000 [dboci.c ,00000] *** ERROR => OCI-call 'OCISessionBegin' failed: rc = 12705

4 ETW000 8871 0.289163

4 ETW000 [dev trc ,00000] server_detach(con_hdl=0,stale=1,svrhp=101255de8)

4 ETW000 60 0.289223

4 ETW000 [dev trc ,00000] Detaching from DB Server (con_hdl=0,svchp=101254fe8,srvhp=101255de8)

4 ETW000 47 0.289270

4 ETW000 [dev trc ,00000] Deallocating server context handle 101255de8 838 0.290108

4 ETW000 [dbsloci. ,00000] *** ERROR => CONNECT failed with sql error '12705'

4 ETW000 110 0.290218

4 ETW000 [dev trc ,00000] Try to connect with default password 61 0.290279

4 ETW000 [dev trc ,00000] Connecting as SAPR3/<pwd>@BBB on connection 0 (nls_hdl 0) ... (dbsl 640 310306)

4 ETW000 100 0.290379

4 ETW000 [dev trc ,00000] Nls CharacterSet NationalCharSet C EnvHp ErrHp ErrHpBatch

4 ETW000 51 0.290430

4 ETW000 [dev trc ,00000] 0 US7ASCII 1 10124dee0 101255720 1012550b8

4 ETW000 46 0.290476

4 ETW000 [dev trc ,00000] Allocating server context handle 33 0.290509

4 ETW000 [dev trc ,00000] Attaching to DB Server BBB (con_hdl=0,svchp=101254fe8,svrhp=101255de8)

4 ETW000 81 0.290590

4 ETW000 [dev trc ,00000] Assigning server context 101255de8 to service context 101254fe8

4 ETW000 142781 0.433371

4 ETW000 [dev trc ,00000] Assigning username to user session 101260038 49 0.433420

4 ETW000 [dev trc ,00000] Assigning password to user session 101260038 43 0.433463

4 ETW000 [dev trc ,00000] Starting user session (con_hdl=0,svchp=101254fe8,srvhp=101255de8,usrhp=101260038)

4 ETW000 52 0.433515

4 ETW000 [dboci.c ,00000] *** ERROR => OCI-call 'OCISessionBegin' failed: rc = 12705

4 ETW000 15437 0.448952

4 ETW000 [dev trc ,00000] server_detach(con_hdl=0,stale=1,svrhp=101255de8)

4 ETW000 51 0.449003

4 ETW000 [dev trc ,00000] Detaching from DB Server (con_hdl=0,svchp=101254fe8,srvhp=101255de8)

4 ETW000 449 0.449452

4 ETW000 [dev trc ,00000] Deallocating server context handle 101255de8 427 0.449879

4 ETW000 [dbsloci. ,00000] *** ERROR => CONNECT failed with sql error '12705'

4 ETW000 75 0.449954

4 ETW000 [dblink ,00419] ***LOG BY2=>sql error 12705 performing CON [dblink#2 @ 419]

4 ETW000 99 0.450053

4 ETW000 [dblink ,00419] ***LOG BY0=>ORA-12705: Cannot access NLS data files or invalid environment specified [dblink#2 @ 419]

4 ETW000 45 0.450098

2EETW169 no connect possible: "DBMS = ORACLE --- dbs_ora_tnsname = 'BBB'"

Here are the environment settings:

sapo-xdps01:bbbadm 7% env

HOME=/export/home/bbbadm

USER=bbbadm

LOGNAME=bbbadm

PATH=/usr/oracle/product/10g2.2/bin:.:/export/home/bbbadm:/usr/sap/BBB/SYS/exe/runU:/usr/sap/BBB/SYS/exe/run:/bin:/usr/bin:/usr/ucb:/usr/bin/X11:/usr/local/bin:/usr/local/bin:/usr/ccs/bin

MAIL=/var/mail/bbbadm

SHELL=/bin/csh

TZ=US/Central

TERM=vt100

SSH2_SFTP_LOG_FACILITY=-1

PWD=/export/home/bbbadm

SAPSYSTEMNAME=BBB

DIR_LIBRARY=/usr/sap/BBB/SYS/exe/run

LD_LIBRARY_PATH=/usr/sap/BBB/SYS/exe/run:/export/home/prdadm/j2sdk1.4.2_11/jre/lib/sparc:/export/home/prdadm/j2sdk1.4.2_11/jre/lib/sparc/client

THREAD=NOPS

dbms_type=ORA

dbs_ora_tnsname=BBB

dbs_ora_schema=SAPR3

ORACLE_PSRV=BBB

ORACLE_SID=BBB

DB_SID=BBB

ORACLE_HOME=/usr/oracle/product/10g2.2

ORACLE_BASE=/usr/oracle/product

ORA_NLS33=/oracle/client/92x_64/ocommon/nls/admin/data

NLS_LANG=AMERICAN_AMERICA.WE8DEC

SAPDATA_HOME=/oracle/BBB

JAVA_HOME=/export/home/prdadm/j2sdk1.4.2_11

Thanks!

Erika

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Cannot access NLS data files or invalid environment specified .

Review the note

Note 592657 - ORA-12701/ORA-12705/ORA-12709

and also 393620.

Am sure these two notes will take u to right direction.

Thanks

Subbu

Answers (9)

Answers (9)

Former Member
0 Kudos

Hello,

I was able to get past this error by installing the Oracle 92x_64 client vs using links to the old database folder (created by CROCLLNK).

Thanks!

Former Member
0 Kudos

Prince Jose,

We changed our DB owner and DB path in order to make it easier for the DBA's to support our environment. This has been working for some months and works in our other environments. We are just experiencing a problem after the Oracle 10g upgrade. I think the issue is due to the fact that we are pointing to the 920 client. I was able to get this to work in 2 other systems, but I cannot seem to get this to work? The other systems only had one SAP instance running on them. This is the first time we are doing this with 2 instances. We have BTA and BBB installed on this database server.

Thanks,

Erika

Former Member
0 Kudos

Have you checked the permissions of files/dir like oracle executables and all other files .. make sure that its not changed after upgrade .. I have seen these getting changed and causing trouble after upgrade

Thanks

Prince Jose

Message was edited by:

Prince Jose

Former Member
0 Kudos

Prince Jose,

We are using Solaris 10. I emailed the DBA's to have them add the environment variable ORA_NLS33=/oracle/client/92x_64/ocommon/nls/admin/data. They currently do not have any SAP variables set in the oracle user environment:

HOME=/usr/oracle/admin

PATH=/bin:/usr/bin:/usr/ccs/bin:/usr/sbin:/usr/ucb:/etc:/usr/etc:/etc/bin:/usr/openwin/bin:.

LOGNAME=oracle

HZ=

TERM=vt220

SHELL=/bin/csh

MAIL=/var/mail/oracle

TZ=US/Central

PWD=/usr/oracle/admin

USER=oracle

MANPATH=/usr/man:/usr/share

DBTOOLS=/usr/dba/dbtools

UCT_PASSWD_PATH=/usr/dba/dbtools/uct/passwd.prd

Thanks!

Erika

Former Member
0 Kudos

you need to have variables like dbms_type,ORACLE_SID,ORACLE_HOME,dbs_ora_schema etc in ora<sid> env .. check that note and add all the required variables accordingly.

I think you need check the installation document and read about the OS users and the directories .. Oracle should be runing under ora<sid> and the home directory should be /oracle/<sid>/10* etc

Thanks

Prince Jose

Former Member
0 Kudos

The oracle client links to the 920_64 oracle install:

sapo-xdps01:bbbadm 28% cd /oracle/client/92x_64

sapo-xdps01:bbbadm 29% ls -l

total 0

drwxr-xr-x 2 bbbadm sapsys 96 Aug 2 13:55 ietc

lrwxrwxrwx 1 bbbadm sapsys 31 Aug 2 13:55 jdbc -> /usr/oracle/product/920_64/jdbc

lrwxrwxrwx 1 bbbadm sapsys 30 Aug 2 13:55 lib -> /usr/oracle/product/920_64/lib

drwxr-xr-x 3 bbbadm sapsys 96 Aug 2 13:55 ocommon

And /oracle/client/92x_64/ocommon/nls/admin/data links to /usr/oracle/product/920_64/ocommon/nls/admin/data (which is the oracle install).

Thanks,

Erika

Former Member
0 Kudos

Erica,

Which flavour of unix you are using ? Please double check your env variables with note 602843

Thanks

Prince Jose

SanjayKulkarni
Employee
Employee
0 Kudos

Hi Erika,

Is the client software /oracle/client/92x_64 a soft link to another directory ? And what about /oracle/client/92x_64/ocommon/nls/admin/data. Is this also a link ?

Do both these link to the same location ?

Regards, Sanjay

Former Member
0 Kudos

Hello Sanjay,

The characterset is

NLS_CHARACTERSET

WE8DEC

Thanks.

Erika

SanjayKulkarni
Employee
Employee
0 Kudos

Hello Erika,

What is your database characterset ? NLS_CHARACTERSET ?

You can get this via sqlplus as orasid from:

SQL> select * from V$NLS_PARAMETERS;

Regards, Sanjay

Former Member
0 Kudos

Thanks for the refernece to the notes. I have looked these over multiple times (before I posted a forum) but cannot figure out what I have set wrong? I know that I am able to load the correct libraries:

sapo-xdps01:bbbadm 20% ldd dboraslib.so

libdl.so.1 => /lib/64/libdl.so.1

libnsl.so.1 => /lib/64/libnsl.so.1

libsocket.so.1 => /lib/64/libsocket.so.1

libclntsh.so.9.0 => /oracle/client/92x_64/lib/libclntsh.so.9.0

libwtc9.so => /oracle/client/92x_64/lib/libwtc9.so

libc.so.1 => /lib/64/libc.so.1

libmp.so.2 => /lib/64/libmp.so.2

libmd5.so.1 => /lib/64/libmd5.so.1

libscf.so.1 => /lib/64/libscf.so.1

libgen.so.1 => /lib/64/libgen.so.1

libaio.so.1 => /lib/64/libaio.so.1

librt.so.1 => /lib/64/librt.so.1

libm.so.2 => /lib/64/libm.so.2

libdoor.so.1 => /lib/64/libdoor.so.1

libuutil.so.1 => /lib/64/libuutil.so.1

/platform/SUNW,Sun-Fire-480R/lib/sparcv9/libc_psr.so.1

/platform/SUNW,Sun-Fire-480R/lib/sparcv9/libmd5_psr.so.1

But for some reason I cannot connect to the database because of the NLS_LANG. I verified that I can access the ORA_NLS33 directory. I also reran CROCLLNK. There has to be a discrepency in ORACLE_HOME and the client since ORACLE_HOME points to 10g and we are using the 92x_64 client. I just cannot figure out what I am missing? Please help?

Thanks!