修复了被损坏的/bin/ls

系统被黑一次,ls被人搞了,也不是完全不能用,只不过参数h挂掉了。。
[root@vm2 bin]# ls -alh
ls: invalid option — h
Try `ls –help’ for more information.
实在懒得管他纵容丫活到现在。。现在是在不能忍了。修复之。懒得找源文件编译,yum install之
先找:
[root@vm2 bin]# yum provides /bin/ls
Searching Packages:
Setting up repositories
Reading repository metadata in from local files

coreutils.i386 5.2.1-36.el4.centos base
Matched from:
/bin/ls

后装,报错
Installing: coreutils ######################### [2/2]
error: unpacking of archive failed on file /bin/ls: cpio: rename

查阅得知有只读权限,废除之

[root@vm2 bin]# lsattr ls
—-ia——- ls
chattr -ia ls

继续yum install coreutils.i386 成功

You can leave a response, or trackback from your own site.

Leave a Reply


Verify Code   If you cannot see the CheckCode image,please refresh the page again!
Powered by WordPress | Compare Cell Phone Plans at iCellPhonePlans.com | Thanks to Cheap Palm Pixi, Bromoney and Wordpress Themes