oracle一个安装报错的处理方法

这两天在CentOS5.5上安装oracle10g到83%左右的时候遇到一个问题,报错日志部分内容如下:

INFO: /home/oracle/product/10.2.0/db_1/bin/genclntsh
INFO: /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/libc.so when searching for -lc
/usr/bin/ld: /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/libc.a(assert.o): relocation R_X86_64_32 against `pthread_setcancelstate@@GLIBC_2.2.5' can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/libc.a: could not read symbols: Bad value
INFO: collect2: ld returned 1 exit status
genclntsh: Failed to link libclntsh.so.10.1
make: *** [client_sharedlib] Error 1
INFO: End output from spawned process.6
INFO: ----------------------------------
INFO: Exception thrown from action: make
Exception Name: MakefileException
Exception String: Error in invoking target 'client_sharedlib' of makefile '/home/oracle/product/10.2.0/db_1/network/lib/ins_net_client.mk'. See '/home/oracle/oraInventory/logs/installActions2011-11-15_07-42-28PM.log' for details.
Exception Severity: 1

在网上搜了很久,答案基本上是说在操作系统和oracle安装包不匹配,例如,32位操作系统安装了64位的oracle导致的,但是我通过执行

uname -sprvmio

看到的结果为

Linux 2.6.18-194.el5 #1 SMP Fri Apr 2 14:58:14 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux

oracle的安装包也一再确认检查,都确认了两个都是64位,不会有错的,后来根据报错信息的提示,即/usr/lib64/libc.so不兼容,然后我试着执行

file /usr/lib64/libc.so

libc.so: ASCII C program text

发现这个文件是文本文件,用vim打开后看到

/* GNU ld script
   Use the shared library, but some functions are only in
   the static library, so try that secondarily.  */
OUTPUT_FORMAT(elf32-i386)
GROUP ( /lib/libc.so.6 /usr/lib/libc_nonshared.a  AS_NEEDED ( /lib/ld-linux.so.2 ) )

再其他相同系统的机器找到该文件,内容为

/* GNU ld script
   Use the shared library, but some functions are only in
   the static library, so try that secondarily.  */
OUTPUT_FORMAT(elf64-x86-64)
GROUP ( /lib64/libc.so.6 /usr/lib64/libc_nonshared.a  AS_NEEDED ( /lib64/ld-linux-x86-64.so.2 ) )

到此,才基本明白安装oracle报错的原因,因为该文件致使oracle找不到正确的64位的库文件导致安装失败,把该文件备份后将其改为后者的内容后即可顺利安装oracle10g;



  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值