oracle10g for linux 安装

 
一、 Oracle 10g 10.2.0.1.zip 可以从官方网站下载。 (1CD, 下载后做下 checksum) 下载后是压缩文档,可以
unzip 解压缩。
二、 CentOS4.2 安装过程中,选择全部安装。
另外还需要确认以下补丁包 :
compat-db-4.1.25-9
compat-gcc-32-3.2.3-47.3
compat-gcc-32-c++-3.2.3-47.3
compat-oracle-rhel4-1.0-3
compat-libcwait-2.0-1
compat-libgcc-296-2.96-132.7.2
compat-libstdc++-296-2.96-132.7.2
compat-libstdc++-33-3.2.3-47.3
gcc-3.4.3-9.EL4
gcc-c++-3.4.3-9.EL4
gnome-libs-1.4.1.2.90-44
gnome-libs-devel-1.4.1.2.90-44
libaio-devel-0.3.102-1
libaio-0.3.102-1
make-3.80-5
openmotif21-2.1.30-11
其中 compat-oracle-rhel4 compat-libcwait 可以在如下网站 :
http://oss.oracle.com/projects/compat-oracle/files/RedHat/ 下载
检查是否符合 oracle 10g 的安装要求,以表格的形式列出。首先是硬件情况。 启动 x-win32以root登录系
用下表命令输出的值大于或等于建议值。

检查项目                 命令 / 方法                                      建议值
内存                       #grep MemTotal  /proc/meminfo      512MB
交换分区                #grep SwapTotal  /proc/meminfo     >1GB
/tmp 目录空闲区      #df -k /tmp                                     400MB
硬盘空闲空间         #df -k                                            4GB
三、设置系统参数
在root 用户下
a) 修改 #vi /etc/sysctl.conf, 与以下内容一致
# Kernel sysctl configuration file for Red Hat Linux
#
# For binary values, 0 is disabled, 1 is enabled.  See sysctl(  and
# sysctl.conf(5) for more details.

# Controls IP packet forwarding
net.ipv4.ip_forward = 0

# Controls source route verification
net.ipv4.conf.default.rp_filter = 1

# Controls the System Request debugging functionality of the kernel
kernel.sysrq = 0

# Controls whether core dumps will append the PID to the core filename.
# Useful for debugging multi-threaded applications.
kernel.core_uses_pid = 1
kernel.shmmax = 536870912 / 268435456
kernel.shmmni = 4096
kernel.shmall = 2097152
kernel.sem = 250 32000 100 128
net.core.rmem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_max = 262144

fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
修改后运行 #/sbin/sysctl -p 命令使得内核改变立即生效;或者重启系统。
四,创建数据库安装的准备工作;
1 ,创建 user和group
#groupadd dba
#groupadd oinstall
#groupadd oper
#useradd -g oinstall -G dba oracle
#passwd oracle
2 ,建立 oracle 安装文件夹;
#mkdir -p /usr/u01/app/oracle
#chown -R oracle:dba /usr/u01/app/oracle
#chmod -R 755 /usr/u01/app/oracle
#mkdir -p /usr/u01/app/oracle/product/10.2.0.1
#chown -R oracle:dba /usr/u01/app/oracle/product/10.2.0.1
#chmod -R 755 /usr/u01/app/oracle/product/10.2.0.1
2 配置环境变量;
切换 Oracle 用户 :
#su oracle
#vi $HOME/.bashrc
配置文件的内容与以下内容一致
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:HOME/bin
export ORACLE_BASE=/usr/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/10.2.0.1
export PATH=$PATH:$ORACLE_HOME/bin:$ORACLE_HOME/Apache/Apache/bin
export ORACLE_OWNER=oracle
export ORACLE_SID=test
export ORACLE_TERM=xterm
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:ORACLE_HOME/lib
export NLS_LANG=”American_america.zhs16gbk”
export ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data
unset USERNAME
umask 022
存盘退出。

五.数据库系统的安装
oracle 用户登录系统,进行 Oracle 的安装
#su oracle
到oracle解压缩目录下
运行 #./runInstaller
一步一个脚印安装下去就行了!
. 安装完成后的测试
[oracle@oracle oracle]$ lsnrctl start
[oracle@oracle oracle]$ sqlplus /nolog
SQL*Plus: Release 10.2.0.1.0 - Production on Sat Mar 12 22:58:53 2005
Copyright (c) 1982, 2004, Oracle Corporation.  All rights reserved.
SQL> connect / as sysdba
Connected.
SQL>; shutdown immediate   关闭数据库
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>startup;    启动数据库
ORACLE instance started.
Total System Global Area  236000356 bytes
Fixed Size                   451684 bytes
Variable Size             201326592 bytes
Database Buffers           33554432 bytes
Redo Buffers                 667648 bytes
Database mounted.
Database opened.
 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值