Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I added these lines to my .bashrc file:

export vertx_home=/anto/vertx/bin
export PATH=${PATH}:${vertx_home}/bin

after doing that. I get an error message like that for all command's I run, for example:clear,groovy :

Command 'clear' is available in '/usr/bin/clear'
The command could not be located because '/usr/bin' is not included in the PATH environment variable.
clear: command not found

How to recover from it?

I'm new to Ubuntu. Kindly help.

Thanks in advance.

share|improve this question
run echo $PATH and see what is in path variable – Manula Waidyanatha Apr 17 '12 at 13:24
it shows ${PATH}:${VERTX_HOME} – Ant's Apr 17 '12 at 14:54
up vote 0 down vote accepted

Two points:

  1. No need for the first 'export' command
  2. Looks to me you have got your vertx_home set wrong, as your effective path is: /anto/vertex/bin/bin - note the repetition of 'bin'

Suggest changing your .bashrc to read as follows:

export PATH=$PATH:$vertx_home/bin

Close any open terminals for the change to take effect.

share|improve this answer
The problem is that I couldn't able to open vi ~/.bashrc as it says the same error in my original question. Not only vi, many other commands got struck-ed! – Ant's Apr 17 '12 at 14:54
Where I can find that file manually? – Ant's Apr 17 '12 at 14:56
Have you tried using the full path of editor and file? Something like /usr/bin/gedit /home/YOUR_USER_NAME/.bashrc – Salem Apr 17 '12 at 15:30
@Salem: Ya now it works!Thanks.. – Ant's Apr 17 '12 at 15:39

vi is in
/usr/bin/vi try /usr/bin/vi ~/.bashrc

share|improve this answer
Thanks a lot. I recovered! – Ant's Apr 17 '12 at 15:38

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.