zoukankan      html  css  js  c++  java
  • linux找不到动态链接库


    开发手动重启服务器,发现docker无法正常自启

    尝试手动重启docker,出现以下问题

    Authorization not available. Check if polkit service is running or see debug message for more information.
    #授权不可用。检查polkit服务是否正在运行,或查看调试消息以获取更多信息。
    Failed to restart docker.service: 连接超时
    See system logs and 'systemctl status docker.service' for details.
    

    发现问题出在polkit

    尝试启动polkit

    [root@rbtnode1 ~]# systemctl start polkit
    Authorization not available. Check if polkit service is running or see debug message for more information.
    Failed to start polkit.service: 连接超时
    See system logs and 'systemctl status polkit.service' for details.
    [root@rbtnode1 ~]# systemctl status polkit
    ● polkit.service - Authorization Manager
       Loaded: loaded (/usr/lib/systemd/system/polkit.service; static; vendor preset: enabled)
       Active: failed (Result: exit-code) since 三 2020-10-28 14:00:47 CST; 27s ago
         Docs: man:polkit(8)
      Process: 22196 ExecStart=/usr/lib/polkit-1/polkitd --no-debug (code=exited, status=127)
     Main PID: 22196 (code=exited, status=127)
    
    10月 28 14:00:47 rbtnode1 systemd[1]: Starting Authorization Manager...
    10月 28 14:00:47 rbtnode1 polkitd[22196]: /usr/lib/polkit-1/polkitd: error while loading shared libraries: lib...ctory
    10月 28 14:00:47 rbtnode1 systemd[1]: polkit.service: main process exited, code=exited, status=127/n/a
    10月 28 14:00:47 rbtnode1 systemd[1]: Failed to start Authorization Manager.
    10月 28 14:00:47 rbtnode1 systemd[1]: Unit polkit.service entered failed state.
    10月 28 14:00:47 rbtnode1 systemd[1]: polkit.service failed.
    Hint: Some lines were ellipsized, use -l to show in full.
    

    无法启动

    尝试修复

    1.编辑/etc/ld.so.conf文件在"include ld.so.conf.d/*.conf"下方增加"/usr/local/lib"。

    2.保存后,在命令行终端执行:/sbin/ldconfig -v;

    其作用是将文件/etc/ld.so.conf列出的路径下的库文件缓存到/etc/ld.so.cache以供使用,因此当安装完一些库文件,或者修改/etc/ld.so.conf增加了库的新搜索路径,需要运行一下ldconfig,使所有的库文件都被缓存到文件/etc/ld.so.cache中,如果没做,可能会找不到刚安装的库

    经过以上两个步骤,"error while loading shared libraries"的问题通常情况下就可以解决了。

    正常启动polkit与docker

  • 相关阅读:
    系统架构师学习笔记_第十一章(下)
    通过IronRuby和C#学习RUBY系列[0]
    TIPS to comment your code
    超级简单:DIV布局
    js 查询XML数据添加到HTML select控件
    《架构之美》读书笔记(一)
    18个不常见的C#关键字,您使用过几个?
    如何成为人尽皆知的C#开发人员
    实现Visual Studio 2010一个很简单的很酷的扩展
    一种简单的直观的高效的权限设计
  • 原文地址:https://www.cnblogs.com/iXiAo9/p/13890961.html
Copyright © 2011-2022 走看看