oracle11g 静默安装

1.检查相关软件包

rpm -qa binutils compat-libstdc++-33 elfutils-libelf elfutils-l

ibelf-devel gcc gcc-c++ glibc glibc-common  glibc-devel glibc-headers ksh libaio

libaio-devel libgcc libstdc++ libstdc++-devel make sysstat unixODBC unixODBC-de

vel  pdksh-5.2.14

安装相关软件包

yum -y install binutils compat-libstdc++-33 elfutils-libelf elfutils-l

ibelf-devel gcc gcc-c++ glibc glibc-common  glibc-devel glibc-headers ksh libaio

libaio-devel libgcc libstdc++ libstdc++-devel make sysstat unixODBC unixODBC-de

vel  pdksh-5.2.14


2.创建相关用户和组

groupadd oinstall

groupadd dba

useradd -g oinstall -G dba oracle

passwd oracle #设置oracle密码



3.设置相关系统变量

vi /home/oracle/.bash_profile

umask 022

export ORACLE_BASE=/u01/app

export ORACLE_HOME=$ORACLE_BASE/oracle/product/11.2.0/dbhome_1

export ORACLE_SID=ORCL

export PATH=$PATH:HOME/bin:$ORACLE_HOME/bin


vi /etc/sysctl.conf

fs.suid_dumpable = 1

fs.aio-max-nr = 1048576

fs.file-max = 6815744

kernel.shmall = 2097152

kernel.shmmax = 536870912

kernel.shmmni = 4096

kernel.sem = 250 32000 100 128

net.ipv4.ip_local_port_range = 9000 65500

net.core.rmem_default = 262144

net.core.rmem_max = 4194304

net.core.wmem_default = 262144

net.core.wmem_max = 1048586


sysctl -p  不重启生效


vi /etc/security/limits.conf

oracle           soft    nproc   2047

oracle           hard    nproc   16384

oracle           soft    nofile  1024

oracle           hard    nofile  65536


vi /etc/pam.d/login

session    required     pam_limits.so


vi /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


4.创建相关目录

mkdir -p /u01/app/

chown -R oracle:oinstall /u01/app/


5.解压软件包到 /u01目录

unzip linux.x64_11gR2_database_1of2.zip linux.x64_11gR2_database_2of2.zip


mv database/* /u01


6.上传或编辑自动响答文件 --附件



7.安装

chmod -R 775 /u01/app

chown -R oracle.oinstall /u01

su - oracle

cd /u01

./runInstaller -silent -force -responseFile /u01/response/db_install.rsp



centos 6 需要运行./runInstaller -silent -ignorePrereq -responseFile /u01/response/db_install.rsp

提示用root帐号运行两个sheel脚本表示安装完成

另开一个终端运行下面两个脚本

sh /u01/app/oracle/oraInventory/orainstRoot.sh

sh /u01/app/oracle/product/11.2.0/dbhome_1/root.sh


安装监听

$ORACLE_HOME/bin/netca -silent -responsefile /u01/response/netca.rsp

安装实列(运行会不断闪不管它直接输入两遍密码过一段时间会出现进度百分比)

$ORACLE_HOME/bin/dbca /silent /responsefile /u01/response/dbca.rsp


再安装个OEM

emca -config dbcontrol db -repos recreate






你可能感兴趣的:(oracle11g,静默安装)