Home > Database > Mysql Tutorial > CentOS 5.4 64位安装Oracle 10G

CentOS 5.4 64位安装Oracle 10G

WBOY
Release: 2016-06-07 17:00:09
Original
1014 people have browsed it

#grep SwapTotal /proc/meminfo2 g

一、检查硬件
查看内存和交换空间以及磁盘大小命令:#grep MemTotal /proc/meminfo"

#grep SwapTotal /proc/meminfo2 g' ]. Q8 O( A# E
#df -h8 l! b% k  s' D; c6 R
#df -k /tmp
8 A; k5 f. k  j( q% q8 T要求:所需最小内存为256MB,而所需最小交换空间为512M。对于内存小于或等于2GB 的系统,,交换空间应为内存的两倍;对于内存大于2GB 的系统,交换空间应为内存的一到两倍。安装Oracle 10g软件需要2.5GB 的可用磁盘空间,而数据库则另需1.2GB的可用磁盘空间。/tmp 目录至少需要 400MB的可用空间。
二、验证Linux安装  t# n6 ~* i- r
1. 检查内核版本:#uname -r8 t/ m: {% ~1 h$ \% E( j
所需版本:2.6.9-5.EL(为官方RHEL 4.0的要求)5 ^# g" X# C' a5 ~
2. 检查所需软件包:#rpm -q package-name
所需包及其版本:
binutis-2.15.92.0.2-13.EL4
Ecompat-db-4.1.25-9' L, ]' p) K$ J* x
compat-libstdc++-296-2.96-132.7.2
control-center-2.8.0-12
gcc-3.4.3-22.1.EL4
gcc-c++-3.4.3-22.1.EL44. l- K1 \1 Q$ u) {5 Z
glibc-2.3.4-2.9
glibc-common-2.3.4-2.9
gnome-libs-1.4.1.2.90-44.1
libstdc++-3.4.3-22.1
libstdc++-devel-3.4.3-22.1

make-3.80-5
pdksh-5.2.14-30
sysstat-5.0.5-19 P% |- U, I, K! m! z
xscreensaver-4.18-5.rhel4.2" C5 s' W( V7 @+ c$ c; ?; n
setarch-1.6-1

如果有软件包未安装,插入Linux系统安装光盘,使用以下方法安装
rpm -ivh package-name-major-version*
例如:#rpm -Uvh compat-db-4*
创建 Oracle 组和用户帐户

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

设置 oracle 帐户的口令:

passwd oracle创建目录以 root 用户身份执行以下命令: mkdir -p /oracle
chown -R oracle:dba /oracle
chmod -R 775 /oracle配置 Linux 内核参数 给出的值都为最小值,因此如果您的系统使用一个更大的值,则不要进行更改。Linux 允许在系统启动并运行时修改大多数内核参数,所以无需在修改内核参数后重启系统。 kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default=4194304
net.core.wmem_default=262144
net.core.rmem_max=4194304
net.core.wmem_max=262144
注意,OEL 5 已经为 kernel.shmall 和 kernel.shmmax 定义了值。如果默认值等于或大于要求值,则使用默认值。使参数生效/sbin/sysctl -p
设置环境变量export PATH
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
ORACLE_BASE=/oracle; export ORACLE_BASE
ORACLE_HOME=$ORACLE_BASE/product/10.2.0.1/db_1; export ORACLE_HOME
ORACLE_SID=db1; 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
安装oracleunzip linux.x64_11gR1_database.zip# sh ./runInstaller -ignoreSysPrereqs
错误:Exception :java.lang.UnsatisfiedLinkError这个错误是也是由于缺少系统安装包造成的,只需安装XFree86-libs包即可,这个安装包可以在系统光盘中找到。: y+ P: |) n9 z1 s: u' z% `
在上面两个错误如果出现在RedHat as5版本中,解决如下:
在RHEL5中上面的包被libXp所取代了,因此rpm -ivh libXp-1.0.0-8.i386.rpm将包打上后问题即可解决。cat >> /home/oracle/raw.conf system=/opt/oracle/oradata/system01.dbf
sysaux=/opt/oracle/oradata/sysaux01.dbf
undotbs1=/opt/oracle/oradata/undotbs01.dbf
redo1_1=/opt/oracle/oradata/redo01.dbf
redo1_2=/opt/oracle/oradata/redo02.dbf
control1=/opt/oracle/oradata/control01.ctl
control2=/opt/oracle/oradata/control02.ctl
temp=/opt/oracle/oradata/temp01.dbf
users=/opt/oracle/oradata/users01.dbf
spfile=/opt/oracle/oradata/spfileora10.ora
orapwd=/opt/oracle/oradata/orapwdora10
EOFln -s /dev/raw/raw1  /oradata/system01.dbf
ln -s /dev/raw/raw2  /oradata/sysaux01.dbf
ln -s /dev/raw/raw3  /oradata/undotbs01.dbf
ln -s /dev/raw/raw4  /oradata/redo01.dbf
ln -s /dev/raw/raw5  /oradata/redo02.dbf
ln -s /dev/raw/raw6  /oradata/control01.ctl
ln -s /dev/raw/raw7  /oradata/control02.ctl
ln -s /dev/raw/raw8  /oradata/temp01.dbf
ln -s /dev/raw/raw9  /oradata/spfileora10.ora
ln -s /dev/raw/raw10 /oradata/orapwdora10
ln -s /dev/raw/raw11 /oradata/users01.dbf

linux

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template