Pages

Tuesday, March 27, 2012

"SP2-1503: Unable to initialize Oracle call interface" in Oracle 11g

Below error appears when we try to log in to 11g Database using sqlplus.

$ sqlplus '/ as sysdba'
SP2-1503: Unable to initialize Oracle call interface
SP2-0152: ORACLE may not be functioning properly

The issue does not appear when I logged in to a separate session and set environment like ORACLE_HOME and ORACLE_SID manually.

Comparing both and checking all the environments I found that on env variable was causing trouble which was
ORA_TZFILE=<ORACLE_HOME>/oracore/zoneinfo/timezlrg.dat

This is some default value and is actually not correct.
When I checked at the location then no such file was there. But other files for all timezones were there with names like timezone_<n>.dat. (See value <n> is missing in present value of ORA_TZFILE)

If we unset the variable (which is the best solution), by default it uses maximum value of n.

unset ORA_TZFILE

Other options are using the desired timezone file.
So if we wish to use any earlier timezone file then we can set the variable to that value with absolute path and file name.

export ORA_TZFILE=<ORACLE_HOME>/oracore/zoneinfo/timezlrg_<n>.dat

This works well in both the cases.

7 comments: