|
Oracle deployment from the AFS tree at CERN
In order to build and run programs on Linux against the Oracle
10g software installed on AFS at CERN, users must choose
one of the two following options.
1. ORACLE_HOME-based Client
The ORACLE_HOME-based Oracle 10g client software for RedHat Enterprise
Linux is installed at CERN in /afs/cern.ch/project/oracle/@sys/prod where @sys will resolve to an specific directory (i.e. linux, linux64,..) depending on the OS of your server.
This contains all the binaries, libraries and data files that are
needed to build and execute client applications based on a variety
of technologies, including SQLPLUS, JDBC, ProC, OCI and OCCI (the
latter for the gcc3.2.3 compiler).
To use this installation, you just need to create a file called oracle in your $HOME/.hepix folder and place
a '1' in it and then re-login
lxplus242.cern.ch:$ cd $HOME; echo '1' > oracle
This is a one time operation only.
Alternatively, you can manually do the setup by running the following scripts
, depending on whether you are using the sh or csh shell families.
source /afs/cern.ch/project/oracle/script/setoraenv.sh
source /afs/cern.ch/project/oracle/script/setoraenv.csh
This will set all the relevant environment variables that are needed
by your applications at runtime, including PATH, LD_LIBRARY_PATH,ORACLE_HOME and TNS_ADMIN
The setoraenv script will set the oracle environment variables to the default binaries:
lxplus242.cern.ch$ setoraenv -l
List of valid values is
10203 --> "10g Release 2 + Patch Set 2"
10204 --> "10g Release 2 + Patch Set 3"
11201 --> "11g Release 2"
DEFAULT VERSION IS ==> 10203
You can also use -s option to set it to one of the above defined values:
lxplus242.cern.ch$ setoraenv -s 10204
The OCI and OCCI header files that are needed to compile C or
C++ applications can be found in /afs/cern.ch/project/oracle/@sys/prod/rdbms/public.
2. Instant Client (without ORACLE_HOME)
Oracle 10g Instant Client technology is installed at CERN under:
/afs/cern.ch/project/oracle/instantclient
These directories contains all the binaries and libraries that are needed to
build and execute client applications based on SQLPLUS, JDBC, ODBC, OCI and OCCI.
To execute applications against the Instant Client installation relevant to
your operating system, you need to set the two environment variables PATH and
LD_LIBRARY_PATH. For instance, on linux like systems (such as lxplus) and assuming
you are using the sh shell and 10.2.0.4 drivers:
export PATH=/afs/cern.ch/project/oracle/instantclient/10.2.0.4/64bits/instantclient_10_2:${PATH}
export LD_LIBRARY_PATH=
/afs/cern.ch/project/oracle/instantclient/10.2.0.4/64bits/instantclient_10_2:${LD_LIBRARY_PATH}
In addition, the TNS_ADMIN environment variable must also be set to point
to the CERN installation of the tnsnames.ora file (which is the same as when
using the ORACLE_HOME-based Client installation):
export TNS_ADMIN=/afs/cern.ch/project/oracle/admin
Normally, the Linux Support team install by default an rpm with the Instant Client in all the centrally managed machines, so
you should not need to do any set up. For instance, we can see that the sqlplus is located in
lxplus242.cern.ch$locate sqlplus
/usr/bin/sqlplus
/usr/lib64/oracle/10.2.0.3/client/bin/sqlplus
/usr/lib64/oracle/10.2.0.3/client/lib64/libsqlplus.so
/usr/lib64/oracle/10.2.0.3/client/lib64/libsqlplusic.so
Although the Oracle Instant Client will satisfy most of the requirements, not all the Oracle tools are provided with this package.
For instance, the EXPort, IMPort and SQL*Loader are not there. This is a limitation of the current model (as provided by Oracle).
NB. ProC is also supported by instant client > 10.2.0.
For questions about the Oracle deployment from the AFS tree at CERN , please contact:
oracle.support@cern.ch
|