开发者

ubuntu server PS, ifocnfig, command not working

i am working on ubuntu server from past few months and now suddenly ps,开发者_如何学C ifconfing commnad stop working with below error.

user1@Fb1:/usr/bin$ ps -bash: /bin/ps: No such file or directory

any suggestions to get this command working back.


What's the output of which ps and ls /usr/bin -al (which are both in /bin also)? Does it work if you gain root privileges, either using sudo ifconfig or sudo su, then ifconfig?

This is possibly an issue with file permissions but it's hard to say without more information.


First use locate to find your ps or ifconfig program:

$ locate ps | grep bin

Also you may try whereis command:

$ whereis ps

If you don't find them, try to search as root user.


i have tried to put all the outputs of different commnads as below root@Fb1:/usr/bin# whereis ps ps: /bin/ps /usr/share/man/man1/ps.1.gz

root@Fb1:/usr/bin# ls -lsa ps 16 -rwxr-xr-x 1 root root 15859 2010-05-26 12:21 ps


Something wrong with your $PATH I suspect it doesn't have /sbin .. maybe new software overwrite your $PATH..

normal path should be include this (mebada is my user name)

mebada@T430:~$ echo $PATH
/home/mebada/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜