码迷,mamicode.com
首页 > 数据库 > 详细

Deploy Oracle 10.2.0.5 on Red Hat Enterprise Linux 6.4

时间:2014-07-29 14:18:48      阅读:412      评论:0      收藏:0      [点我收藏+]

标签:oracle   10g   rhel 6.4   link   linux   

一、Linux系统安装配置


1.安装系统时选Desktop


2.设置eth0网卡为静态IP,添加子网掩码,网关,DNS,并配置自动启动


3.修改/etc/hosts,添加主机名和对应IP


4.禁用firewall和selinux
chkconfig iptables off
vi /etc/selinux/config
SELINUX=disabled

[root@10dg1 selinux]# setenforce 0
[root@10dg1 selinux]# getenforce
Permissive


5.配置本地yum源
mkdir  /media/disk -p
mount -t iso9660 /dev/cdrom /media/disk

mount: block device /dev/sr0 is write-protected, mounting read-only


touch /etc/yum.repos.d/public-yum-rhel6.repo
vi /etc/yum.repos.d/public-yum-rhel6.repo

[rhel6]
name = Red Hat Enterprise Linux 6.4 DVD
baseurl=file:///media/disk/Server/
gpgcheck=0
enabled=1


6.安装Oracle所需要的包
 yum install glibc.i686
 yum install glibc-devel.i686
 yum install libXp.i686
 yum install libXt.i686
 yum install libXtst.i686
 yum install libstdc++.i686
 yum install libstdc++-devel.i686
 yum install compat-libstdc++-296.i686
 yum install compat-libstdc++-33.i686
 yum install compat-gcc-34  #这个没有i686的包,默认会装X86_64
 yum install gcc  #这个没有i686的包,默认会装X86_64
 yum install oracle-rdbms-server-11gR2-preinstall #只有OEL6才有这个包,装完会自动配置oracle的安装环境,方便


装完以后检查一遍

[root@10dg1 disk]# rpm -qa glibc glibc-devel libXp libXt libXtst libstdc++ libstdc++-devel compat-libstdc++-296 compat-libstdc++-33 compat-gcc-34 gcc
gcc-4.4.7-3.el6.x86_64
libXp-1.0.0-15.1.el6.i686
libstdc++-4.4.7-3.el6.i686
libXt-1.1.3-1.el6.x86_64
libstdc++-4.4.7-3.el6.x86_64
glibc-devel-2.12-1.107.el6.i686
compat-libstdc++-33-3.2.3-69.el6.i686
libXtst-1.2.1-2.el6.x86_64
glibc-2.12-1.107.el6.x86_64
glibc-2.12-1.107.el6.i686
libXtst-1.2.1-2.el6.i686
compat-libstdc++-296-2.96-144.el6.i686
libstdc++-devel-4.4.7-3.el6.i686
libXt-1.1.3-1.el6.i686
compat-gcc-34-3.4.6-19.el6.x86_64
glibc-devel-2.12-1.107.el6.x86_64


7.添加用户和组
groupadd oinstall 501
groupadd dba 502
useradd -g oinstall -G dba oracle
password oracle


8.创建目录并赋予权限
mkdir -p /u01/app/oracle/product/10.2.0/db_1
chown -R oracle:oinstall /u01
chmod -R 755 /u01/app/oracle 或者 chmod -R ug=rx,o=rwx


9.配置内核参数
vi /etc/sysctl.conf
#for oracle install
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni =4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 1024 65500
net.core.rmem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_max = 262144
使更改生效
/sbin/sysctl -p


注:一般为内存的0.7倍,OLTP系统SGA+PGA<(Total Memory)*0.8,SGA<(Total Memory)*0.8*0.8


10.设置shell中文件数和进程数的限制
vi /etc/security/limits.conf
#for oracle install
oracle              soft    nproc   2047
oracle              hard    nproc   16384
oracle              soft    nofile  1024
oracle              hard    nofile  65536


11.添加登录用户对资源的限制
vi /etc/pam.d/login
#for oracle install
session required/lib/security/pam_limits.so
session requiredpam_limits.so


12.添加oracle环境变量
su - oracle
vi ~/home/oracle/.bash_profile
PATH=$PATH:$HOME/bin


export PATH


export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
export ORACLE_SID=zlm
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH
export PATH=$PATH:$ORACLE_HOME/bin


#umask 022
#alias sqlplus=‘rlwrap sqlplus‘
#alias rman=‘rlwrap rman‘
stty erase ^


source ~/.bash_profile或. ~/.bash_profile


二、数据库安装


1.安装10.2.0.1数据库软件
使用Xmanage的shell组件连接服务器
su - oracle
cpio -idvm < 10201_database_linux_x86_64.cpio 
unzip p8202632_10205_Linux-x86-64.zip 

cd database/
./runInstaller  -ignoreSysPrereqs #RHEL6.4忽略该参数也可以进入图形化界面,无需修改/etc/redhat-release为低版本,改成5反而进不去安装界面了

bubuko.com,布布扣


由于10.2.0.1 并不认证Linux 6 所以编译过程中会提示ins_ctx.mk,ins_rdbms.mk,ins_emdb.mk,ins_net_client.mk等文件无法link,直接点击continue继续,到10.2.0.5升级时保证升级的LINK全部顺利通过即可,最后依次执行2个脚本完成安装


2.升级数据库软件PSR到10.2.0.5
cd /Disk
./runInstaller
会提示一个包没有装的错误
OUI-11108:  Packages information not specified.
vi /etc/redhat-release
Red Hat Enterprise Linux Server release 6.4 (Santiago) -> Red Hat Enterprise Linux Server release4 (Santiago)
把6.4改成4以后,OUI-11108错误消失


官方RHEL5所需安装的包

rpm -q --qf ‘%{NAME}-%{VERSION}-%{RELEASE}  (%{ARCH})\n‘ binutils compat-libstdc++-33 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc-common glibc-devel glibc-headers libaio libaio-devel libgcc libstdc++ libstdc++-devel make sysstat unixODBC unixODBC-devel



重新安装一遍所有需要的包

yum -y install binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-develglibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devellibaio-devel.i686 libgcclibgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat 


在装10.2.0.5 PSR时,依然会报link错误,由于
之前用yum install glibc安装,系统默认给装了glibc-devel.X86_64的了,而64 bit oracle需要的是glibc-devel.i686,难怪一直报link错误,装完该包以后,之前的link错误不再重现


3.netca创建监听,dbca建库


Deploy Oracle 10.2.0.5 on Red Hat Enterprise Linux 6.4,布布扣,bubuko.com

Deploy Oracle 10.2.0.5 on Red Hat Enterprise Linux 6.4

标签:oracle   10g   rhel 6.4   link   linux   

原文地址:http://blog.csdn.net/aaron8219/article/details/38239065

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!