InstantClientTap / homebrew-instantclient

A tap of Mac Homebrew formulas for Oracle Instant Client.
MIT License
80 stars 39 forks source link

sqlplus returns Message file sp1<lang>.msb not found #28

Closed ahinkle closed 5 years ago

ahinkle commented 5 years ago

Hi , I've installed sqlplus and basic. Everything looks to be installed ok. however, when I run sqlplus I get the following error: 

OS: Mac OS X: Mojave

➜ ~ sqlplus
Error 6 initializing SQL*Plus
SP2–0667: Message file sp1<lang>.msb not found
SP2–0750: You may need to set ORACLE_HOME to your Oracle software directory

I've ran export ORACLE_HOME=/usr/local/Cellar/instantclient-basic/12.2.0.1.0–2/lib & export ORACLE_HOME=/usr/local/Cellar/instantclient-basic/12.2.0.1.0–2/ with the same issue.

Any ideas?

kaukas commented 5 years ago

This is the first time I see this problem, never had it myself. Did a quick search, there are a few related posts but nothing conclusive. It likely has something to do with your paths but I really don't know how. Sorry, there's not much I can do…

ahinkle commented 5 years ago

Thanks — Just to confirm, do you need to install any other software on your pc to connect to a remote oracle database? I keep seeing this /oracle/12.1/client64/bin file reference?

ahinkle commented 5 years ago

Update: I have no idea what happened but I uninstalled/reinstalled basic/sqlplus (and for what it's worth resourced my bash_profile) and it works. Thanks for the links.

RyanSnodgrass commented 4 years ago

Had the same problem perhaps after upgrading to OSX Catalina. Also uninstalling and reinstalling resolved my issue.

Only thing of note is it couldn't link a couple files within basic client so I had to run brew link --overwrite instantclient-basic.

Hope this helps anyone else having this issue.

danizen commented 2 years ago

Monterey 12.3.1 - same deal

ZeloBox commented 12 months ago

If you have only SQLPLUS installed without everything else supplied in the installer (this can be needed if you only need SQLPLUS), then you must to copy both the libraries and sqlplus.exe itself to the one directory.

For example:

Configuration, that throw error: "Error 6 initializing SQL*Plus SP2-0667: Message file sp1.msb not found SP2-0750: You may need to set ORACLE_HOME to your Oracle software directory" :

To fix it, you need to move all the files to one directory and set the paths as follows

for windows:

set PATH=%PATH%;d:\oracle\instantclient_21_12
set ORACLE_HOME=d:\oracle\instantclient_21_12

for linux:

export ORACLE_HOME=/home/petya/oracle/instantclient_21_12
export PATH=/home/petya/oracle/instantclient_21_12:$PATH