User`s guide

Oracle Database Environment Definition File
Architecture and Implementation 2-7
2.5.2 Oracle Environment Variables
Appendix B, "Oracle Environment Variables" contains a list of Oracle environment
variables that the database administrator can use. Most users only need to set a few of
these
variables. Any DBA-specific variables that are placed in a user's
ORAENV
file are
ignored.
2.5.3 Running ORAENV
To set environment variables, simply run a
CALL-PROCEDURE
command on the
ORAENV
file containing the environment variables for the database you want to use. The name
of the
ORAENV
file is
sid.P.ORAENV
(where
sid
is the database system identifier). For
example, to set the environment variables for database DEMO using the example
ORAENV
file, run the following command:
/CALL-PROCEDURE DEMO.P.ORAENV
You can also generate an
ORAENV
file and run the
/SET-FILE-LINK
command before
calling any Oracle Database program:
/SET-FILE-LINK ORAENV, filename
where
filename
is the name of a file having the same format as
DEMO.P.ORAENV
and
which defines at least the
ORASID
environment variable.
Note:
The database administrator should not modify the
ORAENV
file
while the Oracle Database is running.
Users may modify their
ORAENV
file at any time.
You can run several Oracle Databases simultaneously on your BS2000 system; even
wi
thin the same Database Administrator account. A unique system identifier provides
a globally unique name for the database so that a user can select a particular database
by setting the
ORASID
environment variable. The user does this by activating the
ORAENV
file
sid.P.ORAENV
.
Whenever an Oracle Database product (for exa
mple, SQL*Plus) is started, it checks if
the link name
ORAENV
is defined and reads the related file, storing the variable
assignments for later use. If no link name
ORAENV
is set (or the related file cannot be
read), then the
SID
remains undefined. Oracle recommends that a link name
ORAENV
is
always defined prior to a call to an Oracle Database program.
2.5.4 POSIX Environment and ORAENV File
Every Oracle Database utility and product running in the POSIX shell get the
environment variables from the POSIX environment. All Oracle and BS2000-specific
variables can be set in the POSIX environment. The Oracle variable
ORACLE_HOME
, must
be set. To run the utility for a particular database, you must also set the Oracle variable
ORACLE_SID
. The operating system environment variable
PATH
must be extended by the
path to the Oracle binaries
$ORACLE_HOME/bin
. If you do not set any other Oracle
variable in the POSIX environment, then the Oracle utilities use default values.The
installation procedure creates a profile in the
ORACLE_HOME
directory which can be
executed to set and expand the most important variables like
ORACLE_HOME
,
PATH
or
LD_
LIBRARY_PATH
. You can process this profile with the command:
$ . your_oracle_home/.profile.oracle