gpt4 book ai didi

linux - 以静默模式安装 Oracle 后,我无法运行 SQLPLUS

转载 作者:太空宇宙 更新时间:2023-11-04 11:43:36 24 4
gpt4 key购买 nike

显示错误

/oracle/product/12.1.0/dbhome_1/bin/sqlplus: error while loading shared libraries: /oracle/product/12.1.0/dbhome_1/lib/libclntsh.so.12.1: file too short

[oracle@82eb40bf3cd2 ~]$ strace $ORACLE_HOME/bin/sqlplus
execve("/oracle/product/12.1.0/dbhome_1/bin/sqlplus", ["/oracle/product/12.1.0/dbhome_1/"...], 0x7ffd4df2e550 /* 23 vars */) = 0
brk(NULL) = 0xd63000
arch_prctl(0x3001 /* ARCH_??? */, 0x7fffa311c1b0) = -1 EINVAL (Invalid argument)
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/tls/haswell/x86_64/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/oracle/product/12.1.0/dbhome_1/lib/tls/haswell/x86_64", 0x7fffa311b400) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/tls/haswell/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/oracle/product/12.1.0/dbhome_1/lib/tls/haswell", 0x7fffa311b400) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/tls/x86_64/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/oracle/product/12.1.0/dbhome_1/lib/tls/x86_64", 0x7fffa311b400) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/tls/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/oracle/product/12.1.0/dbhome_1/lib/tls", 0x7fffa311b400) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/haswell/x86_64/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/oracle/product/12.1.0/dbhome_1/lib/haswell/x86_64", 0x7fffa311b400) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/haswell/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/oracle/product/12.1.0/dbhome_1/lib/haswell", 0x7fffa311b400) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/x86_64/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/oracle/product/12.1.0/dbhome_1/lib/x86_64", 0x7fffa311b400) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/libsqlplus.so", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\320\374\1\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1546540, ...}) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f664e6da000
mmap(NULL, 3112424, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f664e1bc000
mprotect(0x7f664e2a6000, 2093056, PROT_NONE) = 0
mmap(0x7f664e4a5000, 61440, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xe9000) = 0x7f664e4a5000
close(3) = 0
openat(AT_FDCWD, "/oracle/product/12.1.0/dbhome_1/lib/libclntsh.so.12.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "", 832) = 0
close(3) = 0
writev(2, [{iov_base="/oracle/product/12.1.0/dbhome_1/"..., iov_len=43}, {iov_base=": ", iov_len=2}, {iov_base="error while loading shared libra"..., iov_len=36}, {iov_base=": ", iov_len=2}, {iov_base="/oracle/product/12.1.0/dbhome_1/"..., iov_len=53}, {iov_base=": ", iov_len=2}, {iov_base="file too short", iov_len=14}, {iov_base="", iov_len=0}, {iov_base="", iov_len=0}, {iov_base="\n", iov_len=1}], 10/oracle/product/12.1.0/dbhome_1/bin/sqlplus: error while loading shared libraries: /oracle/product/12.1.0/dbhome_1/lib/libclntsh.so.12.1: file too short
) = 153
exit_group(127) = ?
+++ exited with 127 +++

最佳答案

出现此错误的主要原因是系统上缺少 glib-devel rpm 包。在我的系统上,问题在以下操作后得到解决:

  1. 为 glib 安装正确的 rpm
  2. 然后运行此命令重新创建所有符号链接(symbolic link)。$ORACLE_HOME/bin/relink all
  3. 现在试试 sqlplus。

关于linux - 以静默模式安装 Oracle 后,我无法运行 SQLPLUS,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58539012/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com