2.
vi /etc/security/limits.conf
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
3.
vi /etc/pam.d/login
session required /lib/security/pam_limits.so
session required pam_limits.so
4.
vi /etc/profile
if [ $USER = "oracle" ]; then
if [ $SHELL = "/bin/ksh" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
fi
5.
cd /home/oracle
vi .bash_profile
ORACLE_BASE=/oracle
ORACLE_HOME=$ORACLE_BASE/10g
ORACLE_SID=wilson
PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_BASE ORACLE_HOME ORACLE_SID PATH
6.安装libXp
yum -y install libXp
7.
vi /etc/redhat-release
将CentOS release 5 (Final) 修改成redhat 4
六.用oracle用户进入linux
进入终端
sh /ORACLE的目录/runInstaller
正常安装就可以,关于权限的错误可以忽略
七.安装后运行
由于安装后ORACLE不可以自动启动,需要手动启动ORACLE,方法有2种。
1.手动启动
su - oracle
export ORACLE_HOME=/oracle安装目录
export ORACLE_SID=sid名字
sqlpuls /nolog
出现
sql> conn sys/密码 as sysdba
sql> startup
sql> exit
cd /oracle目录/bin
./lsnrctl start
应该不会报错了,这下ORACLE就应该完全启动起来了。
2.自动启动,有时候会出问题,不知道怎么回事
第2种需要添加脚本(修改红色部分就可以了)
cd /etc/init.d/
touch oracle
vi oracle
写入:
#!/bin/bash
#
# chkconfig: 2345 80 05
# description: Oracle 10g Server
# /etc/init.d/dbora
#
# Run-level Startup script for the Oracle Instance, Listener, and
# Web Interface
# if the executables do not exist -- display error
if [ ! -f $ORACLE_HOME/bin/dbstart -o ! -d $ORACLE_HOME ]
then
echo "Oracle startup: cannot start"
exit 1
fi
# depending on parameter -- startup, shutdown, restart
# of the instance and listener or usage display
case "$1" in
start)
# Oracle listener and instance startup
echo -n "Starting Oracle: "
# su $ORA_OWNR -c "$ORACLE_HOME/bin/lsnrctl start"
su $ORA_OWNR -c $ORACLE_HOME/bin/dbstart
touch /var/lock/oracle
su $ORA_OWNR -c "$ORACLE_HOME/bin/emctl start dbconsole"
echo "OK"
;;
stop)
# Oracle listener and instance shutdown
echo -n "Shutdown Oracle: "
# su $ORA_OWNR -c "$ORACLE_HOME/bin/lsnrctl stop"
su $ORA_OWNR -c $ORACLE_HOME/bin/dbshut
rm -f /var/lock/oracle