客服微信
本文为云贝教育 刘峰 原创,请尊重知识产权,转发请注明出处,不接受任何抄袭、演绎和未经注明出处的转载。
yum源准备工作,参考《基于redhat8的网络配置》
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-8.repo
[root@database ~]# ll *.rpm -rw-r--r-- 1 root root 19112 Jun 20 00:54 compat-libcap1-1.10-7.el7.x86_64.rpm -rw-r--r-- 1 root root 195388 Sep 5 2022 compat-libstdc++-33-3.2.3-72.el7.x86_64.rpm -rw-r--r-- 1 root root 2694664264 Jun 19 19:55 oracle-database-ee-19c-1.0-1.x86_64.rpm -rw-r--r-- 1 root root 18204 Jun 20 00:28 oracle-database-preinstall-19c-1.0-1.el7.x86_64.rpm
rpm -ivh compat-libcap1-1.10-7.el7.x86_64.rpm rpm -ivh compat-libstdc++-33-3.2.3-72.el7.x86_64.rpm yum -y install /lib64/libnsl.so.1
yum -y localinstall oracle-database-preinstall-19c-1.0-1.el8.x86_64.rpm
yum -y localinstall oracle-database-ee-19c-1.0-1.x86_64.rpm
/etc/init.d/oracledb_ORCLCDB-19c
# /etc/init.d/oracledb_ORCLCDB-19c configure Configuring Oracle Database ORCLCDB. Prepare for db operation 8% complete Copying database files 31% complete Creating and starting Oracle instance 32% complete 36% complete
cat >> /home/oracle/.bash_profile << "EOF" umask 022 export TMP=/tmp export TMPDIR=$TMP export ORACLE_BASE=/opt/oracle export ORACLE_HOME=/opt/oracle/product/19c/dbhome_1 export ORACLE_SID=ORCLCDB export PATH=/usr/sbin:$PATH export PATH=$ORACLE_HOME/bin:$ORACLE_HOME/OPatch:$PATH EOF
如果在初始化实例过程中出错,通过以下命令删除重建
# /etc/init.d/oracledb_ORCLCDB-19c delete