I came across this weird situation when I accidentally moved one of my directory to an unknown place I am unable to find.

What I did was executed this command -

/opt/lampp/htdocs/cake$ mv cakephp/ .../

It did executed without any error, and now I am not able to locate my directory.

I googled this issue but I am not getting any help.

Any help will be appreciated.

  • 1
    Another case of Linux assuming that you know what you're doing. And since it starts with a dot, it's hidden by default. – Joe Jul 17 '16 at 7:30

You renamed the directory cakephp in /opt/lampp/htdocs/cake to .... Your command was perfectly valid, therefore it did not produce an error.

You should be able to find the directory at /opt/lampp/htdocs/cake/.... Note that files/folder starting with a dot are hidden (hence you need to use, e.g., ls -a /opt/lampp/htdocs/cake to see it).

  • Thanks for reply... I figured it out when i searched it with triple dot ubuntu in google. – Hirdesh Vishwdewa Jul 8 '16 at 13:08
  • Although, to be a bit pedantic, you shouldn't have had permission to rename a directory under /opt without sudo. – Jos Jul 8 '16 at 13:10
  • Thanks @Jos Its my personal development machine so I have given my htdocs a 777 – Hirdesh Vishwdewa Jul 8 '16 at 13:15
  • 7
    @easycoder that gives anyone rights to create a file, I'd restore it to 755 and do chown -R $USER:$USER – grooveplex Jul 8 '16 at 13:29
  • 1
    You are right @Jos. I will change that on priority... thanks – Hirdesh Vishwdewa Jul 8 '16 at 14:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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