- 论坛徽章:
- 0
|
本帖最后由 ritto 于 2010-03-02 15:50 编辑
大家,我的一台生产环境下的服务器安装的CentOS5.2.
下午突然当机了,查看后,发现系统命令先都不能执行,像ls, ifconfig全都报错,错误如下:
[root@centos2 ~]# ls
ls: error while loading shared libraries: librt.so.1: cannot open shared object file: No such file or directory
[root@centos2 ~]# ifconfig
ifconfig: error while loading shared libraries: libselinux.so.1: cannot open shared object file: No such file or
directory
[root@centos2 ~]# ldd /bin/ls
librt.so.1 => not found
libacl.so.1 => /lib64/libacl.so.1 (0x00000037ba200000)
libselinux.so.1 => not found
[root@centos2 ~]# ldd /sbin/ifconfig
libselinux.so.1 => not found
我强行重启下系统后,发现本脚本进不了系统.
开机时报错:error message when system start:
/sbin/init: error while loading shared libraries: libselinux.so.1: cannot open shared object file: No such file or
directory
Kernel panic - not syncing: Attempted to kill init!
我重新开机使用安装dvd从光盘启动模式进入系统:
chroot /mnt/sysimage
echo "/usr/local/lib" >> /etc/ld.so.conf
echo "/lib" >> /etc/ld.so.conf
ldconfig -v
没有解决问题,连ls命令都用了,无法查看文件是否存在.
按照网上的解决方法:
从其它系统拷贝相同的so文件过去,但是这种如何保持兼容一致呢,我拷了不行(连cp命令都用不了).
还有网上说可以用光盘恢复,我尝试挂载光盘 mount /dev/cdrom /media
mount: error while loading shared libraries: libselinux.so.1: cannot open shared object file: No such file or
directory 无法挂载.
到底是怎么光盘来恢复这些 so 文件的呢,大家帮帮忙,万分感谢~~~` |
|