0
点赞
收藏
分享

微信扫一扫

Linux 7安装Oracle 11g打怪经历


最近接到个需求,要将一套开发环境中Linux 6平台的Oracle 11g,迁移到两套Linux7平台,原以为很简单,但过程中,确实历经坎坷,就像过山车一般,解决这个问题,又碰到下一个。

软件信息

RedHat Linux 7.5

Oracle 11.2.0.4

坑坑坑

1. 软链接

为了安装路径的标准和简便,可以使用软链接,语法如下,

ln -s 【目标目录】 【软链接地址】

例如,为了让原始路径/opt/app/oracle软链接到/u01/app/oracle,并且记得授权,如下所示,

ln -s /opt/app/oracle /u01/app/oracle
chown -R oracle:dba /u01

2. 图形安装界面无法启动

用VNC连接到Linux,常规来讲,在root下,执行xhost +,一般就可以用oracle账户启动Oracle安装界面,但这次失败了,

>>> Could not execute auto check for display colors using command /usr/bin/xdpyinfo. 
Check if the DISPLAY variable is set.    
Failed <<<<

解决方式,

(1) root下执行xhost +
返回信息为:access control disabled,clients canconnect from any host

(2) 切换到oracle(su - oracle),执行export DISPLAY=:2(之所以是2,不是1,应该是我之前启动了两次VNC)。

(3) 执行xdpyinfo,如果能正常显示,说明设置成功。

3. 缺少Package

启动图形界面,在预检的环节,提示缺少compat-libstdc++-33-3.2.3,这个和Linux的版本是有关的,MOS(2254198.1)已经说明了,Linux 7的版本已经将compat-libstdc++-33-3.2.3移到了可选配件中,这个包是和Oracle Text功能相关的,如果不用这功能,就可以不安装这个包了,

As of Red Hat Enterprise Linux version 7 compat-libstdc+±33-3.2.3 (x86_64) has been moved into the optional channel. RedHat policy on this software is that support and guarantees cannot be maintained.

4. 极其诡异的图形界面提示

在这个界面,弹窗显示太小,不能拖动,不管关,不能取消,奇了怪了,

Linux 7安装Oracle 11g打怪经历_oracle

解决方式,

这个问题和启动安装界面时使用的jre环境有关,在执行runInstaller的时候,可以指定jre路径,

./runInstaller -jreLoc /usr/java/jdk1.7.0_79/jre

P.S. 如果使用yum,安装的是openjdk,不是SUN jdk,

yum install java

还是会提示错误,需要的是SUN jdk。

5. sysctl

Linux 7下,/etc/sysctl.conf配置文件中,默认缺少这些信号量的配置,需要手工加上,

# Controls the default maxmimum size of a mesage queue
kernel.msgmnb = 65536

# Controls the maximum size of a message, in bytes
kernel.msgmax = 65536

# Controls the maximum shared segment size, in bytes
kernel.shmmax = 68719476736

# Controls the maximum number of shared memory segments, in pages
kernel.shmall = 4294967296
vm.swappiness=1

否则Oracle图形界面预检的时候,就会提示错误,

Linux 7安装Oracle 11g打怪经历_oracle_02

6. 图形界面安装进度过程中提示错误

经过了上面这些准备工作,在安装进度中,还会提示错误,这个又和Linux 7的版本相关,需要做这些改动,

vi $ORACLE_HOME/sysman/lib/ins_emagent.mk
将
$(SYSMANBIN)emdctl:
        $(MK_EMAGENT_NMECTL)
改为
$(SYSMANBIN)emdctl:
        $(MK_EMAGENT_NMECTL) -lnnz11

此时,继续安装,就可以了。


举报

相关推荐

0 条评论