RedHat5.2下Linux Oracle 10g ASM 安装详细实录-第一篇-环境准备

一、硬件环境检查

1 、至少 1G 内存
   # grep MemTotal /proc/meminfo
2 、交换空间设置
   # grep SwapTotal /proc/meminfo
# free

RAM
Swap Space
Up to 512 MB
2 times the size of RAM
Between 1024 MB and 2048 MB
1.5 times the size of RAM
Between 2049 MB and 8192 MB
Equal to the size of RAM
More than 8192 MB
0.75 times the size of RAM
 
3 /tmp 目录需要 400 MB 以上空间
   # df -k /tmp
4 、根据安装类型不同需要为安装目录准备 1.5 GB-3.5 GB 空闲空间
   # grep "model name" /proc/cpuinfo
 
二、系统环境检查
1 LINUX 版本查询
# cat /proc/version
 
2 、内核查询
# uname –r
 
3 RPM 包查询安装
# rpm -q package_name
 
注:通过LINUX安装光盘的/media/cdrom/Server目录找RPM包,网上找的容易出问题,如果说远程安装,不具备光驱条件,则你本地采用虚拟光驱提取响应文件后传到远程服务器上。
# rpm -Uvh setarch-2*
# rpm -Uvh make-3*
# rpm -Uvh glibc-2*
# rpm -Uvh libaio-0*
# rpm -Uvh compat-libstdc++-33-3*
# rpm -Uvh compat-gcc-34-3*
# rpm -Uvh compat-gcc-34-c++-3*
# rpm -Uvh gcc-4*
# rpm -Uvh libXp-1*
# rpm -Uvh openmotif-2*
# rpm -Uvh compat-db-4*
 
4 Verify that the /etc/hosts file is used for name resolution. You can do this by
checking the hosts file entry in the nsswitch.conf file as follows:
# cat /etc/nsswitch.conf | grep hosts
The output of this command should contain an entry for files.
 
5 Verify that the host name has been set by using the hostname command as follows:
# hostname
The output of this command should be similar to the following:
myhost.mycomputer.com
 
6 Verify that the domain name has not been set dynamically by using the
domainname command as follows:
# domainname
This command should not return any results.
 
 
三、环境配置
1 、修改 /etc/redhat-release 文件,因为 Oracle 数据库暂不支持 RHEL5
# vi /etc/redhat-release
# Red Hat Enterprise Linux Server release 5.2 (Tikanga)
redhat-4
 
2 Oracle 数据库必须在 Oracle 用户下才能安装,因此需建立相应的用户群组、用户,以及设置相应的目录属主、目录权限以及 Oracle 用户设置密码
# groupadd oinstall
# groupadd dba
# useradd -g oinstall -G dba oracle
# mkdir -p /home/oracle
# chown -R oracle.oinstall /home/oracle
# chmod -R 775 /home/oracle
# passwd oracle
 
3 、配置内核相关参数,以便支持 Oracle 数据库
# vi /etc/sysctl.conf
# For Oracle 
kernel.shmall=2097152
kernel.shmmax=2147483648
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=262144 net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_max = 262144
注:如果没有相应的参数则添加之;若相应参数值较给出的值大,勿需修改!
 
4 、设置 Oracle 用户 Shell limit (可不设)
# vi /etc/security/limits.conf
# For Oracle 
oracle         soft          nproc         2047
oracle         hard          nproc         16384
oracle         soft          nofile        1024
oracle         hard          nofile        65536
 
5 、在 /etc/pam.d/login file 文件末端添加相关内容(已经存在则退出)
# vi /etc/pam.d/login
Session             required            /lib/security/pam_limits.so
 
6 、修改 /etc/hosts 文件,将 127.0.0.1 修改成为你服务器的实际 IP 地址,否则可能导致安装 Oracle 的时候,检查网络配置将出现异常
# vi /etc/hosts
#127.0.0.1             localhost.localdomain        localhost
**.**.**.**            localhost.localdomain        localhost
示例:
172.16.3.6    L-DB-3-6 localhost.localdomain localhost
::1              localhost6.localdomain6 localhost6
~                                                  
7 、注销 root 用户,以 oracle 用户登录系统(可 root su - oracle
8 、配置 Oracle 用户环境变量
$ vi ~/.bash_profile
export ORACLE_BASE=/home/oracle
export ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
export ORACLE_SID=zjport
export ORACLE_TERM=xterm
export PATH=$PATH:$HOME/bin:$ORACLE_HOME/bin;
export NLS_LANG="SIMPLIFIED CHINESE_CHINA.ZHS16GBK"
export NLS_DATE_FORMAT='yyyy-mm-dd hh24:mi:ss'
export CLASSPATH=$CLASSPATH:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib:$ORACLE_HOME/network/jlib
export TNS_ADMIN=$ORACLE_HOME/network/admin
export LANG=en_US.utf8
~                      
四、准备数据库介质
1 、下载介质(需要注册 ORACLE 帐户)
示例:
 
2 、解压 CPIO 介质文件
$ gunzip 10201_database_linux_x86_64.cpio.gz
--这样文件就解压成为 "文件名.cpio" 了,然后再对它进行cpio操作
$ cpio –idmv <10201_database_linux_x86_64.cpio
--这样就将cpio文件彻底暴露在我们面前了
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值