-4

Running Debian Linux - newest version.

cp /included/filename /usr/bin/

It gives me error "cannot stat '/included/filename': No such file or directory I don't get why there should be an error. I am doing it as superuser.

J. Doe
  • 20
  • 7
  • 1
    so you are connected to this machine via SSH as root? what does a `ls -la /included/` output? can you show us the file is actually there? – BNT Jun 16 '17 at 12:12
  • No such file or directory - I fully assure you though that folder exists! – J. Doe Jun 16 '17 at 12:14
  • ls: cannot access /included/: No such file or directory to be exact – J. Doe Jun 16 '17 at 12:15
  • 1
    What are the rights on this file/directory? If you are connected to this machine via `ssh` as `root`, can you `chmod` or `chown` the file or the directory? – louis amoros Jun 16 '17 at 12:22
  • `chown debian /usr/bin/included/` outputs nothing. `chown debian /usr/bin/included/install.sh` (that's the filename) tells me `No such file or directory.` Question: Should I try moving it to desktop and see the results? Would have to re-write all the locations, is it worth a try? – J. Doe Jun 16 '17 at 12:28
  • see my answer, i assume you want to use a relative argument when already in /usr/bin. Please provide output of `ls -la /usr/bin/included/` – BNT Jun 16 '17 at 13:25

1 Answers1

2

From your latest comment i conclude you got the paths mixed up. If you want to copy the file install.sh located under /usr/bin/included/ you would need to do

cp /usr/bin/included/install.sh /usr/bin/

to make something similar to your provided command work, id assume you are in /usr/bin and the first argument needs to be a relative one

cd /usr/bin
cp ./included/install.sh /usr/bin/

Please provide more information on what you are trying to do and provide realworld example code.

BNT
  • 936
  • 10
  • 27
  • Thank you! Sorry for not providing much information, I agree with the two downvotes. Situation clarified a bit: I've downloaded an application on my new Beaglebone running Debian Linux. However, when trying to install it it couldn't find its own files. Turns out it was a fault in the application not defining cd /usr/bin. I didn't bother to look for that at first since I thought it had to already be defined before and there wasn't a chance that it wasn't. Well, turns out it never was. Sorry for the hassle! – J. Doe Jun 16 '17 at 13:51