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 am using Ubuntu 12.04.2 LTS on a Dell 50-50 laptop. Everything went fine until:

[1635][lam@ubuntu:~/bin]$ ll
total 48
-rwxr-xr-x 1 lam lam  232 Jan 27 20:37
-rwxr-xr-x 1 lam lam   34 Aug 26 22:02
-rwxr-xr-x 1 lam lam   94 Nov 13 16:54
-rwxr-xr-x 1 lam lam  156 Jan 20 14:21
-rwxr-xr-x 1 lam lam   61 Oct 31 15:56
-rwxr-xr-x 1 lam lam 2323 Jan 20 13:36 infoscript
-rwxrwxr-x 1 lam lam  257 Dec  4 17:22 local-variable
-rwxr-xr-x 1 lam lam   16 Jan 28 15:2[1638]
[lam@ubuntu:~/bin]$ cp temp/
rm: cannot remove `': No such file or directory
rm: cannot remove `temp/': No such file or directory

I am trying to copy a file, yet Ubuntu apparently tries to remove it. Can anybody explain it?

share|improve this question
Welcome Lam to Ask Ubuntu! I have edited your question, so that it's more readable, and the title is more likely to grab other's attention. – Rafał Cieślak Feb 21 '13 at 16:06
check your aliasses with the command alias. – Rinzwind Feb 21 '13 at 16:07
Check the following:1)Have you set an alias for cp in ~/.bash_aliases or ~/.bashrc? 2)You have no folder temp in your current directory, so do you mean /temp? 3) What is the purpose of ~ in your destination? – i08in Feb 21 '13 at 16:09
Using --remove-destination? ... See man cp. And I would suggest type cp (assuming default Bash) instead of alias, because it could be a function, too. – 0xC0000022L Feb 21 '13 at 16:46

@rafalcieslak Thank you for your help.I had searched for the wrong alias(cp=rm -i) only in bashrc & it was not there. following your advice I tried alias on CLI & there it was the misfit. Unaliasing it did it.

share|improve this answer
who told you that? >:) – Rinzwind Feb 23 '13 at 15:09

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.