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'm using the ln command to create a symbolic link to a directory using bash, I went to the directory I wanted to make a link and used the following command:

ln -s C#/ ~/Projetos

This would create a link to ~/media/Projects/C# in the ~/Projetos folder.

But once I cd to my home, the folder is displayed in red color and I can't access it, what's happening here?

enter image description here

share|improve this question
up vote 10 down vote accepted

You can check the link using ls -l (which is usually aliased to just ll). You will see something like this:

 user42@localhost$ ll ~/Projetos
 lrwxrwxrwx 1 user42 user42    3 Sep 26 19:48 Projetos -> C#/

this means, that using the path /home/user42/Projetos will be substituted with /home/user42/C#. This path does not exist.

You probably wanted to use either

  • a correct relative link like ln -s media/Projects/C# ~/Projetos
  • or an absolute link like in ln -s $PWD/C#/ ~/Projetos
share|improve this answer

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.