Oracle19c静默部署

Oracle19c静默部署文档

下载地址 https://www.oracle.com/database/technologies/oracle-database-software-downloads.html#db_free

image-20240316092528444

一、系统基础配置

1、创建用户和用户组
# 创建oinstall和dba用户组
groupadd oinstall
groupadd dba

# 创建Oracle用户
useradd -g oinstall -G dba oracle

# 设置Oracle用户密码
passwd oracle

# 查看用户
id oracle

注意:这里查出来的uid必须是oracle,gid必须是oinstall,组必须是dba

image-20240316094245505

2、修改系统配置文件
cat >>/etc/sysctl.conf<<'EOF'
fs.aio-max-nr=1048576
fs.file-max=6815744
kernel.shmall=524288
kernel.shmmax=2147483647
kernel.sem=250 32000 100 128
kernel.shmmni=4096
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
EOF

sysctl -p



cat >>/etc/security/limits.conf<<'EOF'
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
oracle soft stack 10240
oracle hard stack 10240
EOF


vim /etc/pam.d/login
session    required     /lib64/security/pam_limits.so
session    required     pam_limits.so



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


source /etc/profile

image-20240316094403947

image-20240316094459116

image-20240316094638772

image-20240316094720746

3、 创建数据库目录
mkdir -p /data/server/oracle
chown -R oracle:oinstall /data/server/oracle
chmod -R 775 /data/server/oracle

image-20240316094802883

4、配置Oracle用户
su oracle
vim ~/.bash_profile
export ORACLE_BASE=/data/server/oracle
export ORACLE_SID=orcl

source ~/.bash_profile

image-20240316094926771

二、安装部署及配置

1、上传安装包
mkdir -p /data/file/oracle
chown -R oracle:oinstall /data/file/oracle
chmod -R 775 /data/file/oracle

上传安装包到 /data/file/oracle 目录下

image-20240316095015682

2、解压文件
su - oracle
cd /data/file/oracle/
unzip LINUX.X64_193000_db_home.zip

image-20240316095223720

3、编辑文件内容

切换到oracle用户

su - oracle

打开编辑db_install.rsp

cd /data/file/oracle/install/response/
mv db_install.rsp  db_install.rsp.bak

cat>db_install.rsp<<'EOF'
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v19.0.0
# 响应文件版本号

oracle.install.option=INSTALL_DB_SWONLY
# 安装选项为仅安装数据库软件

UNIX_GROUP_NAME=oinstall
# UNIX 组名为 oinstall

INVENTORY_LOCATION=/data/server/oracle/oraInventory
# Oracle 软件 Inventory(库存)位置

ORACLE_HOME=/data/file/oracle
# Oracle 软件安装目录

ORACLE_BASE=/data/server/oracle
# Oracle 软件基础目录

oracle.install.db.InstallEdition=EE
# 安装的 Oracle 版本为 Enterprise Edition

oracle.install.db.OSDBA_GROUP=dba
# OSDBA 组名为 dba

oracle.install.db.OSOPER_GROUP=oinstall
# OSOPER 组名为 oinstall

oracle.install.db.OSBACKUPDBA_GROUP=oinstall
# OSBACKUPDBA 组名为 oinstall

oracle.install.db.OSDGDBA_GROUP=oinstall
# OSDGDBA 组名为 oinstall

oracle.install.db.OSKMDBA_GROUP=oinstall
# OSKMDBA 组名为 oinstall

oracle.ins
  • 50
    点赞
  • 39
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值