一、操作系统版本
二、安装介质
https://www.oracle.com/database/technologies/oracle-database-software-downloads.html#19c
这个链接是下载oracle安装包
OracleDB_19.19_Linux-for-arm.zip
https://yum.oracle.com/repo/OracleLinux/OL8/appstream/aarch64/
这个链接是下载oracle准备包
oracle-database-preinstall-19c-1.0-3.el8.aarch64.rpm
三、安装步骤
3.1 使用麒麟操作系统yum源
yum install -y ksh libaio-devel libgfortran libstdc+±devel psmisc xorg-x11-utils xorg-x11-xauth
3.2 安装oracle-database-preinstall-19c-1.0-3.el8.aarch64.rpm
rpm -ivh oracle-database-preinstall-19c-1.0-3.el8.aarch64.rpm –-nodeps
如果不是忽略关联安装的话会报这个错
/etc/redhat-release is needed by oracle-database-preinstall-19c-1.0-3.el8.aarch64
libnsl is needed by oracle-database-preinstall-19c-1.0-3.el8.aarch64
一个是因为操作系统不是redhat,另外一个是操作系统上面的libnsl太新了,find一下做个软连接即可,要不然后面runInstall做不了
这个rpm包会自动安装Oracle需要的软件包,同时会对ulimit,内核参数等进行配置,还会创建Oracle用户。你当然可以按照安装文档,一步一步手工配置,使用这个包,是比较简单的方式。此处参考Oracle一体机组公众号连接:
https://mp.weixin.qq.com/s/gwVsVvLAFGTXVUeQw4mEXg
3.3 设置编译工具
Oracle软件relink时,会到指定位置找ar和as工具,在CentOS 8上,虽然有这两个工具,但是位置不对,在Orace软件引用的位置创建符号链接:
mkdir -p /opt/rh/devtoolset-8/root/usr/bin/
cd /opt/rh/devtoolset-8/root/usr/bin/
ln -s /usr/bin/ar ar
ln -s /usr/bin/as as
此处参考Oracle一体机组公众号连接:
https://mp.weixin.qq.com/s/gwVsVvLAFGTXVUeQw4mEXg
3.4 设置Oracle环境变量
3.5 建好oracle目录
3.6 设置CV_ASSUME_DISTID
export CV_ASSUME_DISTID=RHEL8.0
规避这个报错参考连接:
https://www.xifenfei.com/2023/07/arm-install-oracle.html
3.7安装开始
su – oracle
cd $ORACLE_HOME
unzip LINUX.ARM64_1919000_db_home.zip
./runInstaller
3.8 手工建库
Dbca确实不能建库,只能手工建库
脚本如下:
CREATE DATABASE orcl
USER SYS IDENTIFIED BY oracle
USER SYSTEM IDENTIFIED BY oracle
LOGFILE GROUP 1
(’/oracledata/ORCL/onlinelog/redo01a.log’) SIZE 200M BLOCKSIZE 512,
GROUP 2 (’/oracledata/ORCL/onlinelog/redo02a.log’) SIZE 200M BLOCKSIZE 512,
GROUP 3 (’/oracledata/ORCL/onlinelog/redo03a.log’) SIZE 200M BLOCKSIZE 512
MAXLOGHISTORY 1
MAXLOGFILES 16
MAXLOGMEMBERS 3
MAXDATAFILES 8192
CHARACTER SET AL32UTF8
NATIONAL CHARACTER SET AL16UTF16
EXTENT MANAGEMENT LOCAL
DATAFILE ‘/oracledata/ORCL/datafile/system01.dbf’
SIZE 700M REUSE AUTOEXTEND ON NEXT 10240K MAXSIZE UNLIMITED
SYSAUX DATAFILE ‘/oracledata/ORCL/datafile/sysaux01.dbf’
SIZE 550M REUSE AUTOEXTEND ON NEXT 10240K MAXSIZE UNLIMITED
DEFAULT TABLESPACE users
DATAFILE ‘/oracledata/ORCL/datafile/users01.dbf’
SIZE 5M REUSE AUTOEXTEND ON MAXSIZE UNLIMITED
DEFAULT TEMPORARY TABLESPACE temp
TEMPFILE ‘/oracledata/ORCL/tempfile/temp01.dbf’
SIZE 20M REUSE AUTOEXTEND ON NEXT 640K MAXSIZE UNLIMITED
UNDO TABLESPACE UNDOTBS1
DATAFILE ‘/oracledata/ORCL/datafile/undotbs01.dbf’
SIZE 200M REUSE AUTOEXTEND ON NEXT 5120K MAXSIZE UNLIMITED;
–执行以下脚本
@?/rdbms/admin/catalog.sql
@?/rdbms/admin/catproc.sql
@?/rdbms/admin/utlrp.sql
@?/sqlplus/admin/pupbld.sql
3.9安装完成