oracle 10g 在 redhat 5.1 企业版 安装过程

此篇文章是个人总结,感谢各位前人无私的技术共享。

 

 

step1:检查操作系统环境
#rpm -q gcc make binutils openmotif glibc setarch compat-db compat-gcc-34 openmotif compat-gcc-34-c++ compat-libstdc++-33

gcc-4.1.2-14.el5
make-3.81-1.1
binutils-2.17.50.0.6-5.el5
openmotif-2.3.0-0.3.el5
glibc-2.5-18
setarch-2.0-1.1
compat-db-4.2.52-5.1
compat-gcc-34-3.4.6-4
openmotif-2.3.0-0.3.el5
compat-gcc-34-c++-3.4.6-4
compat-libstdc++-33-3.2.3-61
libXp-1.0.0-8.1.el5

 

 


setp2:检查硬件环境
默认的为
kernel.shmmax = 4294967295
kernel.shmall = 268435456
kernel.shmmni = 4096
vm.hugetlb_shm_group = 0
kernel.sem = 250        32000   32      128
fs.file-max = 191147
net.ipv4.ip_local_port_range = 32768    65000

运行如下命令设置:
cat >> /etc/sysctl.conf <<EOF
>kernel.shmall = 2097152     --------(可以不需要,系统默认值较大)
>kernel.shmmax = 2147483648    --------(可以不需要,系统默认值较大)
>kernel.shmmni = 4096
>kernel.sem = 250 32000 100 128
>fs.file-max = 191147
>net.ipv4.ip_local_port_range = 32768 65000
>net.core.rmem_default = 262144
>net.core.rmem_max = 262144
>net.core.wmem_default = 262144
>net.core.wmem_max = 262144
>EOF
#/sbin/sysctl -p

以 root 用户身份运行以下命令来验证您的设置:
# /sbin/sysctl -a | grep shm
# /sbin/sysctl -a | grep sem
# /sbin/sysctl -a | grep file-max
# /sbin/sysctl -a | grep ip_local_port_range

如果系统的参数设置的比上述参数值小,则编辑 /etc/sysctl.conf 文件,添加或更改这些参数。完成后,运行以下命令激活更改:
/sbin/sysctl -p

 

 


step3:对 ORACLE 用户进行SHELL限制

Oracle 建议对每个 Linux 帐户可以使用的进程数和打开的文件数设置限制。要进行这些更改,以 root 用户的身份执行下列命令:

#cat >> /etc/security/limits.conf <<EOF
>oracle               soft    nproc   2047
>oracle               hard    nproc   16384
>oracle               soft    nofile  1024
>oracle               hard    nofile  65536
>EOF

#cat >> /etc/pam.d/login <<EOF
>session   required   pam_limits.so
>EOF


vi /etc/selinux/config,确认
SELINUX=disable
必须关闭SELINUX.

 

 

 

step 4:设置主机IP以及主机名

# Do not remove the following line, or various programs
# that require network functionality will fail
192.168.18.1  oracletest      oracletest

PS:原来的127.0.0.1需删除

 

 

 

step 5:创建 oracle 用户组与用户名

# groupadd oinstall
# groupadd dba
# useradd -m -g oinstall -G dba oracle
# id oracle
uid=501(oracle) gid=501(oinstall) groups=501(oinstall),502(dba)

 

 


step 6:创建 oracle 目录

# mkdir -p /u01/app/oracle
# mkdir -p /u02/oradata
# chown -R oracle:oinstall /u01/app/oracle /u02/oradata
# chmod -R 775 /u01/app/oracle /u02/oradata

 

 


step 7: 更改LINUX版本号

# vim /etc/redhat-release
Red Hat Enterprise Linux Server release 5.1 (Tikanga) 改成
Red Hat Enterprise Linux Server release 3 (Tikanga)

 

 

 

step 8:更改 oracle 用户环境变量

#su oracle
#cd
#vi .bash_profile
在文件最后加上
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=$ORACLE_BASE/product/10.2; export ORACLE_HOME
ORACLE_SID=myoracle; export ORACLE_SID
ORACLE_TERM=xterm; export ORACLE_TERM
PATH=/usr/sbin:$PATH; export PATH
PATH=$ORACLE_HOME/bin:$PATH; export PATH
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/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 -p 16384
    ulimit -n 65536
  else
    ulimit -u 16384 -n 65536
  fi
fi

再次使用 oracle 登录后,环境变量即生效

 

 

 

step 9:安装 oracle

本机登录
#xhost +oracle
#export DISPLAY=IP:0.0
#startx

然后启动一个终端,执行 ./runInstaller

安装过程中需要执行两个脚本,分别是
#/u01/app/oracle/oraInventory/orainstRoot.sh
#/u01/app/oracle/product/10.2/root.sh

 

 

step10.解决按钮乱码问题
1.修改jdk 下面的字体。
$ cd $ORACLE_HOME/jdk/jre/lib/
$ mv font.properties font.properties_bak
$ cp font.properties.zh_CN.Redhat font.properties
$ vi font.properties
将最后一行
filename.-misc-zysong18030-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/share/fonts/zh_CN/TrueType/zysong.ttf
改为
filename.-misc-zysong18030-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/share/fonts/chinese/TrueType/uming.ttf


2.修改jre 下面的字体
$ cd $ORACLE_HOME/jre/1.4.2/lib
$ mv font.properties font.properties_bak
$ cp font.properties.zh_CN.Redhat font.properties
$ vi font.properties
将最后一行
filename.-misc-zysong18030-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/share/fonts/zh_CN/TrueType/zysong.ttf
改为
filename.-misc-zysong18030-medium-r-normal--*-%d-*-*-c-*-iso10646-1=/usr/share/fonts/chinese/TrueType/uming.ttf

3.清除em的cache,如果你安装完了,还没有运行WEB界面的管理控制器,那么下面这一个步骤则不需要,因为还没有生成这个目录
$ cd $ORACLE_HOME/oc4j/j2ee/oc4j_applications/applications/em/em/cabo/images/cache/zhs
$ rm *.gif

4. 重新启动em
$ emctl stop dbconsole
$ emctl start dbconsole

 

5.同样的,清除isqlplus中的cache

$ cd $ORACLE_HOME/oc4j/j2ee/oc4j_applications/applications/isqlplus/isqlplus/cabo/images/cache/zhs
$ rm *.gif

 

6.重新启动sqlplus

$ isqlplusctl stop
$ isqlplusctl start

即可显示中文按钮

PS:如果没安装中文字体包,则安装光盘中的 fonts-chinese-3.02-12.el5.noarch.rpm

 



 

 

 

这样,ORACLE 10G就已经安装在你机器上啦, enjoy yourself!

 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值