problem with commands

Questions about other topics - please check if your question fits better in another category before posting here
Forum rules
Before you post please read this

problem with commands

Postby subzero on Wed Dec 12, 2012 11:57 am

Hi

I don't know where i can write this topic ..

I have problem on mint 14

all commands not working

Example :-
subzero@subzero-N53SV ~ $ cat log.txt
Traceback (most recent call last):
File "/usr/lib/command-not-found", line 21, in <module>
os.execvp("python3", [sys.argv[0]] + sys.argv)
File "/usr/lib/python2.7/os.py", line 344, in execvp
_execvpe(file, args)
File "/usr/lib/python2.7/os.py", line 380, in _execvpe
func(fullname, *argrest)
OSError: [Errno 13] Permission denied


sorry for bad English
subzero
Level 1
Level 1
 
Posts: 4
Joined: Sun Nov 25, 2012 6:00 pm

Linux Mint is funded by ads and donations.
 

Re: problem with commands

Postby overthetop on Wed Dec 12, 2012 12:20 pm

Your problem seems to be a python problem. command-not-found is a python program that runs when a command is not found on the system.
Have you installed python manually? What does the command which python return?

Try running the following in the python interpreter:
Code: Select all
me@my-pc ~ $ python
Python 2.7.3 (default, Sep 26 2012, 21:51:14)
[GCC 4.7.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.path
['', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-linux2', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages/PIL', '/usr/lib/python2.7/dist-packages/gst-0.10', '/usr/lib/python2.7/dist-packages/gtk-2.0', '/usr/lib/python2.7/dist-packages/ubuntu-sso-client']
Image
"A wise man can learn more from a foolish question than a fool can learn from a wise answer." -- Bruce Lee
User avatar
overthetop
Level 4
Level 4
 
Posts: 368
Joined: Thu Oct 06, 2011 10:25 am
Location: /home/overthetop

Re: problem with commands

Postby subzero on Wed Dec 12, 2012 12:22 pm

thanks for your answer

same problem

Code: Select all
subzero@subzero-N53SV ~ $ python
Traceback (most recent call last):
  File "/usr/lib/command-not-found", line 21, in <module>
    os.execvp("python3", [sys.argv[0]] + sys.argv)
  File "/usr/lib/python2.7/os.py", line 344, in execvp
    _execvpe(file, args)
  File "/usr/lib/python2.7/os.py", line 380, in _execvpe
    func(fullname, *argrest)
OSError: [Errno 13] Permission denied
subzero
Level 1
Level 1
 
Posts: 4
Joined: Sun Nov 25, 2012 6:00 pm

Re: problem with commands

Postby overthetop on Wed Dec 12, 2012 12:35 pm

What about
Code: Select all
echo $PATH
Image
"A wise man can learn more from a foolish question than a fool can learn from a wise answer." -- Bruce Lee
User avatar
overthetop
Level 4
Level 4
 
Posts: 368
Joined: Thu Oct 06, 2011 10:25 am
Location: /home/overthetop

Re: problem with commands

Postby subzero on Wed Dec 12, 2012 12:55 pm

Code: Select all
subzero@subzero-N53SV ~ $ echo $PATH
$PATH:/opt/android-sdk-linux/tools:/opt/android-sdk-linux/platforms:/opt/android-sdk-linux/platform-tools
subzero
Level 1
Level 1
 
Posts: 4
Joined: Sun Nov 25, 2012 6:00 pm

Re: problem with commands

Postby xenopeek on Wed Dec 12, 2012 1:01 pm

So the problem is you have set your PATH to only include these android directories. Hence system commands like cat and python can no longer be found, as you have excluded them from your path. Normally your path would be:
Code: Select all
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

Can you recall what you did, e.g. where did you change the PATH settings. Revert that change.

You can correct the path at least for your terminal with:
Code: Select all
export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games"
User avatar
xenopeek
Level 21
Level 21
 
Posts: 14499
Joined: Wed Jul 06, 2011 3:58 am
Location: The Netherlands

Re: problem with commands

Postby subzero on Wed Dec 12, 2012 1:03 pm

Thanks all ^_^
subzero
Level 1
Level 1
 
Posts: 4
Joined: Sun Nov 25, 2012 6:00 pm

Linux Mint is funded by ads and donations.
 

Return to Other topics

Who is online

Users browsing this forum: No registered users and 3 guests