Find the answer to your Linux question:
Results 1 to 3 of 3
For the life of me I can not figure out what I am doing wrong with scp to copy a directory and its contents from a remote machine to my ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Oct 2010
    Posts
    5

    scp question


    For the life of me I can not figure out what I am doing wrong with scp to copy a directory and its contents from a remote machine to my local host. I have no issues with getting a single file but would like to just save time and get the whole folder in one command.

    Here is what I have tried:
    scp user AT remoteMachine:/home/username/folderIwant user AT localMachine:/folderIwant
    this gives me a permission denied error and try again and received disconnect from localHost to many authentication failures

    scp user AT remoteMachine:home/username/folderIwant .
    says can not find file or folder

    I am sure this is something easy that I cant remember, and searches gives me local to remote not remote to local and trying to make the local to remote suggestions I read to work remote to local have not worked. Thanks for any help this

    I had to use AT because it thought I was posting links to something and this being a first post is not allowed sorry about that.

  2. #2
    Just Joined!
    Join Date
    Sep 2005
    Posts
    2
    >> scp user AT remoteMachine:/home/username/folderIwant user AT localMachine:/folderIwant

    The second part user AT localMachine is unnecessary. Just put the filename there.

  3. #3
    Just Joined!
    Join Date
    Oct 2010
    Posts
    5
    Thanks for the reply I had tried that already and didnt work.

    What I ended up figuring out was that I had to do:
    scp -r
    since it was a directory with files in it.

    I appreciate the post it made me try it again and come up with the fix

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •