星期四, 9月 29, 2016

FW: 如何在Redhat Linux 5 上面安裝Oracle 9i Database


Oracle 9.2.0.4 real installation guide for RHEL-5 64-BIT
1. Make sure Java libraries are up to date.. (sysad side..)

2. Do not start installation from the 9204 base installation- Oracle Universal Installer has problem

2.1 Install first the OUI "only" from the 9206 patchset (p3948480_9206_Linux-x86-64.zip)
using the Oracle_Home youve just decided

2.2 In ../Disk1/install/oraparam.ini edit the Linux value under [Certified Versions]
Linux=redhat-2.1AS,redhat-2.1,redhat-3,redhat-4,redhat-5,UnitedLinux-1.0,SuSE-9,SuSE-
* value must include redhat-5 inorder to suppress the error message for OS version incompat.

2.3 After completion of OUI install, edit again ../product/9204/oui/oraparam.ini as instructed
in step 2.2

2.4 Now install the 9204 base using the OUI from 9206. Run ../product/9204/oui/runInstaller BUT
this time, select the "products.jar" from 9204 base installation set.
(ex: /u01/app/oracle/Disk1/stage/products.jar)

2.5 From here u should be able to install the SOFTWARE ONLY option. DO NOT create a database yet.
 
3. Patch the 9204 base with the 9207 patchset (p4163445_92070_Linux-x86-64.zip)

3.1 After decompressing contents, repeat step 2.2 again to suppress OS version incompat.

3.2 Now proceed with the patch application
 
4. You can now create a database using the "dbca" utility.

-------
Real Tests
ref:
Please Ref : http://road-to-ocm.blogspot.tw/2012/07/oracle-9204-real-installation-guide-for.html
and
https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/5/pdf/Tuning_and_Optimizing_Red_Hat_Enterprise_Linux_for_Oracle_9i_and_10g_Databases/Red_Hat_Enterprise_Linux-5-Tuning_and_Optimizing_Red_Hat_Enterprise_Linux_for_Oracle_9i_and_10g_Databases-en-US.pdf


vi /etc/grub.conf

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd0,0)
#          kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
#          initrd /initrd-version.img
#boot=/dev/sda
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title Red Hat Enterprise Linux Server (2.6.18-398.el5)
        root (hd0,0)
        kernel /vmlinuz-2.6.18-398.el5 ro root=/dev/VolGroup00/LogVol00 rhgb quiet elevator=deadline
        initrd /initrd-2.6.18-398.el5.img


Tuning the Page Cache
echo "vm.pagecache=40" >> /etc/sysctl.conf
echo "vm.min_free_kbytes=1024" >> /etc/sysctl.conf
echo "vm.swappiness=10" >> /etc/sysctl.conf
echo "kernel.shmmni=4096" >> /etc/sysctl.conf
echo "kernel.shmall=2097152" >> /etc/sysctl.conf
echo "kernel.sem=250 32000 100 128" >> /etc/sysctl.conf
echo "fs.file-max=65536" >> /etc/sysctl.conf
echo "net.core.rmem_default=262144" >> /etc/sysctl.conf
echo "net.core.wmem_default=262144" >> /etc/sysctl.conf
echo "net.core.rmem_max=262144" >> /etc/sysctl.conf
echo "net.core.wmem_max=262144" >> /etc/sysctl.conf
echo "net.ipv4.ip_local_port_range=1024 65000" >> /etc/sysctl.conf

groupadd dba -g 501
mkdir -p /home/oracle
mkdir -p /u01
mkdir -p /u02
useradd -c "Oracle Software Owner" -g dba -u 502 -m -d /home/oracle -s /bin/bash oracle
chown -R oracle:dba /oracle /u01 
chmod -R 755 /u01

vi /home/oracle/.bash_profile

ORACLE_BASE=/u01; export ORACLE_BASE
ORACLE_HOME=/u01/db920 ;export ORACLE_HOME
ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data; export ORA_NLS33
ORACLE_TERM=xterm ;export ORACLE_TERM
PATH=$PATH:$ORACLE_HOME/bin:$ORACLE_HOME/OPatch:$HOME/bin; export PATH
ORACLE_SID=orcl; export ORACLE_SID

#export LD_ASSUME_KERNEL=2.4.19
umask 022

LD_LIBRARY_PATH=$ORACLE_HOME/lib:$ORACLE_HOME/rdbms/lib:/lib64:/lib:/usr/lib64:/usr/lib:/usr/local/lib64:/usr/local/lib:/usr/bin; export LD_LIBRARY_PATH
unset USERNAME

vi /etc/security/limits.conf
oracle           soft    nproc   2047
oracle           hard    nproc   16384
oracle           soft    nofile  1024
oracle           hard    nofile  65536

-Add or edit the following line in the /etc/pam.d/login file            
session     required     pam_limits.so 

-Add the following lines to /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

[root@rhel5 install]# mount /dev/cdrom /mnt

[root@rhel5 install]# head -n1 /mnt/.discinfo
1409145026.642170

vi /etc/yum.repos.d/rhel5.repo
[rhel5-Server] 
mediaid=1409145026.642170
name=RHEL5-Server
baseurl=file:///mnt/Server
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release 
enabled=1 
gpgcheck=1

rpm -qa |egrep 'binutils|compat-db|compat-libstdc++|control-center|gcc|glibc|glibc-common|glibc-devel|ksh|libaio|libgcc|libgnome|libgnomeui|libgomp|libstdc++|libstdc++-devel|libXp|make|sysstat'
|sort

yum install -y binutilsbinutils
yum install -y compat-db
yum install -y compat-libstdc++-33
yum install -y control-center
yum install -y gcc
yum install -y glibc
yum install -y glibc-common
yum install -y glibc-devel
yum install -y ksh
yum install -y libaio
yum install -y libgcc
yum install -y libgnome

yum install -y libgnomeui
yum install -y libgomp
yum install -y libstdc++
yum install -y libstdc++-devel
yum install -y libXp
yum install -y make
yum install -y sysstat

另外需安裝 
libXp-1.0.0-8.i386.rpm  (java plugin required)
sysstat-7.0.2-1.el5.i386.rpm

xhost +

vi /u01/source/Disk1/install/oraparam.ini
Linux=redhat-2.1AS,redhat-2.1,redhat-3,UnitedLinux-1.0,SuSE-9,SuSE-8
->
Linux=redhat-2.1AS,redhat-2.1,redhat-3,redhat-4,redhat-5,UnitedLinux-1.0,SuSE-9,SuSE-8

su - oracle
/u01/source/Disk1/runInstaller  --> Install OUI only

After completion of OUI install, edit again /u01/db920/oui/oraparam.ini as instructed
Linux=redhat-2.1AS,redhat-2.1,redhat-3,UnitedLinux-1.0,SuSE-9,SuSE-8
->
Linux=redhat-2.1AS,redhat-2.1,redhat-3,redhat-4,redhat-5,UnitedLinux-1.0,SuSE-9,SuSE-8


cd /u01/source/Oracle_9i_R2_92040_Database_Linux_x86_64bit
gunzip amd64_db_9204_Disk1.cpio.gz
gunzip amd64_db_9204_Disk2.cpio.gz
gunzip amd64_db_9204_Disk3.cpio.gz

cpio -idcmv < amd64_db_9204_Disk1.cpio
cpio -idcmv < amd64_db_9204_Disk2.cpio
cpio -idcmv < amd64_db_9204_Disk3.cpio

Now install the 9204 base using the OUI from 9206. Run /u01/db920/oui/bin/runInstaller BUT
this time, select the "products.jar" from 9204 base installation set. 
(ex: /u01/source/Oracle_9i_R2_92040_Database_Linux_x86_64bit/Disk1/stage/products.jar)

From here u should be able to install the SOFTWARE ONLY option. DO NOT create a database yet.

#do the following and choose to continue if prompt error
-bash-3.2$  mkdir -p /u01/db920/Apache/Apache/conf
-bash-3.2$ cp /u01/db920/oracle.apache.apache/conf/oracle_apache.conf /u01/db920/Apache/Apache/conf/.
-bash-3.2$ cp /u01/db920/oracle.apache.apache/ports.ini /u01/db920/Apache/Apache/ports.ini
-bash-3.2$ echo "s_jservPort = 7775" >> /u01/db920/oracle.apache.apache/ports.ini 
-bash-3.2$ cp /u01/db920/oracle.apache.apache/ports.ini /u01/db920/oracle.apache/.


Patch the 9204 base with the 9208 patchset

After decompressing contents, repeat edit /u01/source/Disk1/install/oraparam.ini again to suppress OS version incompat.
Linux=redhat-2.1AS,redhat-2.1,redhat-3,UnitedLinux-1.0,SuSE-9,SuSE-8
->
Linux=redhat-2.1AS,redhat-2.1,redhat-3,redhat-4,redhat-5,UnitedLinux-1.0,SuSE-9,SuSE-8

You can now create a database using the "dbca" utility

沒有留言:

LinkWithin-相關文件

Related Posts Plugin for WordPress, Blogger...