During the Oracle Installation Process today, the entire process was relatively smooth with reference to the information downloaded from the Internet to install oracle on RHEL5, but encountered some problems, although not very serious, however, after all, it is a problem and still uncomfortable. Please solve it here.
The main problem is the environment variables of oracle users. One step during oracle installation is to log on as an oracle user and edit the. bash_profile file. The edited content is as follows.
. Bash_profile file content:
- #. Bash_profile
-
- # Get the aliases and functions
- If[-F ~ /. Bashrc]; then
- .~ /. Bashrc
- Fi
-
- # User specific environment and startup programs
-
- PATH = $ PATH: $ HOME/bin
-
- TMP =/tmp; export TMP
- TMPDIR = $ TMP; export TMPDIR
-
- ORACLE_BASE =/opt/oracle; export ORACLE_BASE
- ORACLE_HOME = $ ORACLE_BASE/10.2; Export ORACLE_HOME
- ORACLE_SID = TSH1; export ORACLE_SID
- ORACLE_TERM = xterm; export ORACLE_TERM
- PATH = $ ORACLE_HOME/bin: $ PATH
-
- Export PATH
-
- LD_LIBRARY_PATH = $ ORACLE_HOME/lib:/usr/lib; export LD_LIBRARY_PATH
- CLASSPATH = $ ORACLE_HOME/JRE: $ ORACLE_HOME/jlib: $ ORACLE_HOME/rdbms/jlib; export CLASSPATH
-
- If[$ USER ="Oracle"]; Then
- If[$ SHELL ="/Bin/ksh"]; Then
- Ulimit-p16384
- Ulimit-n65536
- Else
- Ulimit-u16384-N65536
- Fi
- Fi
When I log on as an oracle user, the following error is prompted:
Error message:
- -Bash:/home/oracle/. bash_profile: line26: Syntax error near unexpected token 'then'
- -Bash:/home/oracle/. bash_profile: line26:'If[$ USER ="Oracle"]; Then'
I checked a lot of information and wrote it like this. I also checked the shell programming materials and didn't see any problems. Please take a look.