[TOC]
Install Oracle 12cR2 on RHEL6
系统信息
Red Hat Enterprise Linux Server release 6.5
IP |
HOSTNAME |
192.168.56.10 |
oel12c |
/etc/hosts 文件
1 2
| vi /etc/hosts 192.168.56.10 oel12c
|
/etc/sysctl.conf
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
| fs.file-max = 6815744 kernel.sem = 250 32000 100 128 kernel.shmmni = 4096 kernel.shmall = 1073741824 kernel.shmmax = 4398046511104 kernel.panic_on_oops = 1 net.core.rmem_default = 262144 net.core.rmem_max = 4194304 net.core.wmem_default = 262144 net.core.wmem_max = 1048576 net.ipv4.conf.all.rp_filter = 2 net.ipv4.conf.default.rp_filter = 2 fs.aio-max-nr = 1048576 net.ipv4.ip_local_port_range = 9000 65500 /sbin/sysctl -p
|
/etc/security/limits.conf
1 2 3 4 5 6 7 8
| oracle soft nofile 1024 oracle hard nofile 65536 oracle soft nproc 16384 oracle hard nproc 16384 oracle soft stack 10240 oracle hard stack 32768 oracle hard memlock 134217728 oracle soft memlock 134217728
|
依赖包
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41
| yum install binutils -y yum install compat-libcap1 -y yum install compat-libstdc++-33 -y yum install compat-libstdc++-33.i686 -y yum install glibc -y yum install glibc.i686 -y yum install glibc-devel -y yum install glibc-devel.i686 -y yum install ksh -y yum install libaio -y yum install libaio.i686 -y yum install libaio-devel -y yum install libaio-devel.i686 -y yum install libX11 -y yum install libX11.i686 -y yum install libXau -y yum install libXau.i686 -y yum install libXi -y yum install libXi.i686 -y yum install libXtst -y yum install libXtst.i686 -y yum install libgcc -y yum install libgcc.i686 -y yum install libstdc++ -y yum install libstdc++.i686 -y yum install libstdc++-devel -y yum install libstdc++-devel.i686 -y yum install libxcb -y yum install libxcb.i686 -y yum install make -y yum install nfs-utils -y yum install net-tools -y yum install smartmontools -y yum install sysstat -y yum install unixODBC -y yum install unixODBC-devel -y yum install e2fsprogs -y yum install e2fsprogs-libs -y yum install libs -y yum install libxcb.i686 -y yum install libxcb -y
|
关闭防火墙
1 2
| chkconfig iptables off service iptables stop
|
禁用selinux
1 2 3
| vi /etc/selinux/config SELINUX=disabled setenforce 0
|
创建用户组及用户
1 2 3 4 5
| groupadd -g 54321 oinstall groupadd -g 54322 dba groupadd -g 54323 oper useradd -u 54321 -g oinstall -G dba,oper oracle passwd oracle
|
创建目录
1 2 3
| mkdir -p /u01/app/oracle/product/12.2.0.1/db_1 chown -R oracle:oinstall /u01 chmod -R 775 /u01
|
oracle 用户环境配置
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
| vi ~/.bash_profile
# Set Oracle Environment ORACLE_BASE=/u01/app/oracle;export ORACLE_BASE ORACLE_HOME=$ORACLE_BASE/product/12.2.0.1/db_1; export ORACLE_HOME ORACLE_SID=enmo;export ORACLE_SID ORACLE_OWNER=oracle;export ORACLE_OWNER ORACLE_TERM=vt100;export ORACLE_TERM LD_LIBRARY_PATH=$ORACLE_HOME/lib;export LD_LIBRARY_PATH PS1=`hostname`'<$PWD>$';export PS1 EDITOR=/bin/vi; export EDITOR JAVA_HOME=/usr/local/java;export JAVA_HOME ORA_NLS33=/u01/product/oracle/ocommon/nls/admin/data;export ORA_NLS33 CLASSPATH=/u01/product/oracle/jdbc/lib/classesl11.zip:/usr/local/java; PATH=$ORACLE_HOME/bin:$JAVA_HOME/bin:$ORACLE_HOME/OPatch:$PATH:.;export PATH
|
软件包准备
Download Software
OTN: Oracle Database 12c Release 2 (12.2.0.1) Software (64-bit).
linuxx6412201database.zip
Unzip the file.
1
| unzip linuxx64_12201_database.zip
|
图形界面安装oracle 12R2 数据库软件
./runInstaller 启动图形安装界面
配置安全更新
只安装数据库软件
安装单实例数据库软件
root 用户运行脚本
netca 创建监听
dbca 建库
dbca建库完成
原文作者:
liups.com
原文链接:
http://liups.cn/posts/5406f2dc/
许可协议: 知识共享署名-非商业性使用 4.0 国际许可协议