文章详情

短信预约-IT技能 免费直播动态提醒

请输入下面的图形验证码

提交验证

短信预约提醒成功

CentOS7.5启动sqlplus失败的解决方法

2024-04-02 19:55

关注

本篇内容介绍了“CentOS7.5启动sqlplus失败的解决方法”的有关知识,在实际案例的操作过程中,不少人都会遇到这样的困境,接下来就让小编带领大家学习一下如何处理这些情况吧!希望大家仔细阅读,能够学有所成!

操作系统:CentOS 7.5

数据库:Oracle 11.2.0.4

sqlplus突然无法启动,报错信息如下:

Error 5 initializing SQL*Plus

NLS initialization error

初步判断是nls编码文件读取失败导致sqlplus无法启动。用strace跟踪sqlplus的执行过程:

[oracle@node3 ~]$ strace -t -e trace=file sqlplus

10:30:16 execve("/opt/app/oracle/product/11g/bin/sqlplus", ["sqlplus"], []) = 0

10:30:16 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/tls/x86_64/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/opt/app/oracle/product/11g/lib/tls/x86_64", 0x7ffd81e7e460) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/tls/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/opt/app/oracle/product/11g/lib/tls", 0x7ffd81e7e460) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/x86_64/libsqlplus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/opt/app/oracle/product/11g/lib/x86_64", 0x7ffd81e7e460) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libsqlplus.so", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libclntsh.so.11.1", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libnnz11.so", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib32/tls/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/opt/app/oracle/product/11g/lib32/tls/x86_64", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib32/tls/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/opt/app/oracle/product/11g/lib32/tls", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib32/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/opt/app/oracle/product/11g/lib32/x86_64", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib32/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/opt/app/oracle/product/11g/lib32", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/tls/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/lib/tls/x86_64", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/tls/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/lib/tls", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/lib/x86_64", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/lib", {st_mode=S_IFDIR|0555, st_size=4096, ...}) = 0

10:30:16 open("/usr/lib/tls/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/usr/lib/tls/x86_64", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/tls/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/usr/lib/tls", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/usr/lib/x86_64", 0x7ffd81e7e3d0) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 stat("/usr/lib", {st_mode=S_IFDIR|0555, st_size=4096, ...}) = 0

10:30:16 open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/lib64/libdl.so.2", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/libm.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib64/libm.so.6", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libpthread.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libpthread.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/libpthread.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/libpthread.so.0", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib64/libpthread.so.0", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libnsl.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libnsl.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/libnsl.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/libnsl.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib64/libnsl.so.1", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libc.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libc.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/libc.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/libc.so.6", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib64/libc.so.6", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libaio.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libaio.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libaio.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib/libaio.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/usr/lib/libaio.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/lib64/libaio.so.1", O_RDONLY|O_CLOEXEC) = 3

10:30:16 open("/opt/app/oracle/product/11g/lib/libsqlplusic.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libociicus.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/lib/libociei.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

10:30:16 open("/opt/app/oracle/product/11g/nls/data/lx1boot.nlb", O_RDONLY) = 3

10:30:16 open("/opt/app/oracle/product/11g/nls/data/lx00001.nlb", O_RDONLY) = 3

10:30:16 open("/opt/app/oracle/product/11g/nls/data/lx20354.nlb", O_RDONLY) = 3

Error 5 initializing SQL*Plus

NLS initialization error

10:30:16 +++ exited with 1 +++

可看到是在读取lx20354.nlb文件候,导致sqlplus退出。查看此文件:

[oracle@node3 data]$ ll /opt/app/oracle/product/11g/nls/data/lx20354.nlb

ls: cannot access /opt/app/oracle/product/11g/nls/data/lx20354.nlb: No such file or directory

发现此文件竟然丢失了。因此可断定,是编码文件lx20354.nlb的丢失导致了sqlplus启动失败。

解决方案:

 从运行正常的同版本实例中拷贝丢失的文件并放到相应目录下即可解决问题。

“CentOS7.5启动sqlplus失败的解决方法”的内容就介绍到这里了,感谢大家的阅读。如果想了解更多行业相关的知识可以关注亿速云网站,小编将为大家输出更多高质量的实用文章!

阅读原文内容投诉

免责声明:

① 本站未注明“稿件来源”的信息均来自网络整理。其文字、图片和音视频稿件的所属权归原作者所有。本站收集整理出于非商业性的教育和科研之目的,并不意味着本站赞同其观点或证实其内容的真实性。仅作为临时的测试数据,供内部测试之用。本站并未授权任何人以任何方式主动获取本站任何信息。

② 本站未注明“稿件来源”的临时测试数据将在测试完成后最终做删除处理。有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341

软考中级精品资料免费领

  • 历年真题答案解析
  • 备考技巧名师总结
  • 高频考点精准押题
  • 2024年上半年信息系统项目管理师第二批次真题及答案解析(完整版)

    难度     813人已做
    查看
  • 【考后总结】2024年5月26日信息系统项目管理师第2批次考情分析

    难度     354人已做
    查看
  • 【考后总结】2024年5月25日信息系统项目管理师第1批次考情分析

    难度     318人已做
    查看
  • 2024年上半年软考高项第一、二批次真题考点汇总(完整版)

    难度     435人已做
    查看
  • 2024年上半年系统架构设计师考试综合知识真题

    难度     224人已做
    查看

相关文章

发现更多好内容

猜你喜欢

AI推送时光机
位置:首页-资讯-数据库
咦!没有更多了?去看看其它编程学习网 内容吧
首页课程
资料下载
问答资讯