7

I'm struggling with the following error when starting up sqlplus as my regular user - say "scott".

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

Environment is:

  • Oracle 11.2.0.2
  • OpenSuse Linux 11.1 (64bit)

Misc other detail:

  • Oracle installed and running on localhost
  • No tnsnames issues as can run sqlplus as oracle admin user
  • Database up and listener started (11.2.0.2 install).
  • user scott in database admin group (/etc/group)
  • user scott references correct 11.2.0.2 installation

This is most bizarre as I can happily run sqlplus as the oracle user (say "oraadmin") and user scott is registered in the oracle admin group. Additionally, I had no such problems with my previous Oracle install (10.2.0.7). My ~scott's $ORACLE_HOME references the 11.2.0.2 installation.

Comparing my 11.2.0.2 and 10.2.0.7 environments, I've noticed several libraries (including $ORACLE_HOME/lib/libsqlplus.so) have group read-only permissions (744) so have chmod'ded these.

Other than that, my $ORACLE_HOME/lib, $ORACLE_HOME/bin, $ORACLE_HOME/oracore and $ORACLE_HOME/rdbms all seem reasonable with sensible permissons.

N.B: There's a plethora of stuff on-line but, as is often the case, there's a lot of case-specific issues and mainly around different versions of Windows. Focusing mainly on comparing my envs. Besides, as far as I can tell, this question doesn't yet exist on SO so could be useful to start collating answers by environment. I'll report back any sensible findings.

wmorrison365
  • 5,995
  • 2
  • 27
  • 40
  • Think I may have a problem with my $PATH. – wmorrison365 Jan 09 '12 at 15:01
  • Any update on how you fixed your problem? please help others. – Mowgli Feb 18 '13 at 14:21
  • Hi @mowgli, I've already left a couple of answers below... The first lists some sites I found useful in my search. The second spells out the particular problem I was experiencing (i.e. that I was being a bit stupid ;-) ... In my case, you'll see I was running the wrong client version for my server and the client wouldn't talk to the server (11.2.0.2 server vs 11.1.0.7 client). This was due to my $PATH settings listing the 11107 bin before the 11202 bin [$ORACLE_HOME was irrlevant]). I didn't accept my own answer as it felt a bit cheeky! – wmorrison365 Feb 18 '13 at 16:37
  • WM, I didn't have to do much, all I did was right click and run as administrator on my windows 7 and it worked fine for me. – Mowgli Feb 18 '13 at 19:02
  • I had a registry entry in `HKLM\Software\Oracle\SysWoW64` which is having the Oracle_Home key. I deleted this and it started working! My Environment: Win10, Ora Instant Client 10.2+, Ora 9i Database Server – hiFI Feb 08 '18 at 06:36

4 Answers4

7

If it is Windows 7, You can right click on SQL Plus or whatever software you using, I use Crystal Reports.

so to you would have to right click and Run as Administrator.

it fixed for me.

Mowgli
  • 3,422
  • 21
  • 64
  • 88
  • Great tip... I added full-control for Authenticated Users under file properties for the client_1 folder (right click on folder, Security tab). Seems to have resolved the issue for me – Edd May 11 '16 at 14:37
2

Fixed my particular issue...

User scott's $PATH still contained the ora11.1.0.7 bin. So, on starting sqlplus, I was running the ora11.1.0.7 sqlplus client against the 11.2.0.2 server. Think there may be more to it than that (i.e. I'd probably expect that client to work with that server) but that is the hub of the problem.

In my defence, my.bashrc sets the $PATH correctly so not yet sure what preempts it with the 11.1.0.7 version. Guess the sensible rule of thumb is to add my $ORACLE_HOME/bin to the front of the $PATH to ensure mine is found first, despite what else is set by whatever other environment config, as in

export PATH=$ORACLE_HOME/bin:$PATH

Yours, a little embarrassed but hopefully will be of help again to someone.

wmorrison365
  • 5,995
  • 2
  • 27
  • 40
0

In Windows i found the solution ---

Assign the "Create global objects" user right to the non-Administrator account.

  1. Go to Administrative Tools, and then click Local Security Policy.
  2. Expand Local Policies, and then click User Rights Assignment.
  3. In the right pane, double-click Create global objects.
  4. In the Local Security Policy Setting dialog box, click Add.
  5. In the Select Users or Group dialog box, click the user account that you want to add, click Add, and then click OK.
  6. Click OK.
Brijesh Rana
  • 621
  • 7
  • 6