Linux升级lib64中的libc.so.6导致所有命令失效

ls: relocation error: libpthread.so.0: symbol __libc_dl_error_tsd, version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference

升级Glibc后出现所有shell命令都不可用

复制代码
# systemctl status
systemctl: relocation error: /lib64/libpthread.so.0: symbol __libc_vfork version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
# systemctl status kubelet
systemctl: relocation error: /lib64/libpthread.so.0: symbol __libc_vfork version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
# ps
ps: relocation error: /lib64/libpthread.so.0: symbol __libc_vfork version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
# ps -elf
ps: relocation error: /lib64/libpthread.so.0: symbol __libc_vfork version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
# ls
ls: relocation error: /lib64/libpthread.so.0: symbol __libc_vfork version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference

解决方法

原因是因为升级过程删除了soft link

此时,sln命令还是可以用的

复制代码
# sln /usr/lib64/libc-2.28.so /lib64/libc.so.6 
# sln /usr/lib64/ld-2.28.so /usr/lib64/ld-linux-x86-64.so.2

系统恢复正常

复制代码
# ps
  PID TTY          TIME CMD
19214 pts/12   00:00:00 ps
30545 pts/12   00:00:01 bash
相关推荐
wdfk_prog1 天前
[Linux]学习笔记系列 -- lib/dump_stack.c 栈回溯打印(Stack Trace Dumping) 内核调试与错误诊断的基石
linux·运维·服务器·c语言·笔记·学习
蓝倾9761 天前
小红书获取用户作品列表API接口操作指南
java·服务器·前端·python·电商开放平台·开放api接口
bantinghy1 天前
RPC内核细节(转载)
linux·服务器·网络·网络协议·rpc
运维成长记1 天前
linux 100个问答81~101 主要是k8s相关
linux·运维·服务器
旺小仔.1 天前
Linux--线程
linux·运维·服务器
Mr. Cao code1 天前
探索OpenResty:高性能Web开发利器
linux·运维·服务器·前端·nginx·ubuntu·openresty
厦门辰迈智慧科技有限公司1 天前
水闸自动化监控系统解决方案
运维·服务器·物联网·安全·自动化·监测
Nuyoah11klay1 天前
华清远见25072班网络编程day1
linux·服务器·网络·网络编程
努力学习的小廉1 天前
深入了解linux系统—— 日志
linux·运维·服务器
qinyia1 天前
Wisdom SSH 是一款创新性工具,通过集成 AI 助手,为服务器性能优化带来极大便利。
服务器·人工智能·ssh