Overview
In Oracle Database files and programs, a question mark (?) represents the value of the ORACLE_HOME environment variable.
the @ sign represents the ORACLE_SID environment variable
Environment Variables
To display the current value of an environment variable,
$ env | more
NLS_LANG
Specifies the language, territory, and character set of the client environment
language_territory.characterset
ORA_NLS10
Specifies the directory where language, territory, character set, and linguistic definition files are stored.
$ORACLE_HOME/nls/data
ORA_TZFILE
Specifies the full path and file name of the time zone file
$ORACLE_HOME/oracore/zoneinfo/timezlrg.dat >>>> DEFAULT
ORACLE_BASE
Specifies the base of the Oracle directory structure for Optimal Flexible Architecture (OFA) compliant installations
/u01/app/oracle
ORACLE_HOME
Specifies the directory containing the Oracle software.
$ORACLE_BASE/product/10.1.0
ORACLE_PATH
/u01/app/oracle/product/10.1.0/bin:.
ORACLE_SID
Specifies the Oracle system identifier
ORCL
ORACLE_TRACE
Enables the tracing of shell scripts during an installation
ORAENV_ASK
Controls whether the oraenv or coraenv script prompts for the value of the ORACLE_SID environment variable.
Value : NO or Any others.
SQLPATH
Specifies the directory or list of directories that SQL*Plus searches for a login.sql file.
/home:/home/oracle:/u01/oracle
TNS_ADMIN
Specifies the directory containing the Oracle Net Services configuration files
$ORACLE_HOME/network/admin
TWO_TASK
Specifies the default connect identifier to use in the connect string
Any connect identifier
UNIX Environment Variables
ADA_PATH (AIX only)
Specifies the directory containing the Ada compiler
/usr/lpp/powerada
CLASSPATH
Used with Java applications
There is no default setting. CLASSPATH must include the following directories:
$ORACLE_HOME/JRE/lib:$ORACLE_HOME/jlib
DISPLAY
Used by X-based tools. Specifies the display device used for input and output.
hostname:server[.screen]
where the hostname is the system name (either IP address or alias), server is the sequential code number for the server, and screen is the sequential code number for the screen. If you have a single monitor, use the value 0 for both server and screen (0.0).
Note: If you have a single monitor, screen is optional.
Example 135.287.222.12:0.0 bambi:0
HOME
The user’s home directory
/home/oracle
PATH
Used by the shell to locate executable programs; must include the $ORACLE_HOME/bin directory.
[oracle@alwarid-taj ~]$ echo $PATH
/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/oracle/bin
Setting a Common Environment
set a common operating system environment by using the oraenv or coraenv scripts
1.For the Bourne, Bash, or Korn shell, use the oraenv command.
2.For the C shell, use the coraenv command.
The oraenv and coraenv scripts are created during installation. These scripts set environment variables based on the contents of the oratab file and provide:
Note:
Do not call the oraenv or coraenv script from the Oracle software owner (typically oracle) user's shell startup script. Because these scripts prompt for values, they can prevent the dbstart script from starting a database automatically when the system starts.
The oraenv or coraenv script is usually called from the user's shell startup file (for example .profile or.login). It sets the ORACLE_SID and ORACLE_HOME environment variables and includes the $ORACLE_HOME/bin directory in the PATH environment variable setting.
When switching between databases, users can run the oraenv or coraenv script to set these environment variables.
[oracle@alwarid-taj /]$ su - root
Password:
[root@alwarid-taj ~]# . /usr/local/bin/oraenv
ORACLE_SID = [root] ? oracle
[root@alwarid-taj ~]#
Local bin Directory
1.When you run the root.sh script after installation, the script prompts you for the path of the local bin directory and automatically copies the oraenv, coraenv, and dbhome scripts to the directory that you specify. The default local bin directory is /usr/local/bin.
2.If you do not run the root.sh script, then you can manually copy the oraenv or coraenv and dbhome scripts from the $ORACLE_HOME/bin directory to the local bin directory.
The oraenv or coraenv script is usually called from the user's shell startup file (for example .profile or.login).
No comments:
Post a Comment