标签:oracle 安装
1 安装前准备
yum -y install binutils compat-libcap1 compat-libstdc++.i686 compat-libstdc++.x86_64 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc.i686 glibc.x86_64 glibc-devel.i686 glibc-devel.x86_64 ksh libgcc.i686 libgcc.x86_64 libstdc++.i686 libstdc++.x86_64 libstdc++-devel.i686 libstdc++-devel.x86_64 libaio.i686 libaio.x86_64 libaio-devel.i686 libaio-devel.x86_64 libXext libXtst libX11 libXau libxcb libXi make sysstat unixODBC-devel.i686 unixODBC-devel.x86_64 unixODBC.i686 unixODBC.x86_64 compat-libstdc++-33.i686 compat-libstdc++-33.x86_64
关闭selinux以及firewalld
2 设置主机解析:主机名 oracle
10.0.0.2 oracle
3 创建组以及用户
groupadd oinstall
groupadd dba
useradd -g oinstall -G dba oracle /usermod -g oinstall -G dba oracle(有账户重新赋予命令)
passwd oracle
4 修改内核参数
vi /etc/sysctl.d/sysctl.conf
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 = 1048576
sysctl -p
5 系统资源限制配置
vi /etc/security/limits.conf
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
oracle soft stack 10240
6创建数据库文件夹分配组权限
mkdir -p /u01/app/
mkdir -p /u01/app/oracle/product/12.1.0/dbhome_1
chown -R oracle:oinstall /u01/app/
chmod -R 775 /u01/app/
7设置环境变量
ORACLE_BASE=/u01/app
ORACLE_HOME=$ORACLE_BASE/oracle/product/12.1.0/dbhome_1
ORACLE_SID=orcl
LD_LIBRARY_PATH=$ORACLE_HOME/lib;
PATH=$PATH:$ORACLE_HOME/bin:$HOME/bin;
export ORACLE_BASE ORACLE_HOME ORACLE_SID LD_LIBRARY_PATH PATH;
8设置DISPLAY变量(避免vnc连接安装出错)
export DISPLAY=:1
接下来通过vnc图形界面按照自定义安装,不会出现任何错误提示
安装完毕后:
查看是否在监听:
[oracle@oracle ~]$ ps -ef|grep LISTENER
oracle 9976 1 0 Jul13 ? 00:00:00 /u01/app/oracle/product/12.1.0/dbhome_1/bin/tnslsnr LISTENER -inherit
重启数据库dbshut出现错误:
ORACLE_HOME_LISTNER is not SET, unable to auto-stop Oracle Net Listener Usag
将会对应脚本文件更改为:
ORACLE_HOME_LISTNER=$1 修改为 ORACLE_HOME_LISTNER=$ORACLE_HOME
本文出自 “大王好帅” 博客,请务必保留此出处http://dawang.blog.51cto.com/4927689/1674057
标签:oracle 安装
原文地址:http://dawang.blog.51cto.com/4927689/1674057