环境:Centos 8
Oracle版本:19c
OGG版本:Oracle GoldenGate 21.3
安装步骤
1.将文件拷贝到opt目录下
2,unzip 191004_fbo_ggs_Linux_x64_shiphome.zip 解压文件
3,chown -R oracle:oinstall fbo_ggs_Linux_x64_shiphome 将权限赋予oracle用户,因为root用户无法安装。
4,使用静默方式安装
./runInstaller -silent -nowait -responseFile /opt/fbo_ggs_Linux_x64_shiphome/Disk1/response/oggcore_cp.rsp -invPtrLoc /opt/ogg/oraInventory/oraInst.loc
5,提示Oracle GoldenGate Core 的 安装 已成功。进入安装目录,输入./ggsci,内容显示如下就表示已成功进入OGG。
问题整理
问题1:检查监视器 未通过 ,问题描述如下:
[oracle@localhost Disk1]$ ./runInstaller
正在启动 Oracle Universal Installer...
检查临时空间: 必须大于 120 MB。 实际为 10732 MB 通过
检查交换空间: 必须大于 150 MB。 实际为 218 MB 通过
检查监视器: 监视器配置至少必须显示 256 种颜色
>>> 无法使用命令 /usr/bin/xdpyinfo 自动检查显示器颜色。请检查是否设置了 DISPLAY 变量。 未通过 <<<<
未通过某些要求检查。必须先满足这些 要求,
然后才能继续安装,
是否继续? (y/n) [n]
解决方式:
[oracle@localhost Disk1]$ export DISPLAY=:1.0
[oracle@localhost Disk1]$ xhost +
access control disabled, clients can connect from any host
[oracle@localhost Disk1]$
如果xhost + 执行后仍然显示xhost: unable to open display ":1.0",执行vncserver命令,启动vnc服务,然后再重新执行上面的命令。
显示如上则表示参数已经设置成功,再执行.runInstaller就不会提示检查不通过了,如果你这个解决方式仍然不能解决你的问题,可以参考这个链接的详细解决方案。ORACLE 11g安装中出现xhost: unable to open display问题解决步骤 - 博客 - 编程圈
问题2:./runInstaller 命令输入后没有任何反应,具体问题描述如下:
[oracle@localhost Disk1]$ ./runInstaller
正在启动 Oracle Universal Installer...
检查临时空间: 必须大于 120 MB。 实际为 12307 MB 通过
检查交换空间: 必须大于 150 MB。 实际为 430 MB 通过
检查监视器: 监视器配置至少必须显示 256 种颜色。 实际为 16777216 通过
准备从以下地址启动 Oracle Universal Installer /tmp/OraInstall2021-09-22_02-33-32PM. 请稍候...[oracle@localhost Disk1]$
OGG有两种安装方案,一种是OUI(弹出可视化窗口的安装方式),一种是静默安装(命令行安装),具体文档参考OGG的官方文档,如下链接:
Installing Oracle GoldenGate Classic for Oracle Database
./runInstaller是OUI方式安装,看来我的OUI有问题,或者我根本就没有装过这东西。
解决方式:
使用静默方式安装。
步骤如下:
1.进入解压文件夹的response目录下,我的目录是
/opt/fbo_ggs_Linux_x64_shiphome/Disk1/response
2.cp oggcore.rsp oggcore_cp.rsp
拷贝一份这个文件,其实在上面直接改也无所谓,保险起见拷贝一份,以免改错了也没法回滚。
3. vim oggcore_cp.rsp 修改该文件
INSTALL_OPTION=ORA19c # 这是你的数据库SID,不知道的命令行输入echo $ORACLE_SID,linux会显示出来,拷贝粘贴过来
#-------------------------------------------------------------------------------
# Specify a location to install Oracle GoldenGate
#-------------------------------------------------------------------------------
SOFTWARE_LOCATION=/opt/ogg # 你OGG的安装目录,提前创建好,不然执行命令的时候会提示oracle用户权限在/opt目录下创建文件夹
#-------------------------------------------------------------------------------
# Specify true to start the manager after installation.
#-------------------------------------------------------------------------------
START_MANAGER=false # 这个就设置为false
#-------------------------------------------------------------------------------
# Specify a free port within the valid range for the manager process.
# Required only if START_MANAGER is true.
#-------------------------------------------------------------------------------
MANAGER_PORT=
4.保存上面的文件,回到命令行,执行如下指令。
./runInstaller -silent -nowait -responseFile /opt/fbo_ggs_Linux_x64_shiphome/Disk1/response/oggcore_cp.rsp
5.第四步可能会报异常:没有为主产品清单 (oraInventory) 所有权组指定值。不要急,看下面的问题处理方案。
问题3:没有为主产品清单 (oraInventory) 所有权组指定值。
解决方式:
加上 这个参数 -invPtrLoc /opt/ogg/oraInventory/oraInst.loc
1.首先找一个目录创建一个.loc文件
cd /opt/ogg
mkdir oraInventory
touch oraInst.loc
2.编辑该文件,添加如下信息
vim oraInst.loc
inventory_loc=/opt/ogg/oraInventory
inst_group=oinstall
3.保存
4.在刚才的命令上加上 -invPtrLoc /opt/ogg/oraInventory/oraInst.loc 参数就可以了。
5.如果上面的修改还是不行
vim /etc/oraInst.loc
把
inventory_loc=/opt/ogg/oraInventory
inst_group=oinstall
粘贴进去。
真心吐槽,oracle的软件真tm难用呀。。!~~~~~~~
问题4:安装成功后,执行./ggsci可能会报找不依赖报,如缺少libnnz19.so等。
解决方式:
参考这个链接,处理的很详细。
ggsci error while loading shared libraries libnnz19.so_m18994118189的博客-优快云博客